<i>Very</i> nice! I fed it one of my favorite commands:<p><pre><code> git branch --merged | grep -v master | xargs -n 1 git branch -d
</code></pre>
and it dealt with it reasonably well. The only part it couldn't understand was `branch -d` at the end. In other words, it was not capable of recognizing that the non-option arguments to `xargs` should actually be recursively interpreted as a command-line.
Best used in combination with shellcheck (<a href="https://www.shellcheck.net/" rel="nofollow">https://www.shellcheck.net/</a>), which checks your shell scripts for bugs.
I fed it the most recent command posted on commandlinefu.com:<p><pre><code> grep -i s2enc /etc/vcac/server.xml | sed -e 's/.* password=\"\([^\"]*\)\".*/\1/' | xargs -n 1 vcac-config prop-util -d --p 2>/dev/null; echo
</code></pre>
Given the height of the result, scrolling up and down became a real pain. Maybe collapsable sections or position:fixed for the command or something like that?
Two big threads from 2013:<p><a href="https://news.ycombinator.com/item?id=6296634" rel="nofollow">https://news.ycombinator.com/item?id=6296634</a><p><a href="https://news.ycombinator.com/item?id=6834791" rel="nofollow">https://news.ycombinator.com/item?id=6834791</a>
I would love it if the site was encrypted so that I could input raw commands at work without modifying sensitive information. (Yes I understand the host can still record this sensitive information, and no I have not looked through the source code yet to see that this doesn't occur).
This works well, but the web interface seems like an unnecessary layer on top of what could just be a terminal based tool. I'm trying to resist the urge to fork this, putting another project on my todo list I will never finish
Optenum to enrich the database of arguments:<p><a href="https://github.com/mattboyer/optenum" rel="nofollow">https://github.com/mattboyer/optenum</a>
Does anyone know where I can find a completely offline tool that does what this site does?<p>The source for this seems like a bit of overkill. I'd like to be able to use a cli based tool that shows me relevant man sections for the flags I chose for example
Lovely! Bookmarking for future use!<p>Some quick notes on my way back from work:<p>1. Broken on mobile :(. Default layout is a mess, and "request desktop site" has the lines going to the edge of the screen, making them invisible. S7, Android, Firefox.<p>2. Totally neeeds to be done as an Emacs mode (preferably offline). Both for checking a particular command and during writing shell scripts.
Really solid. I fed it a recent nasty line from our Makefile: <a href="https://github.com/cockroachdb/cockroach/blob/4aeef50/build/protobuf.mk#L132" rel="nofollow">https://github.com/cockroachdb/cockroach/blob/4aeef50/build/...</a><p>Looks like it doesn't deal with subshells, but otherwise it did reasonably well.<p><a href="http://explainshell.com/explain?cmd=find+.+-name+*.pb.cc+%7C+sed+%27s%21.%2F%21%21%27+%7C+xargs+-I+%25+sh+-c+%27echo+%22%23include+%5C%22%25%5C%22%22+%3E+%24%28echo+%25+%7C+tr+%2F+_%29%27" rel="nofollow">http://explainshell.com/explain?cmd=find+.+-name+*.pb.cc+%7C...</a>
Very impressive.<p>It seems to rely strongly on common *NIX CLI patterns though. It really doesn't like dd, for example[1].<p>[1]: <a href="http://explainshell.com/explain?cmd=dd+if%3D%2Fdev%2Fsda+of%3D%2Fdev%2Fsdb" rel="nofollow">http://explainshell.com/explain?cmd=dd+if%3D%2Fdev%2Fsda+of%...</a><p>Edit:<p>Also, it doesn't understand that the token after `-p` for netcat is actually the port argument[2]. I guess it is parsing manpages internally?<p>[2]: <a href="http://explainshell.com/explain?cmd=nc+127.0.0.1+-p+80" rel="nofollow">http://explainshell.com/explain?cmd=nc+127.0.0.1+-p+80</a>
Cool tool. I think what would really be the icing on the cake is if it substitued the actual command into the documentation. Removing that one layer of indirection would make it that much easier to understand.<p>For example:<p>foo() { bar }<p>> This defines a function named "foo".<p>Also that example fails to parse. Even though :() { :|: };: works so it seems like there is a certian amount of special casing.
Very cool! Although it has some problems if there isn't a space between a flag and its value: <a href="http://explainshell.com/explain?cmd=gcc+-I%2Fusr%2Flocal%2Finclude+-L%2Fusers%2Fblah%2Flibs+test.c+-o+bin%2Fprogram" rel="nofollow">http://explainshell.com/explain?cmd=gcc+-I%2Fusr%2Flocal%2Fi...</a>
If you hover over something that points to a description that's not currently in view, you can't scroll to the description without unhovering and hence unhighlighting the line pointing to the right description.
There are several commands on OS X that behave a bit differently from their traditional UNIX counterparts. grep is the big one that springs to mind—any given grep shell-fu may just not work on OS X and I'll find myself having to reconstruct the arguments from scratch to get it working.<p>I'd love to see a fork of explainshell or an option in the interface to deal with items like this which are specific to OS X. Let me put a grep command in for OS X and have it show me what options I'm using which are undocumented—that would be nifty.
<p><pre><code> file=$(echo `basename "$file"`)
</code></pre>
This is a horrible example, since it has a "useless use of echo", forcing nested evaluations and a bashism. Basename prints to stdout too!<p>The sh-compatible, simpler equivalent:<p><pre><code> file=`basename "$file"`</code></pre>
It doesn't quite get dd, as well.<p><a href="http://explainshell.com/explain?cmd=dd+if%3D%2Fdev%2Furandom+of%3Dtest.iso+bs%3D10M+count%3D10" rel="nofollow">http://explainshell.com/explain?cmd=dd+if%3D%2Fdev%2Furandom...</a>
Does well, but goes only so far. I fed the command sudo chown -R $USER:$USER /var/www/example.com/html and the tool wasn't capable of recognizing what $USER:$USER is doing.
I thought this was pretty cool but missing something. Until I realized that uMatrix was blocking Cloudflare. Once I loaded the rest of the site... Awesomeness. Great work, whoever made this.
Pretty neat! Though it would be nice if it brought into the view the part you highlight when it doesn't fit on screen, otherwise you have to scroll (and highlight is lost).
Handy tip for those on a mac using terminal - type a command and press cmd-ctrl-shift-? to get a man page pop-up. (People with touch bars can just tap on the man page icon.)
Very nice. However I find myself trying to decipher regular expressions more often than shell commands. A tool like this for regular expressions would have been more useful.
i discovered this site about two years ago. I still use it for explaining commands that I run across on StackOverflow before I run them in my own terminal.
it does a pretty good job with "sudo make me a sandwich" =)<p><a href="http://explainshell.com/explain?cmd=sudo+make+me+a+sandwich" rel="nofollow">http://explainshell.com/explain?cmd=sudo+make+me+a+sandwich</a>
There's no PowerShell support. That's not any command.<p><a href="http://explainshell.com/explain?cmd=Get-ChildItem" rel="nofollow">http://explainshell.com/explain?cmd=Get-ChildItem</a>