Skip to content

Wrong syntax highlighting for terminal output #327

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

Closed
LukasKalbertodt opened this issue Nov 13, 2016 · 2 comments
Closed

Wrong syntax highlighting for terminal output #327

LukasKalbertodt opened this issue Nov 13, 2016 · 2 comments
Labels
blocked upstream Blocked on a change that needs to happen in a different repo first Bug Online only

Comments

@LukasKalbertodt
Copy link
Member

LukasKalbertodt commented Nov 13, 2016

Most code blocks that contain output from the terminal seem to be written with

```bash     -or-      ```sh

This results in strange syntax highlighting (here, for example; for in written text is blue). Usually the text in those blocks is just output of rustc or cargo. Syntax-highlighting that doesn't really make sense. bash and sh highlighter are for scripts.

I don't know what chapters this applies to, but there seem to be a few.

@carols10cents
Copy link
Member

Yup... this is a hack because i want a gray background for code blocks (even those without syntax highlighting) but it's going to require a modification to mdbook which I haven't been prioritizing very high since this only affects the online version, not the print version. I do want to fix this though!

@carols10cents carols10cents added Online only blocked upstream Blocked on a change that needs to happen in a different repo first Bug labels Nov 14, 2016
carols10cents added a commit that referenced this issue Nov 14, 2016
Since none of these are actually bash scripts :)

Changed all the instances in the src files to text, which, since my PR
to mdbook got accepted, will still do code background colors but no
syntax highlighting.

Fixes #295 and #327.
@carols10cents
Copy link
Member

Thank you Lukas-- this issue was just the nudge I needed to get all the pieces together. This should be fixed on the rendered version as soon as travis rebuilds it :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked upstream Blocked on a change that needs to happen in a different repo first Bug Online only
Projects
None yet
Development

No branches or pull requests

2 participants