Commit 2ee14eb5 authored by Boris Yumankulov's avatar Boris Yumankulov Committed by Vitaly Lipatov

epm play common: rename get_github_version to get_github_url

parent 9bf79c96
...@@ -170,7 +170,7 @@ get_latest_version() ...@@ -170,7 +170,7 @@ get_latest_version()
done done
} }
get_github_version() get_github_url()
{ {
local url="$1" local url="$1"
local user_and_repo=${url#https://github.com/} local user_and_repo=${url#https://github.com/}
......
...@@ -9,7 +9,7 @@ URL="https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher" ...@@ -9,7 +9,7 @@ URL="https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher"
. $(dirname $0)/common.sh . $(dirname $0)/common.sh
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher/" "${PKGNAME}-.${VERSION}.AppImage") PKGURL=$(get_github_url "https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher/" "${PKGNAME}-.${VERSION}.AppImage")
else else
PKGURL="https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher/releases/download/v$VERSION/${PKGNAME}-${VERSION}.AppImage" PKGURL="https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher/releases/download/v$VERSION/${PKGNAME}-${VERSION}.AppImage"
fi fi
......
...@@ -18,7 +18,7 @@ case "$(epm print info -a)" in ...@@ -18,7 +18,7 @@ case "$(epm print info -a)" in
esac esac
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/mifi/lossless-cut/" "LosslessCut-linux-$arch.tar.bz2") PKGURL=$(get_github_url "https://github.com/mifi/lossless-cut/" "LosslessCut-linux-$arch.tar.bz2")
else else
PKGURL="https://github.com/mifi/lossless-cut/releases/download/v$VERSION/LosslessCut-linux-$arch.tar.bz2" PKGURL="https://github.com/mifi/lossless-cut/releases/download/v$VERSION/LosslessCut-linux-$arch.tar.bz2"
fi fi
......
...@@ -21,7 +21,7 @@ case "$arch" in ...@@ -21,7 +21,7 @@ case "$arch" in
;; ;;
esac esac
PKGURL=$(get_github_version "https://github.com/mattermost/desktop/" "$(epm print constructname $PKGNAME ".$VERSION*" $arch "deb")") PKGURL=$(get_github_url "https://github.com/mattermost/desktop/" "$(epm print constructname $PKGNAME ".$VERSION*" $arch "deb")")
install_pkgurl install_pkgurl
...@@ -9,7 +9,7 @@ URL="https://moonlight-stream.org/" ...@@ -9,7 +9,7 @@ URL="https://moonlight-stream.org/"
. $(dirname $0)/common.sh . $(dirname $0)/common.sh
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/moonlight-stream/moonlight-qt/" "$PKGNAME-.$VERSION-x86_64.AppImage") PKGURL=$(get_github_url "https://github.com/moonlight-stream/moonlight-qt/" "$PKGNAME-.$VERSION-x86_64.AppImage")
else else
PKGURL="https://github.com/moonlight-stream/moonlight-qt/releases/download/v$VERSION/$PKGNAME-$VERSION-x86_64.AppImage" PKGURL="https://github.com/moonlight-stream/moonlight-qt/releases/download/v$VERSION/$PKGNAME-$VERSION-x86_64.AppImage"
fi fi
......
...@@ -27,7 +27,7 @@ else ...@@ -27,7 +27,7 @@ else
fi fi
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/cyanfish/naps2/" "$PKGNAME-.$VERSION-linux-$arch.$pkgtype") PKGURL=$(get_github_url "https://github.com/cyanfish/naps2/" "$PKGNAME-.$VERSION-linux-$arch.$pkgtype")
else else
PKGURL="https://github.com/cyanfish/naps2/releases/download/v$VERSION/$PKGNAME-$VERSION-linux-$arch.$pkgtype" PKGURL="https://github.com/cyanfish/naps2/releases/download/v$VERSION/$PKGNAME-$VERSION-linux-$arch.$pkgtype"
fi fi
......
...@@ -9,7 +9,7 @@ URL="https://persepolisdm.github.io/" ...@@ -9,7 +9,7 @@ URL="https://persepolisdm.github.io/"
. $(dirname $0)/common.sh . $(dirname $0)/common.sh
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/persepolisdm/persepolis/" "${PKGNAME}_.${VERSION}_all.deb") PKGURL=$(get_github_url "https://github.com/persepolisdm/persepolis/" "${PKGNAME}_.${VERSION}_all.deb")
else else
PKGURL="https://github.com/persepolisdm/persepolis/releases/download/$VERSION/${PKGNAME}_${VERSION}_all.deb" PKGURL="https://github.com/persepolisdm/persepolis/releases/download/$VERSION/${PKGNAME}_${VERSION}_all.deb"
fi fi
......
...@@ -23,9 +23,9 @@ case $pkgtype in ...@@ -23,9 +23,9 @@ case $pkgtype in
esac esac
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/SchildiChat/schildichat-desktop/" "$mask") PKGURL=$(get_github_url "https://github.com/SchildiChat/schildichat-desktop/" "$mask")
else else
# need because get_github_version doesn't support ${VERSION} without a dot before VERSION in mask # need because get_github_url doesn't support ${VERSION} without a dot before VERSION in mask
direct_mask="$(echo $mask | sed 's/\.//')" direct_mask="$(echo $mask | sed 's/\.//')"
PKGURL="https://github.com/SchildiChat/schildichat-desktop/releases/download/v$VERSION/$direct_mask" PKGURL="https://github.com/SchildiChat/schildichat-desktop/releases/download/v$VERSION/$direct_mask"
fi fi
......
...@@ -20,7 +20,7 @@ case "$(epm print info -a)" in ...@@ -20,7 +20,7 @@ case "$(epm print info -a)" in
esac esac
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/Automattic/simplenote-electron/" "$PKGNAME-.$VERSION-$arch.AppImage") PKGURL=$(get_github_url "https://github.com/Automattic/simplenote-electron/" "$PKGNAME-.$VERSION-$arch.AppImage")
else else
PKGURL="https://github.com/Automattic/simplenote-electron/releases/download/v$VERSION/$PKGNAME-$VERSION-$arch.AppImage" PKGURL="https://github.com/Automattic/simplenote-electron/releases/download/v$VERSION/$PKGNAME-$VERSION-$arch.AppImage"
fi fi
......
...@@ -8,7 +8,7 @@ URL="https://app.lizardbyte.dev/Sunshine" ...@@ -8,7 +8,7 @@ URL="https://app.lizardbyte.dev/Sunshine"
. $(dirname $0)/common.sh . $(dirname $0)/common.sh
PKGURL=$(get_github_version "https://github.com/LizardByte/Sunshine/" "sunshine-fedora-.*-amd64.rpm") PKGURL=$(get_github_url "https://github.com/LizardByte/Sunshine/" "sunshine-fedora-.*-amd64.rpm")
install_pkgurl install_pkgurl
......
...@@ -9,7 +9,7 @@ URL="https://github.com/tsukinaha/tsukimi" ...@@ -9,7 +9,7 @@ URL="https://github.com/tsukinaha/tsukimi"
. $(dirname $0)/common.sh . $(dirname $0)/common.sh
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/tsukinaha/tsukimi/" "tsukimi-x86_64-linux-gnu.tar.gz") PKGURL=$(get_github_url "https://github.com/tsukinaha/tsukimi/" "tsukimi-x86_64-linux-gnu.tar.gz")
else else
PKGURL="https://github.com/tsukinaha/tsukimi/releases/download/v$VERSION/tsukimi-x86_64-linux-gnu.tar.gz" PKGURL="https://github.com/tsukinaha/tsukimi/releases/download/v$VERSION/tsukimi-x86_64-linux-gnu.tar.gz"
fi fi
......
...@@ -21,7 +21,7 @@ case "$arch" in ...@@ -21,7 +21,7 @@ case "$arch" in
esac esac
if [ "$VERSION" = "*" ] ; then if [ "$VERSION" = "*" ] ; then
PKGURL=$(get_github_version "https://github.com/zed-industries/zed/" "zed-linux-$arch.tar.gz") PKGURL=$(get_github_url "https://github.com/zed-industries/zed/" "zed-linux-$arch.tar.gz")
else else
PKGURL="https://github.com/zed-industries/zed/releases/download/v$VERSION/zed-linux-$arch.tar.gz" PKGURL="https://github.com/zed-industries/zed/releases/download/v$VERSION/zed-linux-$arch.tar.gz"
fi fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment