freebsd-ports/games/ldmud/pkg-install
Greg Lewis 87a76f2e41 . Add a port of the LDMud driver (with optional 2.4.5 mudlib).
"LDMud started as a project to clean up and modernize Amylaar's LPMud
 gamedriver. Primary goals are full documentation, a commented source
 body and out-of-the-box support for the major mudlibs, of which the
 commented source body has been pretty much completed. During the
 course of work a lot of bug fixes and improvements found their way
 into the driver - much more than originally expected, and definitely
 enough to make LDMud a driver in its own right."
2003-09-05 22:26:41 +00:00

37 lines
683 B
Bash

#!/bin/sh
# $FreeBSD$
if [ "$2" = "PRE-INSTALL" ]; then
exit 0
fi
PATH=/bin:/sbin:/usr/bin:/usr/sbin
USER=mud
GROUP=${USER}
UID=97
GID=${UID}
if pw groupshow "${GROUP}" 2>/dev/null; then
echo "Using existing group \"${GROUP}\"."
else
if pw groupadd "${GROUP}" -g ${GID}; then
echo "Added group \"${GROUP}\"."
else
echo "Adding group \"${GROUP}\" failed..."
exit 1
fi
fi
if pw usershow "${USER}" 2>/dev/null; then
echo "Using existing user \"${USER}\"."
else
if pw useradd "${USER}" -u ${UID} -g "${GROUP}" -h - \
-s "/bin/sh" -d "/nonexistent" -c "MUD Owner"
then
echo "Added user \"${USER}\"."
else
echo "Adding user \"${USER}\" failed..."
exit 1
fi
fi