mirror of
https://github.com/EV21/uberspace-helper.git
synced 2026-10-07 20:33:18 +02:00
minor: small refactorings
This commit is contained in:
2 files changed
+2
-7
No files matched your search
+2
-6
@@ -147,9 +147,6 @@ NO_REPLY_ADDRESS = noreply.${USER}.uber.space
|
||||
ENABLED = true
|
||||
MAILER_TYPE = sendmail
|
||||
FROM = ${USER}@uber.space
|
||||
|
||||
[repository]
|
||||
DEFAULT_BRANCH = main
|
||||
end_of_content
|
||||
}
|
||||
|
||||
@@ -165,9 +162,9 @@ autorestart=true
|
||||
end_of_content
|
||||
}
|
||||
|
||||
function get_latest_version
|
||||
function get_download_url
|
||||
{
|
||||
curl --silent $GITHUB_API_URL > "$TMP_LOCATION"/github_api_response.json
|
||||
curl --silent "$GITHUB_API_URL" > "$TMP_LOCATION"/github_api_response.json
|
||||
TAG_NAME=$(jq --raw-output '.tag_name' "$TMP_LOCATION"/github_api_response.json)
|
||||
LATEST_VERSION=${TAG_NAME:1}
|
||||
DOWNLOAD_URL=$(jq --raw-output '.assets[].browser_download_url' "$TMP_LOCATION"/github_api_response.json |
|
||||
@@ -224,7 +221,6 @@ function do_update_procedure
|
||||
supervisorctl stop gitea
|
||||
wget --quiet --progress=bar:force --output-document $TMP_LOCATION/gitea "$DOWNLOAD_URL"
|
||||
verify_file
|
||||
supervisorctl stop gitea
|
||||
mv --verbose $TMP_LOCATION/gitea "$GITEA_LOCATION"
|
||||
chmod u+x --verbose "$GITEA_LOCATION"
|
||||
supervisorctl start gitea
|
||||
|
||||
@@ -15,7 +15,6 @@ function do_update_procedure
|
||||
supervisorctl stop gitea
|
||||
wget --quiet --progress=bar:force --output-document "$TMP_LOCATION"/gitea "$DOWNLOAD_URL"
|
||||
verify_file
|
||||
supervisorctl stop gitea
|
||||
mv --verbose "$TMP_LOCATION"/gitea "$GITEA_LOCATION"
|
||||
chmod u+x --verbose "$GITEA_LOCATION"
|
||||
supervisorctl start gitea
|
||||
|
||||
Reference in new issue
Block a user