Saturday, January 25, 2014

Mac OS X Profile

In case you need to update or create a new profile for Mac OS X, add new aliases or functions. This are the files I use to do that in Mac OS X. This also help me every time I reinstall my Mac.

~/.bash_profile
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
    . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH

~/.bashrc
# .bashrc

# Source global definitions
if [ -f /etc/bashrc ]; then
    . /etc/bashrc
fi

# User specific aliases and functions

/etc/profile
Add these lines to the end:
# color-ls initialization

alias ll='ls -lG' 2>/dev/null
alias la='ls -alG' 2>/dev/null
alias l.='ls -dG .*' 2>/dev/null
alias ls='ls -G' 2>/dev/null
Post a Comment