Changed $CFBASE to $CFREPO.
1 parent 763098e commit 49d4164865f96c2b9902bbdf7932ec56a3f81ad3
@tundra tundra authored on 13 Feb 2013
Showing 1 changed file
View
12
tconfigfiles
#!/bin/sh
# tconfigfiles - Manage Configuration Files
# Copyright (c) 2007-2013 TundraWare Inc., Des Plaines, IL USA
# All Rights Reserved
# $Id: tconfigfiles,v 1.117 2013/02/13 14:55:42 tundra Exp $
# $Id: tconfigfiles,v 1.118 2013/02/13 15:33:42 tundra Exp $
 
# Where things live
 
CFBASE=${CFBASE:-$HOME/configfiles} # The directory that holds everything below
# Can be overridden with $CFBASE env var
CFREPO=${CFREPO:-$HOME/configfiles} # The directory that holds everything below
# Can be overridden with $CFREPO env var
 
ARCHIVES=archives # Where archives go
FILES=tree # Where tree of individual files lives
 
ARCHIVEDIR="$CFBASE/$ARCHIVES"
FILEDIR="$CFBASE/$FILES"
ARCHIVEDIR="$CFREPO/$ARCHIVES"
FILEDIR="$CFREPO/$FILES"
 
# Make sure the container directories exist
 
mkdir -p $ARCHIVEDIR
 
 
"cfarchive") # Make archival copy of current tree
timestamp=`date "+%Y-%m-%d-%H%M%S"`
cd $CFBASE
cd $CFREPO
MACHNAME=`hostname -f`
archdir=$MACHNAME-$FILES-$timestamp
cp -pvR $FILES $archdir
tar -czvf $ARCHIVES/$archdir.tar.gz $archdir