nvarner / typst-lsp

A brand-new language server for Typst, plus a VS Code extension
MIT License
1.19k stars 77 forks source link

cannot correctly recognise the path from environment variables #120

Open zcorn2017 opened 1 year ago

zcorn2017 commented 1 year ago

Issue

The server cannot correctly recognise the path from environment variables, which is a new feature recently released from v3.0. For details, you refer to v0.3.0.

Font path and compilation root can now be set with the environment variables TYPST_FONT_PATHS and TYPST_ROOT

For instance,

#import "/template.typ": *

would give file not found. This bug prevents the server from compiling the file.

Thank you in advance.

thecaralice commented 1 year ago

I have this issue as well. Can't use most of typst-lsp features in my projects because I use some shared functions which i store in TYPST_ROOT=~/.local/share/typst/ - that includes not only my personal use modules but also libraries like typst-canvas.