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

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. Use our Linode referral link if you plan to buy VPS (it starts at only $10/month).
  4. Support us via PayPal donate - Make a Donation
  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.

Receive Your Free Complimentary eBook NOW! -

Download Free Linux eBooks

Linux BASH Programming Cookbook
Getting Started with Ubuntu 16.04
A Newbie's Getting Started Guide to Linux
Introduction to Linux - A Hands on 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.

    • Avishek Kumar says:

      Dear Shad,
      The issue in the code has been fixed. Please use the new code after refreshing the page.

  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.
      avi@deb:~$ 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 *

Join Over 300K+ Linux Users
  1. 177,942
  2. 8,310
  3. 37,548

Are you subscribed?