Skip to content

Commit

Permalink
Add Github action which automatically runs experiments and pushes plo…
Browse files Browse the repository at this point in the history
…ts into Overleaf repository
  • Loading branch information
Baschdl committed Jan 29, 2024
1 parent 5ac39bd commit 5e20aa1
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/push_to_overleaf.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout python project on Github
uses: actions/checkout@v4
with:
path: labproject/
- name: Checkout Overleaf project
uses: actions/checkout@v4
with:
repository: ${{ secrets.OVERLEAF_GIT_CLONE_URL }}
path: overleaf/
- run: |
cd labproject/
python3 -m pip install --upgrade pip
pip install -e ".[docs]"
python3 labproject/run.py
cd ..
cp -r labproject/plots/* overleaf/figures/
- name: Commit and push changes to Overleaf
uses: EndBug/add-and-commit@v7
with:
author_name: "Github Actions"
author_email: ""
cwd: 'overleaf/'
add: 'figures/'
message: "Update figures automatically"
Empty file added labproject/run.py
Empty file.

0 comments on commit 5e20aa1

Please sign in to comment.