-
Notifications
You must be signed in to change notification settings - Fork 11
58 lines (50 loc) · 1.61 KB
/
ci.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
55
56
57
58
name: "CI"
on:
push:
branches:
- "*"
tags:
- "*"
pull_request:
branches:
- "develop"
workflow_dispatch:
jobs:
build:
name: "CI - Build Job"
runs-on: "ubuntu-20.04"
steps:
- name: "Checkout Repository"
uses: "actions/checkout@v2"
- name: "Install Ubuntu Packages"
run: "sudo apt-get update && sudo apt-get -y install scons texlive-latex-extra"
- name: "Build with SCons"
run: "scons"
- name: "Create GitHub Release"
id: "create_github_release"
if: "${{ startsWith(github.ref, 'refs/tags/') }}"
uses: "actions/create-release@v1"
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
with:
tag_name: "${{ github.ref }}"
- name: "Upload Slides to GitHub Release"
if: "${{ startsWith(github.ref, 'refs/tags/') }}"
uses: "actions/upload-release-asset@v1"
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
with:
asset_content_type: "application/pdf"
asset_name: "talk.pdf"
asset_path: "tex/talk.pdf"
upload_url: "${{ steps.create_github_release.outputs.upload_url }}"
- name: "Upload Handout to GitHub Release"
if: "${{ startsWith(github.ref, 'refs/tags/') }}"
uses: "actions/upload-release-asset@v1"
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
with:
asset_content_type: "application/pdf"
asset_name: "handout.pdf"
asset_path: "tex/handout.pdf"
upload_url: "${{ steps.create_github_release.outputs.upload_url }}"