Skip to content

Merge pull request #60 from engnadeau/refactor #22

Merge pull request #60 from engnadeau/refactor

Merge pull request #60 from engnadeau/refactor #22

Workflow file for this run

name: Release
on:
push:
branches:
- master
jobs:
build:
uses: ./.github/workflows/build.yml
release:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v3
with:
name: pdf
- name: Display structure of downloaded files
run: ls -R
- name: Build site
run: cp *.pdf site/
- name: Set tag name
id: tag_name
run: echo "::set-output name=tag_name::$(date +'%Y.%m.%d.%H.%M.%S')"
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
# This token is provided by Actions; do not need to create token
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.tag_name.outputs.tag_name }}
release_name: Release ${{ steps.date.outputs.date }}
draft: false
prerelease: false
- name: Upload Release Asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# This pulls from the CREATE RELEASE step above,
# referencing it's ID to get its outputs object,
# which include a `upload_url`.
# See this blog post for more info:
# https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./nicholas-nadeau_cv.pdf
asset_name: nicholas-nadeau_cv.pdf
asset_content_type: application/pdf
- name: Deploy to Pages
uses: JamesIves/github-pages-deploy-action@v4.4.3
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: gh-pages # The branch the action should deploy to.
FOLDER: site # The folder the action should deploy.