Add cv #33
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build PDF | |
# actions/deploy-pages does not allow you to clear the history. | |
# So s0/git-publish-subdir-action is used to push the file to the pages branch, | |
# and the default deployment from branch is used to deploy the cv to github pages. | |
# | |
# The texlive docker image speeds up the build, but doesn't include git, | |
# which is needed to push the cv to the separate branch. | |
# Therefore a separate job is used. | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
container: | |
image: ghcr.io/moderncv/debian-texlive-docker:main | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Force public version | |
run: touch forcepublic.tex | |
- name: Build PDF | |
run: latexmk -pdf -cd ./maxbothe-cv.tex | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: maxbothe-cv | |
path: ./maxbothe-cv.pdf | |
deploy: | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- name: Download artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: maxbothe-cv | |
- name: Publish PDF | |
uses: s0/git-publish-subdir-action@develop | |
env: | |
REPO: self | |
BRANCH: gh-pages | |
FOLDER: . | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SQUASH_HISTORY: true | |
SKIP_EMPTY_COMMITS: true |