5 ms·
Explaining Shell Commands in the Shell (2014)
- tomkwok 11y agoSo it's like a command line version of http://explainshell.com/ http://explainshell.com/ ... And it seems like your site / API backend is not open source. Do you plan to make an offline version?
- jap 11y agoI don't plan to make a version that gets its data from local man pages, but it would be great if such a tool existed. Parsing the data out of man pages is messy, and my process currently involves a lot of steps. I actually only started collecting the data for this as a side-effect of trying to make man pages render nicely in browsers. I would like to open source more of the backend, but I've started with a tool I wrote to extract man pages from project repos: https://github.com/jacksonp/manlib https://github.com/jacksonp/manlib
- ridiculous_fish 11y agoThe fish shell has a man page parser that you may be interested in: https://github.com/fish-shell/fish-shell/blob/master/share/tools/create_manpage_completions.py https://github.com/fish-shell/fish-shell/blob/master/share/t...
- jap 11y agoThanks, that does look interesting. Will give it a spin as soon as I get a chance and compare results.
- noir_lord 11y agoThanks for mentioning explainshell.com I occasionally run into commands I've not seen before and end up wading through man pages, this is way more terse.
- deleted 11y ago[deleted]
- amelius 11y agoDoes it work with the "find" command, and its overly complicated way of processing arguments?
- jap 11y agoI think it gives decent results for something like: find . -name test -delete You can try it out online btw: https://www.mankier.com/?explain=%20find%20.%20-name%20test%20-delete#explain https://www.mankier.com/?explain=%20find%20.%20-name%20test%...
- Vimlociraptor 11y agohttps://www.mankier.com/?explain=%20sed%20-i#explain https://www.mankier.com/?explain=%20sed%20-i#explain doesn't parse sed right. http://explainshell.com/explain?cmd=sed+-i http://explainshell.com/explain?cmd=sed+-i works much better
- heydonovan 11y agoAwesome concept! I've never been a fan of looking up flags in another tab, and hunting down which ones are in use. Just seems like it should be an automatic process. The explainshell website is great, but it doesn't work offline. Fish's man page auto-completion is useful, but it lists all the flags, instead of the ones currently in use. If I could have this for every command out there, along with the binary's location/version at the top, I'd be a happy camper.
- grymoire1 11y agoI'm not sure why it is defined as a function when a shell script would work as well, and prevents .bashrc clutter. Also it doesn't understand traditional tar options, i.e. explain 'tar xf filename'
- erikb 11y agoWhy does it say "in the shell" when the actual work is done by a web server? Sorry, I was just really curious how you grep/awk/sed through some man pages.