-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (40 loc) · 1.22 KB
/
push_to_overleaf.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
on:
push:
branches:
- master
workflow_dispatch:
permissions:
contents: write
pull-requests: write
issues: write
name: "Push to overleaf"
jobs:
update_sync_overleaf:
runs-on: ubuntu-latest
name: Update branch 'sync_overleaf'
steps:
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: Push to overleaf
run: |
git remote add origin_token https://git:${GITHUB_TOKEN}@github.com/columnflow/demo_docs.git
git push origin_token HEAD:sync_overleaf
env:
OVERLEAF_TOKEN: ${{ secrets.OVERLEAF_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
update_overleaf:
runs-on: ubuntu-latest
name: Update overleaf
steps:
- uses: actions/checkout@v4
with:
ref: sync_overleaf
fetch-depth: '0'
- name: Push to overleaf
run: |
git remote add overleaf https://git:${OVERLEAF_TOKEN}@git.overleaf.com/65df171af9ff7989580f017d
git push overleaf HEAD:master
env:
OVERLEAF_TOKEN: ${{ secrets.OVERLEAF_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}