25 lines
417 B
Bash
25 lines
417 B
Bash
#! /bin/sh
|
|
|
|
dist="shredmaster.sh shredder.sh"
|
|
|
|
if [ -z ${1} ]; then
|
|
echo "usage: ./install TARGET -- installs programs to ~/bin/TARGET/"
|
|
exit
|
|
fi
|
|
|
|
if [ ! -d ~/bin/ ]; then
|
|
mkdir ~/bin/
|
|
echo "creating ~/bin/"
|
|
fi
|
|
|
|
if [ ! -d ~/bin/${1}/ ]; then
|
|
mkdir ~/bin/${1}/
|
|
echo "creating ~/bin/${1}/"
|
|
fi
|
|
|
|
|
|
for i in ${dist}; do
|
|
cp ./${i} ~/bin/${1}
|
|
echo "copying ${i} to ~/bin/${1}/"
|
|
chmod +x ~/bin/${1}/${i}
|
|
done
|