From 91f9e1884bfa42ce85507e3647d5f4dab91b8746 Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Fri, 16 Oct 2020 10:31:20 +0200 Subject: [PATCH] 2020-10-16-rman.md --- content/2020-10-16-rman.md | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 content/2020-10-16-rman.md diff --git a/content/2020-10-16-rman.md b/content/2020-10-16-rman.md new file mode 100644 index 0000000..66cacb9 --- /dev/null +++ b/content/2020-10-16-rman.md @@ -0,0 +1,33 @@ ++++ +title = "rman - Search the Rust Documentation offline" +date = 2020-06-23 +[taxonomies] +tags = [ "rust", "documentation" ] +categories = ["programming"] ++++ + +Want to search your local offline rust `std` documentation, +with a quick command from your terminal? + + + +Preparation: + +Download the rust documentation: +```console +$ rustup component add rust-docs +``` + +Setup a bash function (you might need to replace `firefox` with your browser): +```bash +function rman() { + firefox "file://$(rustc --print sysroot)/share/doc/rust/html/std/index.html?search=$@" +} +``` + +Fire up your browser with the search window from your terminal: +```console +$ rman MaybeUnit +``` + +Ok... it's not `man` and `apropos` ... but good enough for now. \ No newline at end of file