-
Notifications
You must be signed in to change notification settings - Fork 1
46 lines (41 loc) · 1.35 KB
/
ci-miua.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
name: CITEX-MIUA2022
on:
push:
branches:
- main
- 05-camera-ready
- $ADD_ISSUENUMER_NAME
jobs:
build:
if: "contains(github.event.head_commit.message, 'CITEX')"
runs-on: ubuntu-latest
steps:
- name: Set up Git repository
uses: actions/checkout@v1
- name: Compile Abstract
uses: xu-cheng/latex-action@v2
with:
root_file: main.tex
working_directory: abstract/latex
- name: Check pdf files
run: |
file abstract/latex/main.pdf | grep -q ' PDF '
- name: Upload
run: |
# configure git
git config --global user.name "mxochicale"
git config --global user.email "[email protected]"
# setup ssh
mkdir ~/.ssh
chmod 700 ~/.ssh
echo "$DEPLOY_KEY" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
git config --global core.sshCommand "ssh -i ~/.ssh/id_rsa -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no"
git clone --depth=1 --branch pdfs [email protected]:budai4medtech/miua2022.git "$GITHUB_WORKSPACE/deploy"
cp -f abstract/latex/main.pdf "$GITHUB_WORKSPACE/deploy/miua2022-abstract.pdf"
cd "$GITHUB_WORKSPACE/deploy"
git add miua2022-abstract.pdf
git commit -m "latex-action deploy"
git push
env:
DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }}