This repository was archived by the owner on Mar 23, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +41
-3
lines changed
Expand file tree Collapse file tree 2 files changed +41
-3
lines changed Original file line number Diff line number Diff line change 22set -e
33set -u
44
5- if [ -f che-editor-plugin.tar.gz ]; then
6- rm che-editor-plugin.tar.gz
5+ if [ -f ./build/ che-editor-plugin.tar.gz ]; then
6+ rm -rf ./build
77fi
88
99cd etc
10- tar zcvf ../che-editor-plugin.tar.gz .
10+ mkdir -p ../build
11+ tar zcf ../build/che-editor-plugin.tar.gz .
1112
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+ set -e
3+ set -u
4+
5+
6+
7+ ./build.sh
8+
9+ version=che-editor-gwt-ide-$( date +' %F_%k%M-%S' )
10+ git tag $version
11+ git push --tags
12+ text=" Release of Che Editor Gwt IDE"
13+ branch=master
14+ repo_full_name=eclipse/che-editor-gwt-ide
15+ token=$GITHUB_RELEASE_TOKEN
16+ generate_post_data ()
17+ {
18+ cat << EOF
19+ {
20+ "tag_name": "$version ",
21+ "target_commitish": "master",
22+ "name": "$version ",
23+ "body": "Description of the release",
24+ "draft": false,
25+ "prerelease": false
26+ }
27+ EOF
28+ }
29+
30+ echo " Create release $version for repo: $repo_full_name branch: $branch "
31+ rel_id=$( curl -s --data " $( generate_post_data) " " https://api.github.com/repos/$repo_full_name /releases?access_token=$token " | jq -r .id)
32+ echo " Uploading file build/che-editor-plugin.tar.gz"
33+ download_ulr=$( curl -s -X POST " https://uploads.github.com/repos/$repo_full_name /releases/${rel_id} /assets?name=che-editor-plugin.tar.gz&access_token=$token " \
34+ --header ' Content-Type: text/javascript ' --upload-file build/che-editor-plugin.tar.gz | jq -r .browser_download_url)
35+ echo " Download url $download_ulr "
36+
37+ rm build/che-editor-plugin.tar.gz
You can’t perform that action at this time.
0 commit comments