Open DeveloperPaul123 opened 1 year ago
As of v1.0.2 (which is also the new v1 tag), one can pass a new line separated list of .typ files and all of them will be compiled. There are no checks for errors along the compilation, no support for directory, no support for glob expansion.
I am a bit puzzled by how to handle #2 now that there is the possibility of multiple files. I guess a syntax could be
source_file : |
foo.typ bar.pdf
baz.typ
fizz.typ
buzz.typ buzzy.pdf
But that's a bit harder to handle, and I would like the bash script to remain readable. Maybe using python or another scripting language is the best way to go for the building script.
@lvignoli Could you have a second parameter input as another list of output file names and then map them 1 to 1 to the input file list?
I am unsure of how sound passing a directory is.
A typical Typst project is broken into several files, beginning with a template file. Typst needs a specific target root file to start compilation.
Supporting directories would only improve the specific use case of compiling many standalone single files. This seems peculiar, and probably be addressed by generated the list of target files before the Typst action job/step, passing it as an input.
For these reasons, I would rather not support directories nor globbing—for now.
It would be nice to be able to pass a directory with
*.typ
files or a list oftyp
files to be compiled and have the action generate separate PDFs for each of them. Supporting wildcards would be nice too if possible (i.e.<dir>/*.typ
).