From 87a76f2e41be39694c50a8789e0ead03be059c38 Mon Sep 17 00:00:00 2001 From: Greg Lewis Date: Fri, 5 Sep 2003 22:26:41 +0000 Subject: . 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." --- games/ldmud/pkg-install | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 games/ldmud/pkg-install (limited to 'games/ldmud/pkg-install') diff --git a/games/ldmud/pkg-install b/games/ldmud/pkg-install new file mode 100644 index 000000000000..575cbe714897 --- /dev/null +++ b/games/ldmud/pkg-install @@ -0,0 +1,37 @@ +#!/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 -- cgit v1.2.3