Bugfix: Neuste verfügbare Version konnte nicht mehr ermittelt werden
This commit is contained in:
parent
362714817d
commit
ef9ee6f787
@ -16,6 +16,11 @@ handleError() {
|
|||||||
EOT
|
EOT
|
||||||
}
|
}
|
||||||
|
|
||||||
|
err() {
|
||||||
|
echo "${COLOR_RED}$*${COLOR_RESET}"
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
showLogo() {
|
showLogo() {
|
||||||
echo -n "${COLOR_GREEN}"
|
echo -n "${COLOR_GREEN}"
|
||||||
cat <<-'EOT'
|
cat <<-'EOT'
|
||||||
@ -62,7 +67,8 @@ showHelp() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
getVersionLatest() {
|
getVersionLatest() {
|
||||||
VERSION_LATEST="$( wget -qO - https://github.com/logseq/logseq/releases/latest | grep -Poi "Logseq-linux-x64-\K\d\.\d\.\d" | head -n 1 )"
|
VERSION_LATEST="$( wget -qO - https://github.com/logseq/logseq/releases/latest | grep -Poi "releases/tag/\K\d\.\d\.\d" | head -n 1 )"
|
||||||
|
[ -n "$VERSION_LATEST" ] || err "Konnte nicht ermittelt werden"
|
||||||
}
|
}
|
||||||
|
|
||||||
getVersionCurrent() {
|
getVersionCurrent() {
|
||||||
@ -74,11 +80,12 @@ getVersionCurrent() {
|
|||||||
else
|
else
|
||||||
VERSION_CURRENT=
|
VERSION_CURRENT=
|
||||||
fi
|
fi
|
||||||
|
[ -n "$VERSION_CURRENT" ] || err "Konnte nicht ermittelt werden"
|
||||||
}
|
}
|
||||||
|
|
||||||
getLatest() {
|
getLatest() {
|
||||||
local URL
|
local URL
|
||||||
URL="https://github.com$( wget -qO - https://github.com/logseq/logseq/releases/latest | grep -Poi "/logseq.*AppImage" )"
|
URL="https://github.com/logseq/logseq/releases/download/$VERSION_LATEST/Logseq-linux-x64-$VERSION_LATEST.AppImage"
|
||||||
local DIR_DEST
|
local DIR_DEST
|
||||||
DIR_DEST=~/.local/bin
|
DIR_DEST=~/.local/bin
|
||||||
local FILE_LINK
|
local FILE_LINK
|
||||||
|
Loading…
Reference in New Issue
Block a user