diff options
| author | typebrook <typebrook@gmail.com> | 2019-12-22 01:29:50 +0800 |
|---|---|---|
| committer | typebrook <typebrook@gmail.com> | 2019-12-22 01:29:50 +0800 |
| commit | 23bc7187cc555bfeb361a66d679a1f4171fa7033 (patch) | |
| tree | 02a4bc53da00d1b42e5d78205a4d6eb844286a22 /scripts | |
| parent | 9fa375a441ee427a81046d462e19882995d77e0d (diff) | |
update
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/upload-github-release-asset.sh | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/scripts/upload-github-release-asset.sh b/scripts/upload-github-release-asset.sh index e43c573..6923870 100755 --- a/scripts/upload-github-release-asset.sh +++ b/scripts/upload-github-release-asset.sh | |||
| @@ -12,7 +12,7 @@ | |||
| 12 | # * tag | 12 | # * tag |
| 13 | # * filename | 13 | # * filename |
| 14 | # * github_api_token | 14 | # * github_api_token |
| 15 | # * overwrite (optional, default to be false) | 15 | # * overwrite (optional, could be ture, false, delete, default to be false) |
| 16 | # | 16 | # |
| 17 | # Script to upload a release asset using the GitHub API v3. | 17 | # Script to upload a release asset using the GitHub API v3. |
| 18 | # | 18 | # |
| @@ -68,6 +68,9 @@ else | |||
| 68 | else | 68 | else |
| 69 | echo "File already exists on tag $tag" | 69 | echo "File already exists on tag $tag" |
| 70 | echo "If you want to overwrite it, set overwrite=true" | 70 | echo "If you want to overwrite it, set overwrite=true" |
| 71 | exit 1 | ||
| 72 | fi | ||
| 73 | if [ "$overwrite" == "delete" ]; then | ||
| 71 | exit 0 | 74 | exit 0 |
| 72 | fi | 75 | fi |
| 73 | fi | 76 | fi |