mirror of
https://github.com/VSCodium/vscodium.git
synced 2024-12-22 16:31:41 +03:00
ci: use jq to get gh cli (#2168)
Signed-off-by: Thibaud CANALE <thican@thican.net>
This commit is contained in:
parent
6aae07dad9
commit
d0d0da180d
@ -4,9 +4,10 @@ set -ex
|
||||
|
||||
GH_ARCH="amd64"
|
||||
|
||||
VERSION=$( curl --retry 12 --retry-delay 30 "https://api.github.com/repos/cli/cli/releases/latest" | grep '"tag_name"' | sed -E 's/.*"([^"]+)".*/\1/' | cut -c2- )
|
||||
TAG=$( curl --retry 12 --retry-delay 30 "https://api.github.com/repos/cli/cli/releases/latest" | jq --raw-output '.tag_name' )
|
||||
VERSION=${TAG#v}
|
||||
|
||||
curl --retry 12 --retry-delay 120 -sSL "https://github.com/cli/cli/releases/download/v${VERSION}/gh_${VERSION}_linux_${GH_ARCH}.tar.gz" -o "gh_${VERSION}_linux_${GH_ARCH}.tar.gz"
|
||||
curl --retry 12 --retry-delay 120 -sSL "https://github.com/cli/cli/releases/download/${TAG}/gh_${VERSION}_linux_${GH_ARCH}.tar.gz" -o "gh_${VERSION}_linux_${GH_ARCH}.tar.gz"
|
||||
|
||||
tar xf "gh_${VERSION}_linux_${GH_ARCH}.tar.gz"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user