Renovate: paddyroddy/.github #84
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: Deploy | |
on: | |
push: | |
branches: | |
- main | |
- renovate/** | |
pull_request: | |
concurrency: | |
cancel-in-progress: true | |
group: >- | |
${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
jobs: | |
chktex: | |
runs-on: ubuntu-latest | |
steps: | |
# yamllint disable-line rule:line-length | |
- uses: paddyroddy/.github/actions/latex/chktex@5c7fda77e5d84521b7dfe2e289bfec422ceffbb9 # v0 | |
vale: | |
runs-on: ubuntu-latest | |
steps: | |
# yamllint disable-line rule:line-length | |
- uses: paddyroddy/.github/actions/latex/vale@5c7fda77e5d84521b7dfe2e289bfec422ceffbb9 # v0 | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
vale-flags: --glob='!{config/,figures/*/example_,thesis}*' | |
compile-latex: | |
runs-on: ubuntu-latest | |
steps: | |
# yamllint disable-line rule:line-length | |
- uses: paddyroddy/.github/actions/latex/compile@5c7fda77e5d84521b7dfe2e289bfec422ceffbb9 # v0 | |
- name: Upload artefacts | |
# yamllint disable-line rule:line-length | |
uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 # v4 | |
with: | |
name: artefacts | |
path: |- | |
*.bib | |
*.bcf | |
if-no-files-found: error | |
check-citations-referenced: | |
runs-on: ubuntu-latest | |
needs: compile-latex | |
steps: | |
- name: Download artefacts | |
# yamllint disable-line rule:line-length | |
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4 | |
with: | |
name: artefacts | |
- name: Fix regex for checkcites | |
# yamllint disable-line rule:line-length | |
uses: xu-cheng/texlive-action@3586544d56723b23ab69aec1e9d73e7220d9c313 # v2 | |
id: references | |
with: | |
scheme: full | |
run: >- | |
sed -i 's#\sglob="false"##' thesis.bcf; echo uncited=$(checkcites -b | |
biber thesis -u | grep -c "=>") >> $GITHUB_OUTPUT | |
- name: Check all references cited | |
if: ${{ steps.references.outputs.uncited > 0 }} | |
# yamllint disable-line rule:line-length | |
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 | |
with: | |
script: core.setFailed('Not all references cited') | |
upload-to-dropbox: | |
if: github.ref == 'refs/heads/main' | |
needs: compile-latex | |
runs-on: ubuntu-latest | |
steps: | |
- name: Download artefacts | |
# yamllint disable-line rule:line-length | |
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4 | |
with: | |
name: artefacts | |
# yamllint disable-line rule:line-length | |
- uses: paddyroddy/.github/actions/dropbox@5c7fda77e5d84521b7dfe2e289bfec422ceffbb9 # v0 | |
with: | |
configfile-version: ${{ secrets.CONFIGFILE_VERSION }} | |
files-to-upload: $(find . -maxdepth 1 -name '*.pdf' -print) | |
oauth-app-key: ${{ secrets.OAUTH_APP_KEY }} | |
oauth-app-secret: ${{ secrets.OAUTH_APP_SECRET }} | |
oauth-refresh-token: ${{ secrets.OAUTH_REFRESH_TOKEN }} |