-
Notifications
You must be signed in to change notification settings - Fork 1
41 lines (39 loc) · 1.12 KB
/
publish-library.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Publish library in (pre-)release
on:
push:
branches: [ master, dev ]
jobs:
build:
name: Make library
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.10'
- name: Install dependencies
run: |
make install-dev
- name: Build
run: |
cb_fetch_data library/DATA_SOURCES.yml -o library.h5
- name: Upload pre-release version
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: library.h5
asset_name: latest_library.h5
tag: latest
overwrite: true
body: "Pre-release library"
- name: Upload release version
if: startsWith(github.ref, 'refs/tags/v')
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: library.h5
asset_name: latest_library.h5
tag: ${{ github.ref }}
overwrite: true
body: "Stable release"