]> arthur.barton.de Git - ConfigScripts.git/commitdiff
Make sure that $UID is set.
authorAlexander Barton <alex@barton.de>
Thu, 7 Aug 2008 16:56:37 +0000 (18:56 +0200)
committerAlexander Barton <alex@barton.de>
Thu, 7 Aug 2008 16:56:37 +0000 (18:56 +0200)
install.sh

index 6804f0bfae4f0740d0684cb6ce61f2eb911cc394..c7e7d257964c96e5bbcc03852b0041d5ce18dc97 100755 (executable)
@@ -28,9 +28,12 @@ Copy_File() {
        echo "- OK."
 }
 
-echo "Running $NAME ..."
+[ -n "$UID" ] || UID=`id -u`
+export UID
 
-if [ "$UID" -eq 0 ]; then
+echo "Running $NAME (uid=$UID) ..."
+
+if [ "$UID" = "0" ]; then
        echo "Starting system configuration:"
        echo " - bash shell:"
        if [ -e /etc/bash.bashrc ]; then