consistent indention

This commit is contained in:
2025-04-11 21:24:37 +02:00
parent f6a35c3ffe
commit 112132cb46

View File

@ -25,36 +25,36 @@ BINARY=""
POSITIONAL_ARGS=() POSITIONAL_ARGS=()
while [[ $# -gt 0 ]]; do while [[ $# -gt 0 ]]; do
case "$1" in case "$1" in
-a|--archive) -a|--archive)
ARCHIVE="$2" ARCHIVE="$2"
shift 2 shift 2
;; ;;
-b|--binary) -b|--binary)
BINARY="$2" BINARY="$2"
shift 2 shift 2
;; ;;
-h|--help) -h|--help)
print_help print_help
exit 0 exit 0
;; ;;
-*) -*)
echo "Unknown option: $1" echo "Unknown option: $1"
print_help print_help
exit 1 exit 1
;; ;;
*) *)
POSITIONAL_ARGS+=("$1") POSITIONAL_ARGS+=("$1")
shift shift
;; ;;
esac esac
done done
if [[ ${#POSITIONAL_ARGS[@]} -ne 1 ]]; then if [[ ${#POSITIONAL_ARGS[@]} -ne 1 ]]; then
echo "Error: Missing required positional argument: URL" echo "Error: Missing required positional argument: URL"
echo echo
print_help print_help
exit 1 exit 1
fi fi
URL="${POSITIONAL_ARGS[0]}" URL="${POSITIONAL_ARGS[0]}"