Initial commit
This commit is contained in:
commit
c7497d689a
31 changed files with 2149 additions and 0 deletions
38
install.sh
Executable file
38
install.sh
Executable file
|
|
@ -0,0 +1,38 @@
|
|||
#!/bin/sh
|
||||
|
||||
if [ ${0:0:1} == "/" ]
|
||||
then
|
||||
SOURCE=$(dirname $0)/
|
||||
else
|
||||
SOURCE=$(dirname `pwd`/$0)/
|
||||
fi
|
||||
DESTINATION=~
|
||||
|
||||
cd $SOURCE
|
||||
git submodule init
|
||||
git submodule update
|
||||
|
||||
#BIN="cp -r"
|
||||
BIN="ln -s"
|
||||
|
||||
TMPERR=`mktemp`
|
||||
for f in `ls -a $SOURCE`
|
||||
do
|
||||
if [ "$f" != "." ] && [ "$f" != ".." ] &&
|
||||
[ "$f" != ".gitmodules" ] && [ "$f" != "install.sh" ]
|
||||
then
|
||||
echo -ne "Installing $f ...\t"
|
||||
if [ ${#f} -lt 9 ]; then echo -en "\t"; fi
|
||||
if [ -L $DESTINATION/$f ]
|
||||
then
|
||||
echo -e "Already installed"
|
||||
elif [ -e $DESTINATION/$f ]
|
||||
then
|
||||
echo -e "Already existing $f"
|
||||
else
|
||||
$BIN $SOURCE/$f $DESTINATION/$f >&2 2> $TMPERR
|
||||
if [ $? == 0 ]; then echo -e "done"; else echo -e "fail"; fi
|
||||
cat $TMPERR
|
||||
fi
|
||||
fi
|
||||
done
|
||||
Loading…
Add table
Add a link
Reference in a new issue