diff options
Diffstat (limited to 'comms/gnokii/scripts/creategroup')
-rw-r--r-- | comms/gnokii/scripts/creategroup | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/comms/gnokii/scripts/creategroup b/comms/gnokii/scripts/creategroup new file mode 100644 index 000000000000..ce829947a3fb --- /dev/null +++ b/comms/gnokii/scripts/creategroup @@ -0,0 +1,16 @@ +#!/bin/sh + +PATH=/bin:/usr/sbin + +GROUP=gnokii + +if pw group show "${GROUP}" 2>/dev/null; then + echo "You already have a group \"${GROUP}\", so I will use it." +else + if pw groupadd ${GROUP}; then + echo "Added group \"${GROUP}\"." + else + echo "Adding group \"${GROUP}\" failed..." + exit 1 + fi +fi |