dotfiles/bin/updateall

26 lines
465 B
Text
Raw Permalink Normal View History

2023-11-21 16:52:05 +01:00
#!/bin/sh
2023-04-13 00:04:20 +02:00
# cd
cd "${HOME}/.config/$(basename "$(readlink -f "$0")")" || exit
2023-04-13 00:57:54 +02:00
scripts_d=./scripts
# Procédure principale
main() {
for i in "${scripts_d}/"*; do
separator "$(basename "$i" | cut -d '-' -f 2)"
"$i"
done
}
2023-11-21 16:52:05 +01:00
case "$1" in
"")
main "$@"
;;
*)
# Oui, ShellCheck, c'est bel et bien ce que j'essaie de faire
# shellcheck disable=SC2211
2023-11-21 16:52:05 +01:00
"${scripts_d}/"??"-${1}" "$@"
;;
esac