Skip to content

Commit cba7d63

Browse files
author
webdev778
committed
Upload map json artifacts on release
1 parent a2850a7 commit cba7d63

File tree

2 files changed

+48
-42
lines changed

2 files changed

+48
-42
lines changed

.github/workflows/rake.yml

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -53,43 +53,3 @@ jobs:
5353
run: |
5454
bundle install --with=jsexec
5555
bundle exec rspec -f f
56-
57-
generate-json:
58-
runs-on: ubuntu-latest
59-
needs: rspec
60-
if: ${{ github.event_name == 'push' }}
61-
env:
62-
BUNDLE_WITHOUT: "secryst:jsexec"
63-
SKIP_JS: "1"
64-
steps:
65-
- name: Checkout repository and submodules
66-
uses: actions/checkout@v2
67-
with:
68-
submodules: true
69-
- name: Use Ruby
70-
uses: ruby/setup-ruby@v1
71-
with:
72-
ruby-version: 3.0
73-
bundler-cache: true
74-
working-directory: ./ruby
75-
- name: Generate visualization json
76-
run: bundle exec rake generate_visualization_json
77-
- name: Upload artifacts
78-
uses: actions/upload-artifact@v2
79-
with:
80-
name: vis_json
81-
path: ruby/vis_json
82-
- name: Generate metadata
83-
run: bundle exec rake generate_metadata_json
84-
- name: Upload metadata
85-
uses: actions/upload-artifact@v2
86-
with:
87-
name: metadata
88-
path: ruby/metadata.json
89-
- name: Trigger interscript.org
90-
uses: peter-evans/repository-dispatch@v1
91-
with:
92-
token: ${{ secrets.INTERSCRIPT_CI_TOKEN }}
93-
repository: interscript/interscript.org
94-
event-type: ${{ github.repository }}
95-
client-payload: '{ "ref": "${{ github.ref }}" }'

.github/workflows/release.yml

Lines changed: 48 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
with:
1818
ruby-version: '2.7'
1919
architecture: 'x64'
20-
20+
2121
- uses: actions/setup-node@v1
2222
with:
2323
node-version: 14.x
@@ -73,4 +73,50 @@ jobs:
7373
# token: ${{ secrets.INTERSCRIPT_CI_PAT_TOKEN }}
7474
# repository: interscript/interscript-api
7575
# event-type: ${{ github.repository }}
76-
# client-payload: '{ "ref": "${{ github.ref }}" }'
76+
# client-payload: '{ "ref": "${{ github.ref }}" }'
77+
asset:
78+
runs-on: ubuntu-latest
79+
if: ${{ github.event_name == 'push' }}
80+
env:
81+
BUNDLE_WITHOUT: "secryst:jsexec"
82+
SKIP_JS: "1"
83+
steps:
84+
- name: Checkout repository and submodules
85+
uses: actions/checkout@v2
86+
with:
87+
submodules: true
88+
- name: Use Ruby
89+
uses: ruby/setup-ruby@v1
90+
with:
91+
ruby-version: 3.0
92+
bundler-cache: true
93+
working-directory: ./ruby
94+
- name: Generate visualization json
95+
run: bundle exec rake generate_visualization_json
96+
- name: Upload artifacts
97+
uses: svenstaro/upload-release-action@v2
98+
with:
99+
repo_token: ${{ secrets.GITHUB_TOKEN }}
100+
file: ruby/vis_json
101+
asset_name: vis_json
102+
tag: ${{ github.ref }}
103+
overwrite: true
104+
body: "visualize json of map systems"
105+
- name: Generate metadata
106+
run: bundle exec rake generate_metadata_json
107+
- name: Upload metadata
108+
uses: svenstaro/upload-release-action@v2
109+
with:
110+
repo_token: ${{ secrets.GITHUB_TOKEN }}
111+
file: ruby/metadata.json
112+
asset_name: metadata
113+
tag: ${{ github.ref }}
114+
overwrite: true
115+
body: "metadata of all systems"
116+
# - name: Trigger interscript.org
117+
# uses: peter-evans/repository-dispatch@v1
118+
# with:
119+
# token: ${{ secrets.INTERSCRIPT_CI_TOKEN }}
120+
# repository: interscript/interscript.org
121+
# event-type: ${{ github.repository }}
122+
# client-payload: '{ "ref": "${{ github.ref }}" }'

0 commit comments

Comments
 (0)