Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
You can create it, but it may not get executed. The order in OS X is:

1. .bash_profile
2. .bash_login
3. .profile

So you may want to edit or create a .bash_profile instead. Or you could create .profile and add this to .bash_profile:

Code:
if [ -e ~/.profile ]; then
     source ~/.profile
fi

This way it will get called. There is then the difference of interactive non-login shells and login shells, but we won't worry about that.
 
ah ok... Does that mean that it's no use to have more than the .bash_profile? Or does .bash_login and .profile do different things?

So what's the .bashrc for?
 
ah ok... Does that mean that it's no use to have more than the .bash_profile? Or does .bash_login and .profile do different things?

Technically, they should do different things. But they do not have to do different things.

I would just work with the .bash_profile for now.
 
And .bashrc is for what?

Thanks for the help mate :)

That is the distinction I mentioned.

.bashrc gets executed for interactive non-login shells while .bash_profile is executed for login shells.

You may want to spend some time reading the bash man page:

Code:
man bash

It covers many of these things in the "Invocation" section.
 
Ok, I've read it. I didn't understood lots of things. But at least got the notion of what is a interactive and non-interactive shell.

One thing I don't get thou... I've erased my bashrc (totally blank now), but it still appears this when I start the shell:

Code:
MacBook-de-Pedro-Gordo:~ Pedro_Gordo$ bash
bash: {rtf1ansiansicpg1252cocoartf1038cocoasubrtf290: command not found
bash: {fonttbl}: command not found
bash: /Users/Pedro_Gordo/.bashrc: line 3: syntax error near unexpected token `}'
bash: /Users/Pedro_Gordo/.bashrc: line 3: `{\colortbl;\red255\green255\blue255;}'
bash-3.2$

Any idea what this is and how may I solve it?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.