Support passwords with spaces

You must quote $2 in order to support passwords with spaces.
This commit is contained in:
Stefan Midjich 2025-03-13 14:40:59 +01:00 committed by GitHub
parent f053e33486
commit 4f17744d6c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -12,5 +12,5 @@ if [ -z "$2" ]; then
htpasswd -B $PASSWORD_FILE $1 htpasswd -B $PASSWORD_FILE $1
else else
# read password from command line # read password from command line
htpasswd -B -b $PASSWORD_FILE $1 $2 htpasswd -B -b $PASSWORD_FILE $1 "$2"
fi fi