mirror of
https://github.com/anyproto/anytype-ts.git
synced 2025-06-08 05:57:02 +09:00
fix update.sh script to get version
This commit is contained in:
parent
df03e02045
commit
beab5a402c
1 changed files with 5 additions and 4 deletions
|
@ -4,8 +4,9 @@ REPO="anytypeio/go-anytype-middleware"
|
|||
FILE="addon.tar.gz"
|
||||
GITHUB="api.github.com"
|
||||
|
||||
token=$1;
|
||||
platform=$2;
|
||||
user=$1
|
||||
token=$2;
|
||||
platform=$3;
|
||||
arch="";
|
||||
|
||||
if [ "$platform" = "ubuntu-latest" ]; then
|
||||
|
@ -32,8 +33,8 @@ if [ "$arch" = "" ]; then
|
|||
fi;
|
||||
|
||||
mwv=`cat middleware.version`
|
||||
|
||||
version=`curl -H "Authorization: token $token" -H "Accept: application/vnd.github.v3+json" -sL https://$GITHUB/repos/$REPO/releases/tags/v$mwv | jq .`
|
||||
|
||||
version=`curl -u "$user:$token" -H "Accept: application/vnd.github.v3+json" -sL https://$GITHUB/repos/$REPO/releases/tags/v$mwv | jq .`
|
||||
|
||||
tag=`echo $version | jq ".tag_name"`
|
||||
asset_id=`echo $version | jq ".assets | map(select(.name | match(\"js_v[0-9]+.[0-9]+.[0-9]+(-rc[0-9]+)?_$arch\";\"i\")))[0].id"`
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue