#!/bin/sh set -e # Save important files in backup directories. if [ ! -d save ] then echo "Directory 'save' doesn't exist." exit 1 fi if [ ! -d save2 ] then echo "Directory 'save2' doesn't exist." exit 1 fi # I'm remarkably adept at deleting the wrong files; hence, # I make sure I save two old versions, just in case. if [ -f save/gct-ps-defs.c ]; then mv save/* save2; fi cp gct-map.self save cp gct-ps-defs.c save cp gct-ps-defs.h save if [ -f /usr/tmp/GCTLOG ]; then cp /usr/tmp/GCTLOG save; fi exit 0