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

Use TEXMF_OUTPUT_DIRECTORY to set \markdownOptionOutputDir #405

Closed
Witiko opened this issue Feb 12, 2024 · 0 comments · Fixed by #409
Closed

Use TEXMF_OUTPUT_DIRECTORY to set \markdownOptionOutputDir #405

Witiko opened this issue Feb 12, 2024 · 0 comments · Fixed by #409
Labels
defaults Related to default option values and renderer prototypes quality of life Related to quality-of-life improvements to the interface
Milestone

Comments

@Witiko
Copy link
Owner

Witiko commented Feb 12, 2024

As discussed on our matrix.org, in KPathsea from TeX Live 2024, the option --output-directory from engine invocation is available in TEXMF_OUTPUT_DIRECTORY environmental variable. We can use this to set \markdownOptionOutputDir based on --output-directory. After we have added support for TeX Live 2024 (pretest) in #404, we should:

  • Automatically set \markdownOptionOutputDir based on TEXMF_OUTPUT_DIRECTORY if it's set or fall back to current working directory otherwise.
  • Deprecate \markdownOptionOutputDir and make a comment that says that we have to drop support for TeX Live 2024 after we remove it in the next major release.

Here is a more detailed plan of action:

  • Move the loading of the lt3luabridge library before defining the outputDir plain TeX option.
  • Use \sys_if_shell_unrestricted:TF to decide whether we should try to determine TEXMF_OUTPUT_DIRECTORY.
  • Use \luabridge_now:n { print(os.getenv("TEXMF_OUTPUT_DIRECTORY") or ".") } to determine TEXMF_OUTPUT_DIRECTORY.
  • Store the result of \luabridge_now:n in \l_tmpa_tl and use a new variant \@@_add_plain_tex_option:nnV to set the default value from \l_tmpa_tl.
  • Mark \markdownOptionOutputDir as deprecated in technical documentation.
@Witiko Witiko added quality of life Related to quality-of-life improvements to the interface defaults Related to default option values and renderer prototypes labels Feb 12, 2024
@Witiko Witiko added this to the 3.4.1 milestone Feb 12, 2024
@Witiko Witiko changed the title Use TEXMF_OUTPUT_DIRECTORY to set \markdownOptionOutputDirectory Use TEXMF_OUTPUT_DIRECTORY to set \markdownOptionOutputDir Feb 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
defaults Related to default option values and renderer prototypes quality of life Related to quality-of-life improvements to the interface
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant