rust-lang / book

The Rust Programming Language
https://doc.rust-lang.org/book/
Other
15k stars 3.39k forks source link

Copying the CLI code includes the $ sign #3940

Closed 14slash12 closed 4 months ago

14slash12 commented 4 months ago

URL to the section(s) of the book with this problem: e.g. in Chapter 1.2. See: https://arc.net/l/quote/nfbvbeuc

image

Description of the problem: When pressing the copy button the $ is also included, i.e. the user can't use the code directly

Suggested fix: Make the copy function only copy the code without the $ sign

carols10cents commented 4 months ago

Hi, a search for "dollar" returns these duplicate issues https://github.com/search?q=repo%3Arust-lang%2Fbook+dollar&type=issues

And reading those you'll find that this is something we'd like to see resolved in mdbook.

14slash12 commented 4 months ago

Sorry, I did not find it right away. Thanks anyway! 👍