nc_password_client/install.sh

25 lines
527 B
Bash
Raw Normal View History

2024-11-16 21:54:10 +01:00
#!/bin/bash
destination="/usr/local/bin"
while [ $# -gt 0 ]
do
case "$1" in
"--help"|"-h"|"-?")
usage
exit 0
;;
"--destination"|"-d")
shift
destination="${1}"
shift
;;
*)
echo "Ignoring unknwon parameter '${1}'"
shift
;;
esac
done
script_dir=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
sed "s#__src_folder__#${script_dir}#g" wrapper.sh > "${destination}/nc_password_client.sh"
chmod +x "${destination}/nc_password_client.sh"