server/gitea: update.sh: Improved usage of quotation markers

dehydrated
Felix Stupp 4 years ago
parent f8cd2a6f60
commit 90a2a41d7c
Signed by: zocker
GPG Key ID: 93E1BD26F6B02FB7

@ -13,15 +13,15 @@ set -e;
gpg --quiet --keyserver eu.pool.sks-keyservers.net --recv "$GPG_FINGERPRINT"; gpg --quiet --keyserver eu.pool.sks-keyservers.net --recv "$GPG_FINGERPRINT";
function error() { function error() {
echo $@ >&2; echo "$@" >&2;
} }
function as() { function as() {
sudo -u "$GITEA_USER" $@; sudo -u "$GITEA_USER" "$@";
} }
if [ -f "$GITEA_BIN" ]; then if [ -f "$GITEA_BIN" ]; then
installed=$(cd "$GITEA_DIR" && as "$GITEA_BIN" --version | grep --only-matching --perl-regexp "(?<=version )\d+(\.\d+)*(?= )"); installed=$(cd "$GITEA_DIR" && as "$GITEA_BIN" --version | grep --only-matching --perl-regexp '(?<=version )\d+(\.\d+)*(?= )');
else else
installed=0; installed=0;
fi fi

Loading…
Cancel
Save