Windows GitHub release hotfix

Improve id variable parsing and print release.json to catch error
This commit is contained in:
Zion Nimchuk authored and Ani committed 2020-08-16 17:35:19 +01:00
1 parent c3709fa744
commit cd94d9849d
1 file changed
+2 -1
+2 -1
View File
@@ -23,7 +23,8 @@ curl -s \
-H "Accept: application/vnd.github.v3+json" \
--data "$(generate_post_data)" "https://api.github.com/repos/$repo_full_name/releases" >> release.json
id=$(grep '"id"' release.json | cut -d ' ' -f4 | head -n1)
cat release.json
id=$(grep '"id"' release.json | cut -d ':' -f2 | head -n1 | awk '{$1=$1;print}')
id=${id%?}
echo ${id:?}