I first learned to program in Perl on a FreeBSD machine. (No GUI, mind you.) I had no way of browsing the internet, so my only source of documentation was via `perldoc`. Perl's documentation was so good I didn't ever need to go online.
Now, every time I encounter a new language, one of my favorite things is seeing the documentation available off-line, accessible via the command line. (Either directly from the terminal or opened in a browser.)
I've loved seeing the Rust community take documentation and error messages so seriously. It's nice to see this level of care.
The funny thing is that I am fairly junior at Rust, and started using that functionality early on when I was trying to implement it, and really missed it every time I broke it or had to re-installed the prod version of rustup!
This is said a lot, but the Rust community is truly welcoming and helpful, even as a newcomer to Rust I got a lot of help and guidance on this. If you have an idea for a new functionality or fix something, don't let your inexperience stop you, go on discord and discuss it, write a small proof of concept and do a PR asking for feedback.
• You can bring up a specific book with `rustup doc --book`, `rustup doc --embedded-book`, `rustup doc --nomicon` etc... (use `rustup doc -h` to see the list). Yes works offline too.
• It should obvious because it's right there, but I somehow totally missed it, and so did the few people I mentioneded it to since: There is either a search box or a symbol on every single `rustup doc` pages. It works really well and typically allow to find what you're looking for quickly. And yes, it too works offline!
But now I can shift "do some stuff with Rust" higher up on that list, so thank you!
Ed: now the bad thing about lean core - fat ecosystem - and the great cargo - is of course that I will need to either "pack my expected dependencies", or just stick to the core... Which is great for learning, but kind of annoying if the plan isn't to write a database and a graphics library... But rather some kid of application. But we can't have everything.
It lets you download offline doc "packs" and search through them quickly.
This is inspired by Dash: https://kapeli.com/dash.
I know Rust is working on their own LangServ as well. I hope LangServ matures enough to secretly turn supporting editors into lightweight IDEs.
That's amazing
godoc -http=:6060
Will do it for you. Then just visit localhost:6060It sounds like the Rust distribution needs to use zip files more?
$ rustup component list | grep installed
cargo-x86_64-unknown-linux-gnu (installed)
rust-docs-x86_64-unknown-linux-gnu (installed)
rust-std-x86_64-unknown-linux-gnu (installed)
rustc-x86_64-unknown-linux-gnu (installed)
rustfmt-x86_64-unknown-linux-gnu (installed)
$ find ~/.cargo -type f | wc -l
8699
8K files... So 1 to 2 orders of magnitude less than any given frontend node_modules folder. Pretty reasonable actually.