Display progress during upload (ninja 1.5)

This commit is contained in:
Allan Odgaard
2014-04-18 06:06:34 +07:00
parent 9524439aef
commit 2134e957e6
2 changed files with 2 additions and 1 deletions

View File

@@ -919,6 +919,7 @@ rule tbz_archive
rule upload
command = bin/upload -k$upload_keyfile -d$upload_destination -t'v$APP_VERSION' -m'{"version":"$APP_VERSION","revision":"$APP_REVISION"}' $in > $out~ && mv $out~ $out
pool = console
generator = true
description = Upload $in

View File

@@ -60,7 +60,7 @@ def create_release(path, repository, tag, description, content_type)
if url = github['upload_url']
url.sub!(/\{\?name\}/, '')
upload_url = "|curl -sn -H'Content-Type: #{content_type}' --data-binary @'#{path}' '#{url}?name=#{basename}'"
upload_url = "|curl -nH'Content-Type: #{content_type}' --data-binary @'#{path}' '#{url}?name=#{basename}'"
open(upload_url) do |io|
res = JSON.parse(io.read)
return "https://github.com/#{repository}/releases/download/#{tag}/#{basename}" if res.include?('url')