diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..f473428 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,38 @@ +name: Create Release + +on: + push: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout Repository + uses: actions/checkout@v2 + + - name: Set up Docker + uses: actions/setup-docker@v2 + + - name: Build Docker Image + run: docker build -t nspyc-pandoc . + + - name: Run Container and Generate PDF + run: docker run -v ${{ github.workspace }}/output:/data nspyc-pandoc + + - name: Create Release + id: create_release + uses: actions/create-release@v1 + with: + tag_name: $(grep 'subtitle:' convention.md | awk '{print $NF}') + release_name: $(grep 'subtitle:' convention.md | cut -d' ' -f 2-) + draft: false + prerelease: false + + - name: Upload PDF as Release Asset + uses: actions/upload-artifact@v2 + with: + name: convention.pdf + path: output/convention.pdf