Compare commits

...

3 commits

Author SHA1 Message Date
335f59f2d8 Update generated file name
All checks were successful
Compile LaTeX and Release PDF / build_latex (push) Successful in 1m0s
2025-03-07 09:08:13 -03:00
b16ce512bb Another commit to show in release notes 2025-03-07 09:06:30 -03:00
8a38bd389a Update how we retrieve commit messages 2025-03-07 09:06:05 -03:00

View file

@ -33,21 +33,29 @@ jobs:
# Step 3: Compile the LaTeX.
- name: Compile LaTeX document
run: |
latexmk -pdf -jobname=dist/main main.tex && rm -f dist/main.aux dist/main.log dist/main.out dist/main.fls dist/main.fdb_latexmk
latexmk -pdf -jobname=dist/leonardo-murca-resume main.tex
rm -f dist/leonardo-murca-resume.aux dist/leonardo-murca-resume.log dist/leonardo-murca-resume.out dist/leonardo-murca-resume.fls dist/leonardo-murca-resume.fdb_latexmk
# Step 4: Get commit messages for the release (from the tag)
- name: Get commit messages for the release
id: get_commit_messages
run: |
COMMITS=$(git log ${GITHUB_REF} --pretty=format:'- %s' | head -n 20)
echo "commits=$COMMITS" >> $GITHUB_ENV
LAST_TAG=$(git describe --tags --abbrev=0 $(git rev-list --tags --skip=1 --max-count=1) 2>/dev/null || echo "")
if [ -z "$LAST_TAG" ]; then
COMMITS=$(git log --pretty=format:'- %s' | head -n 20)
else
COMMITS=$(git log $LAST_TAG..HEAD --pretty=format:'- %s' | head -n 20)
fi
echo "commits<<EOF" >> $GITHUB_ENV
echo "$COMMITS" >> $GITHUB_ENV
echo "EOF" >> $GITHUB_ENV
# Step 5: Upload the compiled PDF as a release asset
- name: Upload PDF to Release
uses: actions/upload-artifact@v3
with:
name: main.pdf # The file to upload as the release asset
path: dist/main.pdf # Path to the compiled PDaF
name: leonardo-murca-resume.pdf # The file to upload as the release asset.
path: dist/leonardo-murca-resume.pdf # Path to the compiled PDaF
# Step 6: Create release
- name: Create release