Super User is a question and answer site for computer enthusiasts and power users. 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

For some reasons i always get the following whenever i log into my terminal:

: command not found
: command not found
: command not found
: command not found
: command not found

It's really a minor problem because everything is working fine, or at least everything what im using in the terminal. Still it would just look nicer without them. Any help?

I'm running Mac OS 10.5.8 <= if this helps solving the problem

share|improve this question

migrated from Apr 20 '10 at 14:02

This question came from our site for professional and enthusiast programmers.

You probably have some garbage in your .login or .profile.

share|improve this answer

Places to look:

  • System shell startup files -- /etc/profile, /etc/bashrc
  • Personal startup files -- $HOME/.profile, $HOME/.bashrc, $HOME/.bash_profile

(this all assumes you're using bash as your shell)

Try running the scripts using the -x option to show the commands and their output to help you identify the troublesome lines:

$  bash -x /etc/bashrc
+ '[' -z '' ']'
+ return
/etc/bashrc: line 3: return: can only `return' from a function or sourced script
+ PS1='\h:\W \u\$ '
+ shopt -s checkwinsize

The lines preceded by + show the commands which will be executed. Output (if any) is shown in between.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .