mirror of
https://code.forgejo.org/actions/forgejo-release.git
synced 2025-04-24 18:02:15 +00:00
dont use wget to download
This commit is contained in:
parent
eb0fcc44a1
commit
27146d0e06
1 changed files with 2 additions and 2 deletions
|
@ -107,7 +107,7 @@ upload() {
|
||||||
setup_api() {
|
setup_api() {
|
||||||
if ! which jq curl ; then
|
if ! which jq curl ; then
|
||||||
apt-get -qq update
|
apt-get -qq update
|
||||||
apt-get install -y -qq jq curl wget
|
apt-get install -y -qq jq curl
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -149,7 +149,7 @@ download() {
|
||||||
cd $RELEASE_DIR
|
cd $RELEASE_DIR
|
||||||
api GET repos/$REPO/releases/tags/$TAG > $TMP_DIR/assets.json
|
api GET repos/$REPO/releases/tags/$TAG > $TMP_DIR/assets.json
|
||||||
jq --raw-output '.assets[] | "\(.name) \(.browser_download_url)"' < $TMP_DIR/assets.json | while read name url ; do
|
jq --raw-output '.assets[] | "\(.name) \(.browser_download_url)"' < $TMP_DIR/assets.json | while read name url ; do
|
||||||
wget --quiet -O $name $url
|
curl -H "Authorization: token $TOKEN" -o $name -L $url
|
||||||
done
|
done
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue