Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The '$' command gives the result and then outputs "command not found" in the terminal?

share|improve this question
There is no '$' command so the message is accurate. It may be helpful to know what you were attempting to accomplish so we could be of more help. At the command line you can enter: filenames for files in your PATH, and shell commands and aliases. You can use the apropos keyword and then man command_name to find information about the former, and a command like man bash (if you use the bash shell) to find information about the latter. – John S Gruber May 24 '12 at 4:05
up vote 1 down vote accepted

The original question listed '$0', which is a positional parameter, not a command.

To display it's value without an error you should use

 echo "$0"
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.