Understanding Shell Commands Easily Using “Explain Shell” Script in Linux

Best Affordable Linux and WordPress Services For Your Business
Outsource Your Linux and WordPress Project and Get it Promptly Completed Remotely and Delivered Online.

If You Appreciate What We Do Here On TecMint, You Should Consider:

  1. Stay Connected to: Twitter | Facebook | Google Plus
  2. Subscribe to our email updates: Sign Up Now
  3. Get your own self-hosted blog with a Free Domain at ($3.45/month).
  4. Become a Supporter - Make a contribution via PayPal
  5. Support us by purchasing our premium books in PDF format.
  6. Support us by taking our online Linux courses

We are thankful for your never ending support.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide

You may also like...

13 Responses

  1. Anne says:

    looking for a person who has an idea how to do this:

    Create a bash-shell script called terminator that
    terminates all processes of a name given to the shell
    script as an argument.
    (Guidance: pidof, ps –ef , awk)

    if anyone has an idea please let me know :)

  2. SDF says:

    This is a rather lame utility that gives you very, very little that you can’t get with the ‘man’ command. As the old saying goes, this is a utility that fills a much-needed gap in the Linux world.

  3. minicast says:

    I had the same problem as @aligaligari
    I am using Ubuntu and in my man page for curl the “–data-ur” option is not listed (only “–data-urlencode”)
    However, I managed to run the explain command after changing the script as follows:

    # explain.sh begins
    explain () {
    if [ “$#” -eq 0 ]; then
    while read -p “Command: ” cmd; do
    # curl -Gs “https://www.mankier.com/api/explain/?cols=”$(tput cols)–data $
    curl -Gs “https://www.mankier.com/api/explain/?cols=70&q=”$cmd
    echo “Bye!”
    elif [ “$#” -eq 1 ]; then
    # curl -Gs “https://www.mankier.com/api/explain/?cols=”$(tput cols) –data-ur $
    curl -Gs “https://www.mankier.com/api/explain/?cols=70&q=”$1
    echo “Usage”
    echo “explain interactive mode.”
    echo “explain ‘cmd -o | …’ one quoted command to explain it.”

  4. Shad says:

    Same problem that @aligaligari. (hard to write :p )

    I have tried with other commands but the problem is still here.

    I use Ubuntu 15.04.

  5. paco says:

    Exactly the same result as aligaligari in both Debian Jessie and Sid. Whatever the command.

  6. aligaligari says:

    # explain ‘du -h’
    curl: option –data-ur-$: is unknown
    curl: try ‘curl –help’ or ‘curl –manual’ for more information

    What’s going on? :-/

    • Avishek Kumar says:


      When i run the same command, here is what i get.
      [email protected]:~$ explain ‘du -h’

      Summarize disk usage of the set of FILEs, recursively for directories.
      Mandatory arguments to long options are mandatory for short options too.

      -h (-h, –human-readable)
      print sizes in human readable format (e.g., 1K 234M 2G)

      are you able to explain other shell command? Is the problem with this command only or every other command? Please check the code you pasted in your .bashrc file. Also let us know your distribution and release. If you are unable to resolve you may forward me SSH credentials at avishek1210[at]gmail.com

      • wally says:

        i get exact same thing when run the command:
        curl: option –data-ur$: is unknown
        curl: try ‘curl –help’ or ‘curl –manual’ for more information

        uname -a
        Linux valinux 2.6.32-431.el6.x86_64 #1 SMP Sun Nov 10 22:19:54 EST 2013 x86_64 x86_64 x86_64 GNU/Linux

        curl –version
        curl 7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/ zlib/1.2.3 libidn/1.18 libssh2/1.4.2
        Protocols: tftp ftp telnet dict ldap ldaps http file https ftps scp sftp
        Features: GSS-Negotiate IDN IPv6 Largefile NTLM SSL libz

        • Avishek Kumar says:

          Dear wally,
          The code has been fixed. Clear cache and Refresh page. Use the new code.
          If any issue let me know.

    • Avishek Kumar says:

      sorry for the inconvenience @aligaligari,
      There was a small error in the code which is fixed now.
      Please clear the cache, Refersh this page and use the code above.
      If any issue, don’t mind to ping me.

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.