-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (45 loc) · 1.31 KB
/
cd_push.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
name: Continuous Deployment
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-22.04
env:
COMMIT_MSG: ${{ github.event.head_commit.message }}
GRAPHQL_GITHUB_KEY: ${{ secrets.GRAPHQL_GITHUB_KEY }}
API_KEY_GITHUB_REPO: ${{ secrets.API_KEY_GITHUB_REPO }}
steps:
- name: Setup tectonic
uses: wtfjoke/setup-tectonic@v3
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Clone source
uses: actions/checkout@v4
with:
path: 'source'
- name: Build resume
run: |
cd source
npm install
npm run build --workspace data
npm run build --workspace resume
- name: Clone GH pages repo
uses: actions/checkout@v4
with:
repository: MarioJim/mariojim.github.io
path: 'website'
token: ${{ secrets.API_KEY_GITHUB_REPO }}
- name: Add files
run: |
cd website
mv ../source/resume/build/mario_jimenez_resume.pdf .
git add mario_jimenez_resume.pdf
- name: Push website repo
run: |
cd website
git config --global user.name "MarioJim"
git config --global user.email "[email protected]"
git commit -m "[CD] $COMMIT_MSG"
git push