[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Health] bash_profile
From: |
Chris |
Subject: |
Re: [Health] bash_profile |
Date: |
Wed, 23 Apr 2014 00:17:51 -0700 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
Hiya!
> I'd like to know whats in the bash_profile.
Sorry if this is completely misleading, but I quickly looked through the
gnuhealth_install.sh script for relevant bash_profile stuff. Here is the
function that seems relevant:
bash_profile () {
...blah...
# Load .gnuhealthrc from .bash_profile . If .bash_profile does not exist,
create it.
if [ -e $HOME/.bash_profile ] ; then
grep --silent "source ${PROFILE}" $HOME/.bash_profile || echo "[[ -f
${PROFILE} ]] && source ${PROFILE}" >> $HOME/.bash_profile
else
echo "[[ -f ${PROFILE} ]] && source ${PROFILE}" >> $HOME/.bash_profile
fi
}
So... it checks whether bash_profile is sourcing PROFILE
(= $HOME/.gnuhealthrc)... if not, it modifies it to source it.
Here is the gnuhealthrc file:
export EDITOR=vi
if ! type $EDITOR >/dev/null ; then
echo "$EDITOR not found"
fi
# Aliases
alias cdlogs='cd $HOME/gnuhealth/logs'
alias cdexe='cd $HOME/gnuhealth/tryton/server/trytond-*/bin'
alias cdconf='cd $HOME/gnuhealth/tryton/server/trytond-*/etc'
alias cdmods='cd $HOME/gnuhealth/tryton/server/modules'
alias editconf='${EDITOR}
$HOME/gnuhealth/tryton/server/trytond-*/etc/trytond.conf'
alias rm='rm -i'
alias mv='mv -i'
alias cp='cp -i'
alias ls='ls --color=auto'
#Prompt
PS1="\[\e[32;address@hidden:\[\e[30;0m\]\w $ \[\e[0m\]"
So... aliases, editor, and prompt. Not that important. Unless I'm
missing something, hehe.
-C