Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

When I open a new terminal I don't get the prompt I setup in ~/.bashrc or my aliases etc... If I run exec $SHELL then everything applies like it should for example:

Last login: Mon Jan  7 09:02:00 on console
osiris:~ adam$ exec $SHELL
[09:03:32][adam@osiris][~] 

How do I get it to run everything on startup like it should?

share|improve this question
add comment

1 Answer

up vote 4 down vote accepted

The Mac OS X Terminal, in contrast to most other terminals, runs a login shell by default.

This means that .bashrc is not called. It will run .bash_profile instead, so you should source your .bashrc from there to have it executed.

See man bash, section "Invocation" for more info, as well as this blog article by Josh Staiger: .bash_profile vs .bashrc

share|improve this answer
    
Thanks! I knew it would be something simple –  Arcath Jan 7 '13 at 9:32
add comment

Your Answer

 
discard

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.