Wow, this is really cool. I assumed this was going to be written in go or rust, but taking a look it's actually all bash! I'm always surprised by how much people can get out of bash. It's also some of the cleanest bash I've seen. Definitely going to be using some of these patterns for my own scripts.
An interactive cheatsheet tool for the command-line
41–49 of 49 posts
Re: An interactive cheatsheet tool for the command-line
#42Is there any way to run this on Windows, for people who use Cygwin or Git Bash? It seems really cool and useful
Re: An interactive cheatsheet tool for the command-line
#43Would be neat if `navi git` started it up and applied a filter at the same time.
My only concern is that this way it would be impossible to add subcommands to navi
Let's say that in the future I want to add a command for removing a cheat (navi remove)
The way you described, it would look for snippets which contain "remove"
Any ideas?
Re: An interactive cheatsheet tool for the command-line
#44Is there a key command or way to find out what's below the cheat? For instance, I tried the "local ip address" example in the demo and it gave the IP address but now 'how' -- ifconfig? was it in a text file? env var? script?
Alternatively, you can use the --print option
I hope you like it!
Re: An interactive cheatsheet tool for the command-line
#45Similar concept: cheat.sh
Re: An interactive cheatsheet tool for the command-line
#46Same idea as https://news.ycombinator.com/item?id=19436884 but more polished and faster.
Re: An interactive cheatsheet tool for the command-line
#47Looks neat. I wish, though, there was a way to try it out in the browser as advertised without having to sign up or login. Might be a requirement of the site hosting the demo but whoever it is, forcing login is always and forever a deal breaker for me.
I didn't know it requires a login. Do you know any online free platform that can launch a given docker image?
Re: An interactive cheatsheet tool for the command-line
#48Looks really nice; I don't like the fact that an unknown command is executed before i can see/inspect what it is. Currently you won't even see what command was executed afterwards, you only see the result... Would be nice to be able to also show the command below the item/result. --print is possible, but it's cumbersome and not interactive: you can't "accept" the command after inspecting, and execute it.
Based on your input, the latest version has a preview window: https://user-images.githubusercontent.com/3226564/65380182-6... I hope you like it!
Re: An interactive cheatsheet tool for the command-line
#49This looks cool, a common workflow of mine is `cmd --blah --blah ` ah damn I don't know the value for blah, okay, fzf ` --blah=(blahgen | fzf) ` oh I'm also missing [...] This seems like it can help do the same thing more quickly, so I'm keen to give it a go. I do like shell history though, a shame to just have a bunch of `navi` entries - I wonder if it could be faked; populated with the chosen command afterwards?
I could write a zsh/bash plug-in so that it fills the prompt instead of running the command, in the same manner as ctrl-r. What do you think?