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

improve support for export to stdout #55

Open
jonassmedegaard opened this issue Dec 7, 2023 · 1 comment
Open

improve support for export to stdout #55

jonassmedegaard opened this issue Dec 7, 2023 · 1 comment

Comments

@jonassmedegaard
Copy link

When passing - as output file, it mostly works: Both curl and wget treats that as a redirection to stdout.

Unfortunately the shell script does not expect this (which is a common pattern in POSIX-like tools):

a) An annoying trailing line containing the lone dash is appended.
b) Exporting as slides does not support this.

For both cases, dash should here be captured and an appropriate action (either nothing or a graceful error message emitted to stderr) should be taken instead.

@jonassmedegaard
Copy link
Author

Oh, and in case you are curious: Exporting and redirecting to stdout is useful to further process the data without needing an intermediary storing on disk - e.g. a script converting mermaid to {mermaid} for reuse with quarto.

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

1 participant