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

doc subcommand markdown issues #66

Open
kevinramharak opened this issue Aug 21, 2020 · 4 comments
Open

doc subcommand markdown issues #66

kevinramharak opened this issue Aug 21, 2020 · 4 comments
Labels
almost fixed A working fix has been implemented and will be merged soon bug Something isn't working

Comments

@kevinramharak
Copy link
Contributor

So i noticed a few issues with the doc subcommand:

  1. the -o OUTPUT flag does not seem to work
  2. characters like * and _ have special meaning in markdown. These characters are currently unescapable when writing a #[doc("*")] directive
  3. a function without arguments is printed out like fn HWI::comport_console_clear). A function with arguments is printed out correctly like fn HWI::comport_self_out(source: &char) -> bool.
@adam-mcdaniel
Copy link
Owner

Ahh, the first problem came about when I fixed the -g flag not working, and is a simple fix. Additionally, the third problem is also a one or two line fix. The second, however, I'm not really sure is a problem. The user has the ability to make the markdown look terrible by leaving an unescaped *, and I'm fine with that being their fault.

@kevinramharak
Copy link
Contributor Author

Except it is impossible to escape it. Unless im writing the wrong sequence but from what i have tested nothing of the following will generate a *: \*, \\* and \\\\*.

@adam-mcdaniel
Copy link
Owner

adam-mcdaniel commented Aug 21, 2020

Ohhhh, I see what you mean. I thought you meant that the user could not un-make-the-rest-of-the-markdown-italic. That should be fixed.

@adam-mcdaniel
Copy link
Owner

After doing some digging, the root of this problem is not in this crate. The crate printing the markdown to the terminal is at fault. If you want to display a * character in your markdown, \* will work. You just can't print it to the terminal properly right now; the -o output file will be displayed properly by another markdown compiler or previewer.

@adam-mcdaniel adam-mcdaniel added bug Something isn't working almost fixed A working fix has been implemented and will be merged soon labels Aug 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
almost fixed A working fix has been implemented and will be merged soon bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants