[PATCH v2 10/10] .github: add a runner to build the latest draft
Alex Bennée <[email protected]> Fri, 10 Oct 2025 12:20:10 +0100
| Newsgroups | dev.linux.lists.virtio-comment |
|---|---|
| Message-ID | <[email protected]> |
This will run each time anything is pushed to the repository and store the result in the release assets area of github. To see an example of it in practice see the virtio-msg repo: https://github.com/Linaro/virtio-msg-spec/releases Signed-off-by: Alex Bennée <[email protected]> Message-ID: <[email protected]> --- .github/workflows/deploy.yaml | 37 +++++++++++++++++++++++++++++++++++ .github/workflows/test.yml | 15 ++++++++++++++ 2 files changed, 52 insertions(+) create mode 100644 .github/workflows/deploy.yaml create mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml new file mode 100644 index 0000000..fec4910 --- /dev/null +++ b/.github/workflows/deploy.yaml @@ -0,0 +1,37 @@ +name: Deploy current state + +on: [push] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: xu-cheng/texlive-action@v2 + with: + scheme: full + run: | + apk add file font-liberation make zip + make local-all + echo ${{ github.sha }} > Release.txt + + - name: Create Draft Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{github.ref_name}}-${{ github.repository_owner }}-draft-v${{ github.run_number }} + release_name: Draft ${{ github.run_number }} + draft: false + prerelease: false + + - name: Upload Release Asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: virtio-v1.4-wd01.pdf + asset_name: ${{github.ref_name}}-${{ github.repository_owner }}-draft-v${{ github.run_number }}.pdf + asset_content_type: application/pdf diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..34f4f44 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,15 @@ +name: CI + +on: [pull_request] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: xu-cheng/texlive-action@v2 + with: + scheme: full + run: | + apk add file make zip + make local-html -- 2.47.3