not really known
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
213 B

#!/bin/bash
if [ $# -eq 0 ]; then
echo "bup [FILE|DIR]";
exit;
fi;
DATE=`date +%Y%m%d-%H%M`;
if [ -f "$1" ]; then
cp $1 $1.$DATE.bup;
fi;
if [ -d "$1" ]; then
tar -cvzf $1.$DATE.tar.gz $1;
fi;