Upload pdf as release on new tag

This commit is contained in:
Radu C. Martin 2021-07-20 18:15:47 +02:00 committed by GitHub
parent e65f05b121
commit c2a857a0e8

View file

@ -7,6 +7,8 @@ on:
# Triggers the workflow on push or pull request events but only for the master branch # Triggers the workflow on push or pull request events but only for the master branch
push: push:
branches: [ master ] branches: [ master ]
tags:
- 'v*.*.*'
pull_request: pull_request:
branches: [ master ] branches: [ master ]
@ -29,10 +31,12 @@ jobs:
- name: Compile LaTeX document - name: Compile LaTeX document
uses: xu-cheng/latex-action@v2 uses: xu-cheng/latex-action@v2
with: with:
root_file: main.tex root_file: main.tex
# Uploads resulting file to workflows - name: Release
- uses: actions/upload-artifact@v2 uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with: with:
name: PDF files: main.pdf
path: main.pdf env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}