Skip to content

Merge pull request #58 from aris-space/DPR-Test #49

Merge pull request #58 from aris-space/DPR-Test

Merge pull request #58 from aris-space/DPR-Test #49

Workflow file for this run

name: Tag and Release
on:
push:
branches: [main]
jobs:
tag_release:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch full history to detect changes
- name: Create Tag
id: create_tag
uses: Songmu/tagpr@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Remove Watermark from Header
if: ${{ steps.create_tag.outputs.tag != '' }}
run: |
sed -i 's/\\setboolean{isDraft}{true}/\\setboolean{isDraft}{false}/' src/common/lib/header.tex
- name: Compile and Move LaTeX Documents Inside Docker
if: ${{ steps.create_tag.outputs.tag != '' }}
run: |
docker run --rm \
-v "${{ github.workspace }}:/workspace" \
-w /workspace \
texlive/texlive:latest \
bash -c "apt-get update && \
apt-get install -y git python3-pip python3-venv && \
python3 -m venv /workspace/venv && \
/workspace/venv/bin/pip install gitpython && \
/workspace/venv/bin/python scripts/compile-all-latex.py && \
/workspace/venv/bin/python scripts/move-files.py"
- name: Create GitHub Release with PDFs
if: ${{ steps.create_tag.outputs.tag != '' }}
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ steps.create_tag.outputs.tag }}
files: release/*