Ask Different is a question and answer site for power users of Apple hardware and software. 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

I don't know how to get my .profile aliases back in to the terminal every time I try them, this error massage comes up:

apaw:~ apaw$ cdp
-bash: cdp: command not found

How do i exit this -bash? I strongly believe it was named different while it still worked.

share|improve this question

I'm not sure I understand your question.

The -bash: prefix you see is simply bash's way of identifying itself as the source of the error message. In this case you entered cdp which is neither an external nor internal shell command nor was it defined as an alias or function.

While in a (bash) terminal, you can simply type exit to leave the terminal and close the shell session.

The aliases in your .profile are read when you start a new terminal or shell session, or if you source the files: e.g. source ~/.profile. That should re-read your .profile and load any changed aliases.

share|improve this answer
up vote 0 down vote accepted

Okay, I've found out what the problem was, some script has created a .bash_profile file that was overriding my .profile file, now I've removed the .bash_profile file and it works again!

share|improve this answer
I recommend using .bash_profile instead of .profile, especially if it contains any bash-specific code. Also, if you're not already doing it this way: you should generally place customizations in .bashrc and have .bash_profile source .bashrc. .bashrc applies to login and non-login shells, but .profile (and .bash_profile) only apply to login shells. – Chris Page Nov 9 '11 at 14:07

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.