660fad954a
make the arguments optional (with documented defaults) plus they need not exist a priori, reducing one command (the silly mkdir!) that the user has to run. All this is preparatory to deprecating the from-client method. We've even switched the test suite to 'non-root' method now
16 lines
338 B
Bash
Executable file
16 lines
338 B
Bash
Executable file
#!/bin/bash
|
|
|
|
cd
|
|
rm -rf .ssh .gitolite .gitolite.rc repositories gitolite-install /tmp/glrb bin share
|
|
tar xf rollback.tar
|
|
( cd /tmp; tar xf ~/rollback2.tar )
|
|
|
|
# if arg1 is a directory, we have to overwrite sources from there (see commit
|
|
# message for details)
|
|
if [ -d "$1" ]
|
|
then
|
|
cd .gitolite
|
|
/bin/cp -a $1/{src,hooks} .
|
|
cd
|
|
fi
|