os-init/alpine.sh

28 lines
442 B
Bash
Raw Normal View History

2023-11-19 18:13:43 +00:00
#!/bin/dash
BASE_URL=https://git.netm.ch/m/os-init/raw/branch/main
showHelp() {
echo "alpine.sh"
echo ""
echo "use :"
echo "sh alpine.sh [options]"
echo " -b | --base-url url"
}
main() {
wget -O /tmp/init.sh "${BASE_URL}"/alpine/init.sh
sh /tmp/init.sh -b "${BASE_URL}"
rm /tmp/init.sh
}
while [ ${#} -gt 0 ]; do
2023-11-19 18:16:16 +00:00
case ${1} in
2023-11-19 18:13:43 +00:00
--help) showHelp; exit 0;;
-b | --base-url) BASE_URL="${2}"; shift;;
*) shift;;
2023-11-19 18:16:16 +00:00
esac
2023-11-19 18:13:43 +00:00
done
main