Moved detecthost to after detectdistro and made OS X output remove '.local' from hostname.

This commit is contained in:
Brett Bohnenkamper
2013-06-13 00:29:20 -05:00
parent fe5dc7ba99
commit 65ab4f90a6

View File

@@ -282,14 +282,6 @@ fi
# Begin Detection Phase
#########################
# Host and User detection - Begin
detecthost () {
myUser=${USER}
myHost=${HOSTNAME}
[[ "$verbosity" -eq "1" ]] && verboseOut "Finding hostname and user...found as '$myUser@$myHost'"
}
# Distro Detection - Begin
detectdistro () {
if [[ -z $distro ]]; then
@@ -601,6 +593,14 @@ detectdistro () {
}
# Distro Detection - End
# Host and User detection - Begin
detecthost () {
myUser=${USER}
myHost=${HOSTNAME}
if [[ "${distro}" == "Mac OS X" ]]; then myHost=${myHost/local/}; fi
[[ "$verbosity" -eq "1" ]] && verboseOut "Finding hostname and user...found as '$myUser@$myHost'"
}
# Find Number of Running Processes
# processnum="$(( $( ps aux | wc -l ) - 1 ))"
@@ -2533,7 +2533,7 @@ asciiText () {
"Android")
if [[ "$no_color" != "1" ]]; then
c1="\e[1;37m" # White
c1="\screens.kittykatt.use[1;37m" # White
c2="\e[1;32m" # Bold Green
fi
if [ -n "${my_lcolor}" ]; then c1="${my_lcolor}"; fi