Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PDF not exported when non-main source files are changed (onSave or onType) #70

Open
4 of 5 tasks
xingjian-zhang opened this issue Apr 4, 2023 · 4 comments
Open
4 of 5 tasks

Comments

@xingjian-zhang
Copy link

xingjian-zhang commented Apr 4, 2023

  • Component:
    • VSCode Extension
    • VSCodium Extension
    • LSP (used with other editor)
  • Extension version: v0.3.1
  • LSP version:
  • OS version and name:
  • I am on the latest stable version of the extension/LSP.
  • I have searched the issues of this repo and believe that this is not a duplicate.

Issue

Reproduce:

  • [VSCode Extension setting] Export PDF: onSave and onType
  • Folder structure
.
├── other.typ
├── main.pdf
├── main.typ
└── template.typ
  • In main.typ:
#include "other.typ"

When other.typ is modified, the PDF will not be rendered automatically.

@Alex-Muirhead
Copy link

This behaviour is also present when using only the LSP component.

@xingjian-zhang
Copy link
Author

This behaviour is also present when using only the LSP component.

Just also toggled the LSP checkbox.

@beeb
Copy link
Contributor

beeb commented Apr 15, 2023

Related #11

@KronosTheLate
Copy link

I was table to work around this by running typst watch main.typ and changing ctrl+s to File: Save all files. This leads to a smooth workflow with multiple files.

It should be possible to configure a langage-dependent binding of ctrl+s to save all files, and make a command that is Typst: watch X.typ, which when selected, opens a list of all typst files in current directory, and when the user presses enter on one of them, watches that file.

I am not sure how to incoperate a log upon errors with this approach, which is something that I miss. This is no problem with the manual approach of opening a terminal and running typst watch main.typ in the same group as the PDF, allowing easy swiching between terminal and PDF.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants