Browse Source

Upgrade shtpl installer

master
dig 4 years ago
parent
commit
9d10846ff9
  1. 24
      shtpl/install

24
shtpl/install

@ -1,6 +1,24 @@
#!/usr/bin/env bash
from=$(pwd)/$(dirname "$0")
to=/usr/local/bin
install()
{
name="shtpl"
from="$(pwd)/$(dirname "$0")"
to="/usr/local/bin"
[[ -n "$yes" ]] && v=y || read -re -p "Voulez-vous installer $name ? (y/n)" v
if [ $v = y ]
then
echo "Installation de $name en cours ..."
if [ -f /usr/local/bin/$name ]; then
rm /usr/local/bin/$name
fi
cp $from/shtpl $to/shtpl
echo "Installation terminé !"
fi
}
install
cp $from/shtpl $to/shtpl

Loading…
Cancel
Save