1
0
mirror of https://github.com/wting/autojump synced 2024-10-27 20:34:07 +00:00
This commit is contained in:
GitHub Merge Button 2011-11-29 12:27:31 -08:00
commit 310e25bf07

View File

@ -23,7 +23,12 @@ function show_help {
prefix=/usr prefix=/usr
user=${SUDO_USER:-${USER}} user=${SUDO_USER:-${USER}}
OS=`uname`
if [ $OS == 'Darwin' ]; then
user_home=$(dscl . -search /Users UniqueID ${user} | cut -d: -f6)
else
user_home=$(getent passwd ${user} | cut -d: -f6) user_home=$(getent passwd ${user} | cut -d: -f6)
fi
bashrc_file=${user_home}/.bashrc bashrc_file=${user_home}/.bashrc
# Command line parsing # Command line parsing