If you do, or want to do a lot of command line stuff, you may want to consider a few more variables.
Here's my .bash_profile.
- Code: Select all
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
# User specific environment and startup programs
set -o vi
export PATH LS_OPTIONS TERM LESS EDITOR
alias ll='ls -lh $LS_OPTIONS'
alias llm='ls -alh $LS_OPTIONS| less'
alias lrt='ls -alhrt $LS_OPTIONS'
alias ls='ls $LS_OPTIONS'
alias lsd='ls -lhd */ 2>/dev/null $LS_OPTIONS'
alias lsnd='ls -lh |grep -v ^d $LS_OPTIONS'
alias df="df -h"
As you can see the variables are set individually, then exported on a single line. Exporting variables makes them global. That is to say that other instances of the shell can see them.
Oh yea, make sure to read the man pages for the terminal you want use. Usually a -ls will make it a login session and read the .bash_profile in. Most support it in one form or another.
I use ksh by preference, but I tested this with bash and everything should work fine.
I'd rather have a bottle in front of me than a frontal lobotomy.