Skip to content

add missing " #1

add missing " #1 #7

Workflow file for this run

name: Compile Latex and Release PDF
on:
push:
tags:
- 'v*'
branches:
- '*'
jobs:
build_latex:
runs-on: self-ubuntu-24.04
outputs:
prefix: ${{ steps.repo_name.outputs.prefix }}
steps:
- name: Set up Git repository
uses: actions/checkout@v4
- name: Compile LaTeX document
uses: xu-cheng/latex-action@v3
with:
root_file: main.tex
- name: Get Repository Name
id: repo_name
run: |
prefix=$(echo "${{ github.repository }}" | cut -d'/' -f2)
echo "prefix=$prefix" >> GITHUB_OUTPUT
- name: Upload PDF
uses: actions/upload-artifact@v4
with:
# get the name of the repo without the organisation
name: pdf-${{ steps.repo_name.outputs.prefix }}
path: main.pdf
download:
runs-on: self-ubuntu-24.04
needs: build_latex
env:
veersionedpdf: ${{ needs.build_latex.outputs.prefix }}.pdf
steps:
- name: Download PDF
uses: actions/download-artifact@v4
with:
name: ${{ needs.build_latex.outputs.prefix }}.pdf
release:
runs-on: ubuntu-latest
needs: build_latex
if: startsWith(github.ref ,'refs/tags/v')
env:
veersionedpdf: ${{ needs.build_latex.outputs.prefix }}-v${{ github.ref_name }}.pdf
steps:
- name: Download PDF
uses: actions/download-artifact@v4
with:
name: ${{ needs.build_latex.outputs.prefix }}.pdf
- name: Rename to add version
run: mv ${{ github.repository }}.pdf ${{ env.veersionedpdf}}
- name: Create Release
id: create_release
uses: softprops/action-gh-release@v2
with:
draft: false
prerelease: ${{ contains(github.ref, 'alpha') || contains(github.ref, 'beta') || contains(github.ref, 'rc') || contains(github.ref, 'preview') }}
name: Release ${{ github.ref_name }}
generate_release_notes: true
tag_name: ${{ github.ref }}
token: ${{ secrets.GITHUB_TOKEN }}
files: |
${{ env.veersionedpdf }}