upload-to-github: mark newly created releases as drafts
This hides them from https://github.com/.../releases/latest so that the release can be made public only after all the files have been uploaded. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This commit is contained in:
Родитель
5e95af6d43
Коммит
dfb0081f2f
|
@ -26,7 +26,9 @@ id="$(curl --netrc -s $url |
|
|||
grep -B1 "\"tag_name\": \"$tagname\"" |
|
||||
sed -n 's/.*"id": *\([0-9]*\).*/\1/p')"
|
||||
test -n "$id" || {
|
||||
out="$(curl --netrc -s -XPOST -d '{"tag_name":"'"$tagname"'"}' $url)" ||
|
||||
out="$(curl --netrc -s -XPOST -d \
|
||||
'{"tag_name":"'"$tagname"'","draft":true,"prerelease":true}' \
|
||||
$url)" ||
|
||||
die "Error creating release: $out"
|
||||
id="$(echo "$out" |
|
||||
sed -n 's/^ "id": *\([0-9]*\).*/\1/p')"
|
||||
|
|
Загрузка…
Ссылка в новой задаче