-
-
Notifications
You must be signed in to change notification settings - Fork 45
74 lines (61 loc) · 2.01 KB
/
carsus-data-repos-config.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
name: carsus-data-repos-config
on:
workflow_dispatch:
env:
NBCONVERT_FLAGS: --execute --ExecutePreprocessor.timeout=600 --to html
defaults:
run:
shell: bash -l {0}
jobs:
checkout:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
path: carsus/
- name: Restore cache
uses: actions/cache@v3
with:
path: carsus-data-cmfgen
key: ${{ runner.os }}-cache-${{ hashFiles('carsus-data-cmfgen/**/*.lock') }}
- name: Restore cache
uses: actions/cache@v3
with:
path: carsus-data-kurucz
key: ${{ runner.os }}-cache-${{ hashFiles('carsus-data-kurucz/**/*.lock') }}
- name: Restore cache
uses: actions/cache@v3
with:
path: carsus-data-nist
key: ${{ runner.os }}-cache-${{ hashFiles('carsus-data-nist/**/*.lock') }}
- run: |
for repo in carsus-data-cmfgen carsus-data-kurucz carsus-data-nist; do
repo_path="$repo"
if [ ! -d $repo_path ] ; then
git clone https://github.com/tardis-sn/$repo $repo_path
else
cd $repo_path
git fetch
git checkout origin/main
cd ..
fi
done
- uses: mamba-org/setup-micromamba@v1
with:
environment-file: conda-lock.yml
init-shell: bash
cache-environment: true
cache-downloads: true
environment-name: carsus
- name: Install package
run: pip install -e carsus/
- name: Run notebooks
run: |
jupyter nbconvert ${{ env.NBCONVERT_FLAGS }} carsus/docs/tardis_atomdata_ref.ipynb
env:
CARSUS_REFDATA: ${{ github.workspace }}/carsus-refdata
- name: Upload Atom Data
uses: actions/upload-artifact@v3
with:
name: atom-data
path: carsus/docs/kurucz_cd23_cmfgen_H_Si.h5