# HG changeset patch # User Igor Chubin # Date 1328109294 -7200 # Node ID d775ffd49dbfe92030739f7e794dc1339e18ba1b # Parent 137cf5a580be65ac46a9f473e6d6471cf80f0e0f minifix: bsd/darwin in uname diff -r 137cf5a580be -r d775ffd49dbf install --- a/install Mon Nov 28 13:26:46 2011 +0200 +++ b/install Wed Feb 01 17:14:54 2012 +0200 @@ -1,7 +1,7 @@ #!/bin/sh hostname=`hostname` -uname -a | grep -qi freebsd || hostname=`hostname -f` +uname -a | egrep -qi '(freebsd|darwin)' || hostname=`hostname -f` ############################################################################### # @@ -30,7 +30,7 @@ apt_get_install_this="perl make libmodule-build-perl libc6-dev gcc" wget=wget -uname -a | grep -qi bsd && wget=fetch +uname -a | egrep -qi '(bsd|darwin)' && wget=fetch normC='\033[0;39m' whiteC='\033[1;37m' @@ -79,7 +79,7 @@ get_user_home() { - uname -a | grep -qi freebsd && pw user show "$@"| awk -F: '{print $9}' || getent passwd "$@"| awk -F: '{print $6}' + uname -a | egrep -qi '(freebsd|darwin)' && pw user show "$@"| awk -F: '{print $9}' || getent passwd "$@"| awk -F: '{print $6}' } install_to_users_homes() diff -r 137cf5a580be -r d775ffd49dbf l3bashrc --- a/l3bashrc Mon Nov 28 13:26:46 2011 +0200 +++ b/l3bashrc Wed Feb 01 17:14:54 2012 +0200 @@ -44,7 +44,7 @@ # and del vvvv this if it does export L3_TTY=`/usr/bin/tty` - uname -a | grep -qi bsd && bsd=yes + uname -a | egrep -qi '(bsd|darwin)' && bsd=yes proc_on_the_term=`w | grep "${L3_TTY##/dev/}" | awk '{print $8;}'` # freeBSD: [ -n "$bsd" ] && \ @@ -60,7 +60,7 @@ mkdir -p $L3_HOME tty=`/usr/bin/tty` - uname -a | grep -qi bsd && bsd=yes + uname -a | egrep -qi '(bsd|darwin)' && bsd=yes parent=`cat /proc/$PPID/cmdline 2> /dev/null` [ -z "$parent" ] && parent="`ps waux | awk '{if ($2 == '$PPID') print $11; }'`" system=`uname -rs` @@ -92,7 +92,7 @@ _l3_run_script() { - uname -a | grep -qi bsd && bsd=yes + uname -a | egrep -qi '(bsd|darwin)' && bsd=yes flush="-f" #linux [ -n "$bsd" ] && flush="-t 0" #freebsd export L3_PARENT_TTY=`/usr/bin/tty`