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

relative preprocessor paths are relative to the current directory instead of the book root #1424

Open
ehuss opened this issue Jan 4, 2021 · 1 comment
Labels
A-Preprocessor Area: Preprocessors Breaking Change This would require a SemVer breaking change
Milestone

Comments

@ehuss
Copy link
Contributor

ehuss commented Jan 4, 2021

If a preprocessor has a custom command path like foo/bar, then the path will be relative to the current directory. I think it should be relative to the book root. This only really matters if mdbook is run outside of the book root.

Unfortunately this is not easy to change without a breaking API change. CmdPreprocessor could add a root field, or Preprocessor::supports_renderer trait method would need to pass in the book root.

See #1418 for more related to backend relative paths.

@daprilik
Copy link

Just wanted to chime in that we ran into this in our project-specific mdbook preprocessor https://github.com/microsoft/openvmm/tree/main/Guide/mdbook-openvmm-shim

Glad to see this was put on the 0.5 milestone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Preprocessor Area: Preprocessors Breaking Change This would require a SemVer breaking change
Projects
None yet
Development

No branches or pull requests

2 participants