Skip to content

Commit

Permalink
Make generated output pdf filenames predictable for Ci
Browse files Browse the repository at this point in the history
  • Loading branch information
timofurrer committed Jan 9, 2020
1 parent 4394564 commit c510867
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ jobs:
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
body: |
Release ${{ github.ref }} generated by the CI.
draft: false
prerelease: false
- name: Upload Slides
Expand All @@ -39,7 +41,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: GitWorkshop_Slides_*.pdf
asset_path: GitWorkshop_Slides.pdf
asset_name: Slides
asset_content_type: application/pdf
- name: Upload Handout
Expand All @@ -49,6 +51,6 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: GitWorkshop_Handout_*.pdf
asset_path: GitWorkshop_Handout.pdf
asset_name: Handout
asset_content_type: application/pdf
6 changes: 4 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,14 @@ all: slides handout
slides: gen $(PNGS)
cd $(TMP) && pdflatex ../gitworkshop.tex
cd $(TMP) && pdflatex ../gitworkshop.tex
mv $(TMP)/gitworkshop.pdf GitWorkshop_Slides_$(shell date "+%Y-%m-%d").pdf
mv $(TMP)/gitworkshop.pdf GitWorkshop_Slides.pdf
cp GitWorkshop_Slides.pdf GitWorkshop_Slides_$(shell date "+%Y-%m-%d").pdf

handout: gen $(PNGS)
cd $(TMP) && HANDOUT=1 pdflatex ../gitworkshop.tex
cd $(TMP) && HANDOUT=1 pdflatex ../gitworkshop.tex
mv $(TMP)/gitworkshop.pdf GitWorkshop_Handout_$(shell date "+%Y-%m-%d").pdf
mv $(TMP)/gitworkshop.pdf GitWorkshop_Handout.pdf
cp GitWorkshop_Handout.pdf GitWorkshop_Handout_$(shell date "+%Y-%m-%d").pdf

gen:
mkdir -p $(TMP)/diagrams
Expand Down

0 comments on commit c510867

Please sign in to comment.