vscode-plantuml icon indicating copy to clipboard operation
vscode-plantuml copied to clipboard

Question/clarification: How to use includepaths?

Open chipbite opened this issue 4 years ago • 5 comments
trafficstars

Hi, I am trying to use includepaths setting (using server render). My diagram !includes work for (a) current (diagram sourcefile) dir, (b) relative to that sourcefile dir but I cannot get includes (c) relative to the project root to work.

It all works fine when I use "local jar-file" render, but not when using server render.

So, I tried setting up plantuml.includepaths, but I cannot get it to fix the issue. I have tried:

/docs/
docs/
docs

( e g "plantuml.includepaths": [ "/docs/" ] )

  • ❔ How can I setup the includepaths to include a docs folder in the project root?

(I am using win10.)

Thanks for a great plugin!

BR! /marcus

chipbite avatar Sep 07 '21 09:09 chipbite

So if I understand it correctly, project relative references do not work. The includepaths must be global.

https://github.com/qjebbs/vscode-plantuml/issues/375#issuecomment-773036980

chipbite avatar Dec 15 '21 09:12 chipbite

@chipbite , hello!

I have try to include file by relative path by instruction https://github.com/qjebbs/vscode-plantuml#include-files-search-logic

!include "./../lib/rsm.puml"

and have error

cannot include "./../lib/rsm.puml"

Do you mean, this way does not work now?

vitalyzhakov avatar Feb 24 '22 09:02 vitalyzhakov

Hello!

I still do not fully understand. Do paths relative to project/vscode workspace root not work in the includepaths setting? In the readme of the project the path suggestions look relative to me: "plantuml.includepaths": ["docs/diagrams/style","docs/diagrams/src"]

But for me it doesn't work unless I put absolute paths there.

Florin-Popescu avatar Apr 20 '22 23:04 Florin-Popescu

Hello i am also encountering this problem , the only way for the !include style_sheet.iuml to work is if it is in the same directory of duplicate_record.puml file , I can not add relative paths such as !include ../style_sheet.iuml Duplicate records

yorgoA avatar Jun 20 '24 07:06 yorgoA

I also tested with both files in .puml instead of one in .puml and another in .iuml but the issue remains

yorgoA avatar Jun 20 '24 07:06 yorgoA