]> andersk Git - moira.git/commitdiff
Add shell script for installing the warehouse data files.
authortytso <tytso>
Mon, 3 Mar 1997 19:32:24 +0000 (19:32 +0000)
committertytso <tytso>
Mon, 3 Mar 1997 19:32:24 +0000 (19:32 +0000)
gen/warehouse.sh [new file with mode: 0644]

diff --git a/gen/warehouse.sh b/gen/warehouse.sh
new file mode 100644 (file)
index 0000000..bcba7a6
--- /dev/null
@@ -0,0 +1,33 @@
+#!/bin/sh
+#
+#
+DIR=/warehouse/transfers/moirausr
+TAR_FILE=$DIR/moira.tar.Z
+
+PATH="/etc:/bin:/usr/bin:/usr/etc:/usr/athena/etc"
+
+# The following exit codes are defined and MUST BE CONSISTENT with the
+# MR error codes the library uses:
+set MR_MISSINGFILE =   47836473
+set MR_TARERR =        47836476
+
+cd $DIR
+
+echo extracting $TAR_FILE
+
+if [ ! -f $TAR_FILE ]; then
+       exit $MR_MISSINGFILE
+fi
+
+if zcat < $TAR_FILE | tar xvf -; then
+       echo Extract successful
+else
+       exit $MR_TARERR
+fi
+
+chmod 644 username_id.*
+
+rm -f $0
+echo removed self
+
+exit 0
This page took 0.052426 seconds and 5 git commands to generate.