11 ms·
Explain Shell
- heldrida 13y agoVery interesting project, already using it!
- aeykie 13y agoYou can use `man test` for [ ] which it currently reports no man page for.
- staunch 13y agoVery well done. Now I just wish this was a shell program! user@server:~$ explain iptables -A INPUT -i eth0 -s ip-to-block -j DROP
- jeroenjanssens 13y agoSee https://github.com/jeroenjanssens/data-science-toolbox/blob/master/explain https://github.com/jeroenjanssens/data-science-toolbox/blob/... for a bash script that interfaces with explainshell.com. I wrote this script a while ago. I just needed to update the request because the API had changed a bit since then. Please note that it depends on the scrape tool in the same repository, which in turn depends on the python packages lxml and cssselect. But once you have that set up, you can explain commands from the shell! :-)
- staunch 13y agoSounds like a job for a little statically compiled Go program :-)
- Flimm 13y agoThe trouble with that approach is that you have to escape special characters: $ explain cat filename | sort # won't work $ explain 'cat filename | sort' # presumably would work I wonder if the best approach is to make `explain` behave like a prompt. If there was some way it could inherit bash's command history, even better $ explain explain> cat filename | sort
- auton1 13y agoThis is a great idea!
- jph 13y agoI'll donate $100 if the author wants to build this and open source it. [Ed: As a shell application locally] A new "explain" command could help me, my team, and save us an enormous amount of time getting up to speed on some of our org's long-term system maintenance scripts.
- toomuchtodo 13y agoHow about an API where you can POST your script with curl -X and a unique link is returned that explains the script when you hit it with a browser? #shutupandtakemymoney (DevOps is fun, teaching not always)
- deleted 13y ago[deleted]
- skeletonjelly 13y agoI would never install this in this format. I'm not going to POST my bash history! I'd prefer a model where you download a definition file (if it needs to be "updated" at the start frequently)
- idank 13y agoThanks for the incentive, but it's not needed and if I do get around to it, it'll of course be open source. The main difficulty I had with writing a command line utility is figuring out the UI in a console. Suggestions are welcome of course. Also, there are two possibilities for a client: the first queries an API on explainshell.com by sending it a command line. This has the advantage of the client being thin, and using the centralized man page database which is probably more accurate. But this means that you're potentially not explaining the exact command you're running locally, which may be confusing. The second option is to run the man page parser, matcher, etc. locally against the man page on your machine.
- auton1 13y agoOne advantage of a local repository is that it is more likely to match the software versions on the local machine. However, perhaps the best thing would be to allow both local and remote queries :-)
- michaelhoffman 13y agoYou can run the web server locally. See the source code readme: https://github.com/idank/explainshell https://github.com/idank/explainshell It should be trivial to whip something up that will generate the right URL for a set of arguments, running either on your local web server or against explainshell.com
- StavrosK 13y agoI thought of quickly writing one, but it doesn't have an API. Something like this would work well: POST your query, e.g.: tar zcf - some-dir | ssh some-server "cd /; tar xvzf -" Returns: [ ["tar(1)": "explanatory text"], ["z": "explanatory text"], ["x": "explanatory text"], ["f file": "explanatory text"], ] etc.
- idank 13y agoI had something similar in mind. But this format means that repeated arguments that aren't adjacent will have their help text repeated. Feel free to open a bug and we can discuss the options there.
- ajross 13y agoUm... the output wouldn't be interesting for that iptables command -- it's simply a single program with arguments; no shell syntax involved. I suspect what you really want is an iptables demuddler tool that explains the insane "chains" metaphor and explains how individual packets are going to behave. I'd like that too, but it's not this tool.
- staunch 13y agoIf all it did was parse program arguments and display usage info it would be super useful. Bash syntax is mostly trivial while there are thousands of arguments across hundreds of programs.
- tlrobinson 13y ago#!/usr/bin/env python import sys import urllib import webbrowser url = "http://explainshell.com/explain?cmd=" + urllib.quote(' '.join(sys.argv[1:])) webbrowser.open_new(url) (webrowser.open_new doesn't seem to be always working for me, not sure why, I've never used it before)
- deleted 13y ago[deleted]
- SimHacker 13y agoAt least you didn't try to do that in bash! ;) One suggestion though: If there are no command line parameters, then read a line from stdin, so you don't have to play the game of trying to properly escape all of your punctuation in the command line to get it into sys.argv[1:] without any corruption, and can just copy and paste it into stdin. Hmm, that raises the question of what should happen if you pipe an entire shell script into it, like "./configure"? That might be considered a denial of service attack on explainshell.com.
- tlrobinson 13y agoI've definitely written a URL escaping routine in bash before :)
- petercooper 13y agoIt exists, though does rely on the central service: http://schneems.com/post/61514247453/explain-shell-from-your-shell http://schneems.com/post/61514247453/explain-shell-from-your...
- jraines 13y agothere's this: https://github.com/schneems/explain_shell https://github.com/schneems/explain_shell
- jfasi 13y agoGorgeous. Amazing. Absolutely fantastic. Easy the coolest and most useful thing I've seen on hacker news in a while. Enough gushing, now some bug reports: "read -r random_line < <(sort -R file)" yields "syntax: expecting filename or fd (position 22)" "nc HOST PORT | tee movie.mp4 | mplayer -" I can hover over movie.mp4, but I can't scroll down the see the description without losing the emphasis on that path. I'd suggest letting the user click on the portion, or perhaps a long-hover effect?
- icebraining 13y agoThe first bug is acknowledged in the page: "support for (...) command substitutions will be added later on"
- rcthompson 13y ago> I can hover over movie.mp4, but I can't scroll down the see the description without losing the emphasis on that path. I'd suggest letting the user click on the portion, or perhaps a long-hover effect? What if the command was simply pinned to the top of the screen as you scroll down? This would require some trickiness to make the atoms remain connected to their documentation as the documentation slides under the command, but would allow you to view any documentation on the same screen as the command itself. EDIT: On the other hand, I just noticed that there are buttons to only show the documentation for specific subcommands, so you can always use those to cycle until the documentation you want to see is visible.
- angersock 13y agoThe wiring is sexy, but this is a textbook cases where tabbed panes would be perfect: just have each command segment be a tab, and the corresponding docs be in a pane underneath.
- logicallee 13y ago(I have no relationship with OP or the submitter/submission). >Gorgeous. Amazing. Absolutely fantastic. Easy the coolest and most useful thing I've seen on hacker news in a while. >Enough gushing, now some bug reports: I like the way you wrote your comment! It could stand as an example to everyone. Yours might have had enough gushing, but I think every "negative" comment should start with as high praise as it can muster. If the whole thing isn't as good, then it should first be "damned with faint praise" and then specific constructive criticisms shown. Obviously the praise doesn't have to be as strong as your comment. I just want to point out how awesome a comment like yours is - it is incredibly hard to put together and share something. We could all do well to remember that when we point out how to improve it.
- publicfig 13y agoThis is amazing! It's great for someone like me who, while knowing their way around the shell, isn't as well versed as some of my more veteran co-workers. While it's great to hear explanations of some of the more dense lines they give me to run, that's not always possible and can be a bit annoying. This could help take some of the pressure off of them to drag me through. :P
- jbverschoor 13y agoWOW!
- tieTYT 13y agoThis is pretty cool but what I found annoying was matching the snippet of code and the description together. Take this for example: http://explainshell.com/explain?cmd=true+%26%26+%7B+echo+success%3B+%7D+%7C%7C+%7B+echo+failed%3B+%7D http://explainshell.com/explain?cmd=true+%26%26+%7B+echo+suc... The command is: true && { echo success; } || { echo failed; } But the top box description is for echo parameters. The next one is for echo. Why can't it go from top to bottom in order of the command? EG: Start with true, then &&, then {, then echo, etc. The way it is, I spend a lot of mental energy matching things up.
- idank 13y agoI agree it's a little counter-intuitive. But if it's top to bottom then all the lines would cross each other which would ruin the UI. If there's a way to make it top to bottom while keeping the UI useful, I'd love to hear!
- tieTYT 13y agoMaybe I'm missing some point, but I don't think you need the lines if it goes top to bottom. Or, maybe you'd only need one line to show up if you highlighted a snippet/description: To point back to what you're hovering over.
- idank 13y agoI think it'll be hard to match portions of the command to their boxes if there were no lines at all. How would you know that the `v` in `tar xzvf foo` matches the 4th box? Having a single line when you hover could help, but sounds confusing for new users that are unaware of this feature.
- tieTYT 13y agoThat's a fair point. What if you put the snippet and the description side by side so you don't even need the arrows? Perhaps like this: tar description1 x description2 z description3 ...
- dzlobin 13y agoHoly moly, this might be one of the best things I've seen on HN in a long time.
- nichochar 13y agoThis is super cool
- jff 13y agoI don't know what I was expecting, but one of my most-used command lines, "du -a | grep foo" is pretty uninformative.
- evanspa 13y agoTried it. The explain read-out seemed reasonable. Care to elaborate how it wasn't informative?
- jff 13y agoThe explanation for "du" and its -a flag make it sound like I'm trying to find out how much disk space my files are using. Fine, that's the usual usage, but the point here is that it lists out every file under the current directory. The bigger problem is grep. We're told that grep prints lines matching a pattern, great. But then the explanation of the arguments makes it sound, to the uninitiated, like I'm giving "foo" as the filename, because the site doesn't include the actual grep syntax. It doesn't really explain what the command line is doing. It does seem to do a decent job of telling someone who's already fluent in shell usage the specific meaning of all options given. That's actually pretty important these days where any given GNU util will have flags for every single letter of the alphabet in both upper and lower case.
- ygra 13y agoThat's not really solvable in this case, though. All explainshell has are the man pages of the commands. It cannot know how they will interact with each other. It should be at least semi-possible in PowerShell (because you have output type information and parameter type information), but I hit a roadblock with ExplainPS a while ago and haven't had the time to resurrect it.
- wilcox 13y agoPerhaps you should go for find . / -name filename instead. Using du -a | grep filename works for sure, but it a bit of hack.
- w1ntermute 13y ago
- uonyx 13y agoNice. Very nice.
- mihok 13y agoI give out this link to all my developers that are just getting a feel for the terminal. Thanks so much for this! A nice to have: Having the command that was originally entered follow you down at the top of the window so when I'm looking at a long piped command, it makes it easier to follow
- k-mcgrady 13y agoReally cool project! I can already see myself using this a lot.
- hndl 13y agoVery cool! It would be great if you would provide common usages for a given command if the user didn't provide any switches. That could be links like the ones you have in the "examples" section on the landing page.
- ivan_ah 13y agoThe UI with the svg "wiring" is awesome. You should consider abstracting away that functionality so that it can be reused by other projects. Right now I'm imagining explainphys ;) where each term in a physics equation is explained e.g. The magnetic force felt by a particle of charge q moving with velocity \vec{v} in a magnetic field \vec{B} is \vec{F}_B = q \vec{v} × \vec{B} | | | | |______magnetic field magnetic force | | | | | cross charge | prod. | velocity of particle
- alecdbrooks 13y agoOr maybe cdecl [0]. [0]: Online version: http://cdecl.org/ http://cdecl.org/.
- Splendor 13y agoAgreed. I would love to see this UI on a RegEx parser too.
- AlwaysBCoding 13y agoCheck out http://www.regexper.com/ http://www.regexper.com/
- Splendor 13y agoI've used that but I think OP's UI is sexier. Thanks though.
- Riseed 13y agoThis is beautiful! It will come in handy for filling in the vast holes in my knowledge. I think it would also make a great resource for those just starting to work with shell. Very well done indeed!
- noonespecial 13y agoSo I fed it : cat ./trunk/.config |awk ' /CONFIG_TARGET_BOARD/ { gsub(/\"/,""); split($0,a,"="); print a[2] }' A little one-liner I worked up a few days ago to quickly show me which architecture my OpenWRT trunk was last built with. I'd really like it to explain in much more detail what each of the terms inside the awk command do. Perhaps make "explain" modular so that people can add more detail to the gazillion things that can happen inside awks, seds, greps, etc? Fabulous idea. This should have been in unix all along as part of the man system.
- angersock 13y agoThat'd be brilliant. We should have a `wtf?` command, used like so: wtf? yes | sudo apt-get install libpq-dev Results would be ncurses, top line of screen is command with current subcommand highlighted, and rest of screen is less'ed explanation.
- idank 13y agoIt's definitely doable to add dedicated parsers for options of awk, sed, et al. But it's a lot of work... I doubt someone will go through the trouble of writing a parser for awk, just for this.. What is possible and quite easy is creating links for things that are explained in other tools, such as linking the regex argument of grep to some site that explains regular expressions, or somehow integrate it into the existing UI.
- SmileyKeith 13y agoThis is fantastic. Even with simple examples like `ls -la` it shows the documentation and other flag synonyms for all of the passed flags. Very impressed.
- TallboyOne 13y agoLots more where that came from (great resource btw!): http://pineapple.io/resources/tagged/bash+terminal http://pineapple.io/resources/tagged/bash+terminal
- nish1500 13y agoI started learning Shell last week. This couldn't have been better timed :)
- fennecfoxen 13y ago:(){ :|:& };: or GTFO :)
- poizan42 13y agoI tried that as well. It says "Missing man page" :(
- denizozger 13y agohttp://explainshell.com/explain?cmd=git http://explainshell.com/explain?cmd=git Funny
- ygra 13y agoIt's what git's man page says: https://www.kernel.org/pub/software/scm/git/docs/ https://www.kernel.org/pub/software/scm/git/docs/
- Theriac25 13y agoDoesn't seem to support backquotes? For example for x in `ls ~/foo`; do echo $x; done doesn't yield anything remotely interesting.
- nailer 13y agoNew style subshells aren't supported (yet) either: for x in $(ls ~/foo); do echo $x; done
- mathattack 13y agoYou know you're on the right track when people are saying, "But why isn't this in there already?"
- JoshTriplett 13y agoThis is quite impressive. I'd love to see the argument explanations narrow down sub-arguments. For instance, "find -type f" ought to just show the top-level description for -type and the description for 'f', not all the other type characters.
- nailer 13y agoGood: it understands &>, which some Unix old-timers don't get. To improve: it didn't provide any context to what $IFS is used for.
- ape4 13y agoIts cool and good but gets into the syntax too quickly. To explain "tar xzvf archive.tar.gz" I would say "extract the archive".
- lelandbatey 13y agoI totally love this, it's already incredibly helpful! It's super-functional, and frankly it's very, very nice looking. To Mr. Idan Kamara, the creator of this, I have nothing but the highest praise! Now, I hate to get side-tracked, but for much larger commands, like this one: ps x -o "%r %c " | grep "someScript.sh" | awk -F' ' '{print $1}' | xargs -I % /bin/kill -TERM -- -% that has a lot of parts, it can be hard to connect the different options to the various explanations[0], since there are so many lines and they frequently have similar colors and you have to keep scrolling up and down the page. Being able to do something like click on a command/option and have the page jump to the corresponding explanation would be very helpful. [0] - http://explainshell.com/explain?cmd=ps+x+-o++%22%25r+%25c+%22+|+grep+%22webLauncher.sh%22+|+awk+-F%27+%27+%27{print+%241}%27+|+xargs+-I+%25+%2Fbin%2Fkill+-TERM+--+-%25 http://explainshell.com/explain?cmd=ps+x+-o++%22%25r+%25c+%2...
- etrain 13y agoVery cool - but support for xargs seems to be broken. find . -type f | xargs wc -l http://explainshell.com/explain?cmd=find+.+-type+f+%7C+xargs+wc+-l http://explainshell.com/explain?cmd=find+.+-type+f+%7C+xargs...
- un1xl0ser 13y agoI would expect xargs to stop processing arguments strictly after the first non-flag argument. Arguments to xargs do appear to be parsed, example below: http://explainshell.com/explain?cmd=find+%2F+-type+f+-print0+%7C+xargs+-0+grep+heythere http://explainshell.com/explain?cmd=find+%2F+-type+f+-print0...
- etrain 13y agoRight, but in this example it's not telling me what the "grep" is doing. Admittedly xargs is a weird case where the arguments to the program are invoked as a program, but I'd say it shows pretty frequently in these type of "what does this long freaking command do?" situations. Maybe worth adding a special case for.
- 13y ago
- eabruzzese 13y agoThis is incredible. One small change request: the longer commands make me scroll down the page, and I can no longer see what each block is pointing to. Maybe you could fix the command to a top-bar as you scroll down?
- ErikRogneby 13y agoFirst of, I love the functionality and clean design. Why are you using bootstrap if the site isn't responsive?
- scott_karana 13y agoIt unfortunately can't decode :(){ :|:& };:, a classic unintelligible forkbomb. I suppose it's only lack of function support that's the issue! Really neat program, nonetheless!
- stonewhite 13y agoSee halting problem
- ErsatzVerkehr 13y agoIt's the halting problem, not the parsing problem.
- ToastyMallows 13y agoIt could just compare the literal string and have static explanation just for this command.
- idank 13y agoI'm tempted to add a place holder for all the variations of this forkbomb, until I teach the parser about functions. You'll be amazed how many people try this (or other 'malicious' commands), presumably thinking I'm executing the queries. ;)
- akincisor 13y agoI tried this, but not because I believed that you would execute it, but because a very important use of such a tool would be to explain potentially dangerous commands and their implications.
- redwall_hp 13y agoI searched the classic sudo rm -rf /, too. Just to see if it would adequately explain it.
- Procrastes 13y agoI agree it's beautiful, and a really great idea. I'll also add my vote that this would make an even better commandline tool. It had difficulty with: find . -name ".cpp" | xargs -i grep -His "oops" "{}" http://explainshell.com/explain?cmd=find+.+-name+%22*.cpp%22+|+xargs+-i+grep+-His+%22oops%22+%22{}%22 http://explainshell.com/explain?cmd=find+.+-name+%22*.cpp%22... It seems to think the -His belongs to xargs rather than grep.
- kin 13y agoYup, just shared with my whole office. Super useful for all levels. Thanks for this.
- TorKlingberg 13y agoVery neat! I did choke at the end of this little favorite: find -name "*.[hc]" -o -name "*.[hc]pp"|xargs grep -siP 'apa'
- njharman 13y agoSource https://github.com/idank/explainshell https://github.com/idank/explainshell This is truly stunning. It's a small thing, and what it does is not stupendous. But the design, aesthetics, ease of use, in a word elegance makes the combined whole a superlative tool.
- wila 13y agoGreat tool. Would have preferred to use it locally without all of those dependencies on a machine without networking. But OTOH having it online means that it is easier to centrally manage and update.
- mmgutz 13y agoVery useful. Good job.
- Xelom 13y agoBeautiful. Can't describe with words...
- ChuckMcM 13y agoVery nice. It was challenged by my go to command: tar cf - . | (cd /dest/dir ; tar xvf -) Which uses tar to copy a directory tree. It didn't know '.' stood for the current directory, it missed out that 'f -' was the file "standard in" / "standard out"
- gahahaha 13y agoWhy do you use that instead of cp -R ? I would normally only use your version if I was copying a directory tree over ssh.
- Aissen 13y agoI think you mean cp -a. cp -R doesn't preserve permissions and other goodies of tar.
- ChuckMcM 13y agoGenerally tar to tar transfers have a couple more options, one being not to step across file systems, one being to keep symlinks intact (or not), and one being to avoid filling in 'holey' files. Of course those things might not be true any more, basically I got habituated to using it when I was Sun and it continues to work, so my fingers haven't tried to learn a new pattern.
- b0rsuk 13y agoIt's surprisingly good, overall, but there are some glaring omissions. For instance: sudo apt-get install tree Only sudo is explained. I understand apt-get is distro-specific, but it's widespread enough to deserve a special case. Interestingly, apt-get install tree (without sudo) works better. Common, widely known system configuration files like /etc/issue, /etc/hosts, /etc/hostname, /etc/fstab ... deserve to be special-cased, too. Many of them actually have their man pages, so it's possible to script.
- idank 13y agoTrue, it doesn't figure out that some commands should be matched recursively since their arguments are other commands, xargs is also in the same boat. There might be an open bug for this already. I only scanned sections 1 and 8 of the man page archive, so that's why files are missing.. but they can be added.
- emeraldd 13y agoIt's a nice toy, but seems to break down with more interesting stuff. For instance: for FILE in `ls`; do echo $FILE ; done http://explainshell.com/explain?cmd=+for+FILE+in+%60ls%60%3B+do+echo+%24FILE+%3B+done http://explainshell.com/explain?cmd=+for+FILE+in+%60ls%60%3B... That's a simpler equivalent of something I cooked up which probably didn't belong in a single line of shell anyhow.
- idank 13y agoYou've hit the two top things on my to do list.. command substitution and control flows. It says on the top of the home page that they're not implemented yet.
- emeraldd 13y agoThat's what I get for trying to play with a new site after Thanks Giving weekend! You already have a solid tool, that will make it even better ;)
- cheeseprocedure 13y agoThis is brilliant. (I've forwarded it to novices and pros alike, and everyone else's response has been much the same.) If you were to open up donations to support development, I would HAPPILY contribute.
- idank 13y agoThanks! I work full-time right now, so money isn't really an issue. I'll gladly accept commits though! ;)
- harichinnan 13y agoFound a minor defect. cat fil*.dat | head -100 | tail -20. Does not explain -100 in head and -20 in tail.
- patriciaecastro 13y agomy best friend's aunt makes $86 hourly on the computer. She has been unemployed for 8 months but last month her pay was $12133 just working on the computer for a few hours. you can try here======> http://www.jobs25.com http://www.jobs25.com
- patriciaecastro 13y agomy best friend's aunt makes $86 hourly on the computer. She has been unemployed for 8 months but last month her pay was $12133 just working on the computer for a few hours. you can try here======> www.jobs25.com
- emiliobumachar 13y agoGreat! This could serve as an example for help sites about other shell-like environment.
- pmattos 13y agoStuff of dreams!
- deft0nes 13y agoTotally awesome!
- social_monad 13y ago# this command fails to explain: : abc $(xclock) def
- NovaS1X 13y agoHaha! This is brilliant!
- un1xl0ser 13y agoAmazing tool for beginners, but also helpful for advanced users. GREAT: find / -type f -print0 |xargs -0 grep heythere I tried some sub-shells, and seemed to not work so well. $() and `` would be nice. ps -fp $(pgrep -d, krb5kdc) ps -fp `pgrep -d, krb5kdc` http://explainshell.com/explain?cmd=ps+-fp+%24%28pgrep+-d%2C+krb5kdc%29 http://explainshell.com/explain?cmd=ps+-fp+%24%28pgrep+-d%2C... edit: newlines
- rbosinger 13y agoWow. I've only tried a few queries but they worked well! This could be great for breaking down some of the "copy paste to install this" commands you see from open-source projects.
- quickpost 13y agoThis is awesome. Best post I've seen on HN in a while.
- parallelist 13y agoNothing useful said for: for word in foo bar baz; do echo $word; done Seems to think COLUMNS is a command in: COLUMNS=20 ls
- garrettdreyfus 13y agoIt's like shellgenius.
- garrettdreyfus 13y agoIt's like shellgenius.
- garrettdreyfus 13y agoIt's like shellgenius.
- fernly 13y agoImpressive but I agree with all who said you can't read the callouts below the 2nd or 3rd, because you have to scroll, which loses the focus on the item. I think it might work better if you just pop up one explanation box at a time, directly below the command, as the mouse sweeps across. Also missing some obvious things like on this basic zip command [0]. It can't explain -9, probably because that's not in the man page as itself but as "-n". But also has nothing to offer about the zip file target or the input folder, which are in the man page as symbolic arguments. [0] http://explainshell.com/explain?cmd=zip+-vr9+foo.zip+somefolder http://explainshell.com/explain?cmd=zip+-vr9+foo.zip+somefol...
- gocha9921 13y agoI am new to command line - but this is awesome! VERY helpful. Thanks and congrats!
- paulasmith 13y agoFantastic tool, kudos!!!!
- gtallen1187 13y agothis is great - i have had a hard time learning shell and this is a huge help. thank you!!!
- droid_w 13y agoFantastic! I love your UI.
- SimHacker 13y agoThis is a wonderful idea and an upstanding social service, in the same vein of giving heroin addicts access to free clean needles, pure heroin, and a safe place to shoot up. There is no perfect solution -- in the ideal world, everyone would use safe healthy programming languages, and nobody would be addicted to shell scripting. But in the real world, many people still choose to use shell scripting as a quick and easy short term solution to their problems. Like the unhealthy temptation to use regexps for parsing html, shell scripting just causes more problems, which snowball out of control until you have the dire situation we're in today, with a whole generation of urban hipsters who learned cargo-cult cut-n-paste shell scripting by typing "more ./configure". So it's much better to treat shell scripting as a health problem rather than a criminal problem. My only suggestion is that you should sponsor links to "recovery programs," where people can learn to solve their problems with safe healthy programming languages instead of shell scripts. For the popular rube-goldbergesque shell incantations, you could show how to accomplish the same thing more comprehensibly in Python, Ruby, JavaScript, Lisp, Forth, Mathematica, Quartz Composer, etc. ;)
- gjarkko 13y agovpenis.sh also has trouble explaining. It's a bit of a challenge for anyone, though. echo `uptime|grep days|sed 's/.up \([0-9]\) day.*/\1\/10+/'; cat \ /proc/cpuinfo|grep '^cpu MHz'|awk '{print $4"/30 +";}';free|grep \ '^Mem'|awk '{print $3"/1024/3+"}'; df -P -k -x nfs | grep -v \ 1k | awk '{if ($1 ~ "/dev/(scsi|sd|md)"){ s+= $2} s+= $2;} END \ {print s/1024/50"/15+70";}'`|bc|sed 's/\(.$\)/.\1cm/
- samsosina 13y agoStraight to my bookmark bar!
- kfk 13y agoHey, very nice! What about allowing users to take notes and tags on the search results? I have a bunch of bash commands I run I always forget, this would help me a lot to keep track of things (like all the ssh-ing stuff that I can't seem to fit in my memory...).
- ananth99 13y agoInsane stuff!
- daGrevis 13y agoIt says that `-h` in `shutdown` stands for help, not halt. Otherwise, seems as a useful tool! :)
- trurl42 13y agoIt fails to parse the command if you start with a redirect. http://explainshell.com/explain?cmd=%3E+foo http://explainshell.com/explain?cmd=%3E+foo
- Arnor 13y agoAwesome tool. Now can we have one that does the same thing for a regexps?
- pixelmonkey 13y agoReally cool. A suggestion. For long explains, it'd be great to be able to click on the part to jump to that part of the explanation, and then offer some way to "jump back to top". Alternatively, I was thinking there might be a nice "swipe" or "carousel" interface applicable here. e.g. you hit left/right arrows and it explains every individual atom of the command-line. That said, very nice as it is now. You deserve major kudos simply for bringing most manpages online in a searchable, good-looking interface! Instantly added as a "dev" bookmark for me.
- D9u 13y agoThe site doesn't mention the !! command. The !! command is used to repeat the previously issued command.
- DonGateley 13y agoI'd like it if hovering on a parsed item moved it's explanation to the top rather than just highlighting it. Not so much scrolling required if any.
- mumoksha 13y agoNice!!!!!
- bonemachine 13y agoReally liking this.
- willfiveash 13y agoDoesn't yield anything particularly useful for: [[ -f /tmp/foo ]] && echo yes