-
Notifications
You must be signed in to change notification settings - Fork 4
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
Wrap media paths with <> #3
Comments
Hey! Thanks for the report and looking for a solution. I've implemented this (for markdown flavors which use the Let me know if it works for you :) Side noteConsider as well that GitHub-flavored markdown has a different syntax, as folllows,
which supports paths with spaces by default as well as keeping image size information. The markdown test in the tests directory renders well both in GitHub and VSCode. To use GitHub flavored markdown, set
|
Wonderful, thanks a lot @alopezrivera ! During my own testing I also realised that spaces in the notebook names (as in, the actual name as seen from OneDrive web, not the "local" name that can be changed in app) cause an error during Onenote->docx conversion, thus failing to attempt the markdown conversion. As I said earlier, I will test the media path file and provide more detail on the rest of issues later on. Thanks again for everything! |
Cool! Let me know if the figure names work when you test :) Thanks for the heads up about notebook names. If you will, please submit a new issue for that if you have the time. I'd appreciafe if you add some more information about the notebook names causing issues and such so I can replicate them and see what's going on. Thanks in advance! |
Alright, I'm back after some more tests. Thanks again for supporting the tool btw! :) So, after the latest commits the file paths still don't appear to be flanked by <>. I looked into the commit and, from my very limited knowledge, I believe that should have fixed it. The only thing I could think off would be some shenanigans with variable names or config options, but sadly I don't enough about powershell to suggest a fix.... For reference, see below my config options:
Again, thank you for everything; I really wish I could implement the changes myself via a pull request. |
Alright so, there's two errors that could be happening there:
To cross off the second I've added support for all markups supported by Pandoc in commit c8bc293. This means that The issue persisted, so after some trial and error I've implemented a brute force regex solution to wrap media paths in
|
If there are any spaces in the path to media files, those can't be parsed and loaded into the .md file. Simply wrapping the file paths with <> in markdown would solve the issue.
Example:
![](media/FILENAME with SPACES.file)
----> Broken link in .md![](<media/FILENAME with SPACES.file>)
Using <> for file paths in markdown:
The text was updated successfully, but these errors were encountered: