Comments (10)
Yeah, that's definitely an annoyance. It's reported upstream here: rust-lang/mdBook#864.
People tried to fix it repeatedly: #25 and #29. So we should probably do something about it...
My idea would be to fix it upstream, but I haven't taken the time to do that.
from comprehensive-rust.
Fixed via #951.
from comprehensive-rust.
We could separate the output from the shell commands (like you did in your PRs)
@mgeisler when doing this, the test build fails on the PR
I noticed this when I tried it in the previous PR itself, not sure how to fix it
Update: figured it out, had to specify the language for the new code block
from comprehensive-rust.
Glad to see it's already reported upstream :)
from comprehensive-rust.
Our style guide actually talks about this: https://developers.google.com/style/code-syntax#prompt.
The system used there knows to not copy the $
, even for examples that contain multiple commands. I think we should enhance mdbook
with a similar capability.
from comprehensive-rust.
If mdbook
ever gets support for not copying the prompt, then we can consider adding the prompts back. For now, it's probably better to remove them since this has been suggested repeatedly 😄
from comprehensive-rust.
Hi @sharunkumar, thanks for tackling this. There is a final place where we have a $
infront of the shell commands: build_all.sh
. These dollar signs show up in the Android section.
We should fix those too to make things consistent. Right now, we include the commands from the shell script and hard-code the output. So the Markdown on the page linked above looks like this:
```shell
{{#include ../build_all.sh:hello_rust}}
Hello from Rust!
```
We could separate the output from the shell commands (like you did in your PRs).
from comprehensive-rust.
Oh alright I could check it out
from comprehensive-rust.
Idk if its because I'm running it from windows but when I run mdbook serve
this is what that page looks like on localhost, after the changes:
Update: looks good on WSL though, but not sure why it looks the way it does when serving from windows 🤔
from comprehensive-rust.
We could separate the output from the shell commands (like you did in your PRs)
@mgeisler when doing this, the test build fails on the PR
I noticed this when I tried it in the previous PR itself,
not sure how to fix itUpdate: figured it out, had to specify the language for the new code block
Great that you figured it out — the error looks very mysterious at first! 😄
from comprehensive-rust.
Related Issues (20)
- cortex-m-rt 0.7.4 has been yanked
- Possible clarification in chapter "6.2.1. for" HOT 1
- Page `Exercise: Iterator Method Chaining` rust code not rendering HOT 1
- Most code snippets don't work anymore HOT 2
- Dead link found in the glossary.md translations HOT 1
- Korean (ko): Catch-up with EN version
- Spanish (es): Catch-up with EN version HOT 19
- Brazilian Portuguese (pt-BR): Catch-up with EN version
- Chinese Simplified (zh-CN): Catch-up with EN version
- Chinese (Traditional) (zh-TW): Catch-up with EN version
- Make `Fork` useful in Dinning Philosopher exercises HOT 1
- The language switching menu requires clicking on the text, not elsewhere in the menu item HOT 5
- dprint fmt failing HOT 2
- Local `dprint` and `dprint` in CI want opposite things HOT 1
- Rust
- Automated slide size analysis with a new slide scoring tool HOT 2
- Non-lexical lifetimes on exclusive reference HOT 1
- Link check runs on all languages HOT 2
- Write our own summaries of std types' API surface HOT 1
- Swap order of Cell/RefCell HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from comprehensive-rust.