rename: listusers.sh -> userlist.macosx.sh
authorAlexander Barton <alex@barton.de>
Mon, 28 Sep 2009 10:22:47 +0000 (12:22 +0200)
committerAlexander Barton <alex@barton.de>
Mon, 28 Sep 2009 10:22:47 +0000 (12:22 +0200)
listusers.sh [deleted file]
userlist.macosx.sh [new file with mode: 0755]

diff --git a/listusers.sh b/listusers.sh
deleted file mode 100755 (executable)
index f9f0f2f..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/bin/bash
-
-while [ -n "$1" ]; do
-       case "$1" in
-       "--all"|"-a")
-               ALL=1
-               ;;
-       "--local"|"-l")
-               LOCAL=1
-               ;;
-       *)
-               echo "Usage: $0 [--local|-l]"
-               exit 1
-       esac
-       shift
-done
-
-sw_vers -productName | grep -i "Server" >/dev/null 2>&1
-if [ $? -eq 0 -a -z "$LOCAL" ]; then
-       # Mac OS X Server
-       OD=1
-fi
-
-if [ -n "$OD" ]; then
-       HOST="localhost"
-       USER_BASE="/LDAPv3/127.0.0.1/Users"
-       UID_MIN=1000
-else
-       HOST="."
-       USER_BASE="/Users"
-       UID_MIN=500
-fi
-
-[ -n "$ALL" ] && UID_MIN=0
-
-dscl "$HOST" -list "$USER_BASE" | while read x; do
-       declare -i id
-       id=`dscl "$HOST" -read "$USER_BASE/$x" UniqueID | cut -d: -f2`
-       if [ "$id" -gt $UID_MIN ]; then
-               echo " $id: $x"
-       fi
-done | sort -n
-
-# -eof-
diff --git a/userlist.macosx.sh b/userlist.macosx.sh
new file mode 100755 (executable)
index 0000000..f9f0f2f
--- /dev/null
@@ -0,0 +1,44 @@
+#!/bin/bash
+
+while [ -n "$1" ]; do
+       case "$1" in
+       "--all"|"-a")
+               ALL=1
+               ;;
+       "--local"|"-l")
+               LOCAL=1
+               ;;
+       *)
+               echo "Usage: $0 [--local|-l]"
+               exit 1
+       esac
+       shift
+done
+
+sw_vers -productName | grep -i "Server" >/dev/null 2>&1
+if [ $? -eq 0 -a -z "$LOCAL" ]; then
+       # Mac OS X Server
+       OD=1
+fi
+
+if [ -n "$OD" ]; then
+       HOST="localhost"
+       USER_BASE="/LDAPv3/127.0.0.1/Users"
+       UID_MIN=1000
+else
+       HOST="."
+       USER_BASE="/Users"
+       UID_MIN=500
+fi
+
+[ -n "$ALL" ] && UID_MIN=0
+
+dscl "$HOST" -list "$USER_BASE" | while read x; do
+       declare -i id
+       id=`dscl "$HOST" -read "$USER_BASE/$x" UniqueID | cut -d: -f2`
+       if [ "$id" -gt $UID_MIN ]; then
+               echo " $id: $x"
+       fi
+done | sort -n
+
+# -eof-