I'm starting to use command line a little more, and I see there are a lot of ways to configure some config files in my $HOME. This is good, since you can customize it the way you really like.

Unfortunately, for begginners, having too many options is a little confusing. For example, I created .bash_alias for some alias I'm using. I didn't even know this option existed, I'm used to simply edit .bashrc.

Do exist a pattern, a "good practice", envisioning flexibility and modularity in terms of rc files structure? Do exist a standardization group for this, or every body just creates it's own configuration setup?


the configuration files are all dependent upon the software that uses them. in most cases, the file is named .<programname>rc in some cases it's a config file in a 'hidden' . directory, i.e. ~/.fluxbox/init

there is nothing wrong with putting your aliases in the .bashrc file, .bash_alias is another shell script called from within .bashrc, some people just like to segregate their configurations while others, like me, prefer putting all our related configurations in the same file, for easy management.

in my .bashrc there is:

#if [ -f ~/.bash_aliases ]; then
#    . ~/.bash_aliases

which is what i presume is in yours, only not commented out, meaning it checks that .bash_alias is a file, and then 'sources' it into the .bashrc file (that's what . ~/.bash_alias means, . in this case is a shortcut for source)

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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