44 lines (39 loc) · 1.18 KB
/
update-bibliography.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
name: Update bibliography
on:
schedule:
# We'll run this weekly
- cron: '0 12 * * 1'
workflow_dispatch:
jobs:
update-schedule:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2.2.0
with:
# channels: conda-forge,defaults
# channel-priority: true
activate-environment: ols-website
environment-file: environment.yml
- shell: bash -el {0}
run: |
conda info
conda list
conda config --show-sources
conda config --show
- name: Update library
shell: bash -el {0}
env:
ZOTERO_API: ${{ secrets.ZoteroAPI }}
run: |
python bin/prepare_website_data.py updatebibliography -a "$ZOTERO_API"
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
commit-message: Update bibliography
title: Automatic bibliography update
body: Automatic bibliography update done via GitHub Action once a week
base: main
branch: bibliography-update
delete-branch: true