-
Notifications
You must be signed in to change notification settings - Fork 0
52 lines (49 loc) · 1.41 KB
/
release.yaml
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
name: Build and release pdf
on:
push:
branches:
- main
permissions:
contents: write
jobs:
release-pdf:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: Create initial tag
run: |
if [ -z "$(git tag -l 'v*')" ]; then
git tag v0.0.0
fi
- name: Bump version and push tag
id: bump
uses: anothrNick/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
WITH_V: true
DEFAULT_BUMP: 'patch'
- name: Create Release
id: create_release
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ steps.bump.outputs.new_tag }}
name: Version ${{ steps.bump.outputs.new_tag }}
draft: false
prerelease: false
- name: Compile LaTeX document - Template
uses: dante-ev/latex-action@master
with:
working_directory: ./src
root_file: template.tex
- name: Upload Release Asset - Template
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./src/.build/template.pdf
asset_name: template.pdf
asset_content_type: application/pdf