Skip to content

Commit

Permalink
Update actions to build release zip in all run
Browse files Browse the repository at this point in the history
Signed-off-by: Shengqi Chen <harry-chen@outlook.com>
  • Loading branch information
Harry-Chen committed Feb 27, 2024
1 parent 4d64a7c commit b1d8f02
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 24 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,19 @@ jobs:
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
- name: Build and push
uses: docker/build-push-action@v4
uses: docker/build-push-action@v5
with:
push: true
context: "{{defaultContext}}:.github/workflows"
Expand Down
31 changes: 12 additions & 19 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ jobs:
container: ghcr.io/tuna/thuthesis-test-env
steps:
- uses: actions/checkout@v4
- name: Git describe
id: ghd
uses: proudust/gh-describe@v2
- name: Test thesis
run: make thesis
- name: Test spine
Expand All @@ -18,28 +21,18 @@ jobs:
run: make doc
- name: Test with l3build
run: make test
- name: Build release zip with l3build
run: l3build ctan --config build-ctan
- name: Upload release zip
uses: actions/upload-artifact@v4
with:
name: thuthesis-ctan-${{ steps.ghd.outputs.describe }}
path: thuthesis-ctan.zip
- name: Upload test results if failed
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
if: failure()
with:
name: test-result
name: test-result-${{ steps.ghd.outputs.describe }}
path: |
build/test
build/test-testfiles
build_release:
runs-on: ubuntu-latest
if: "startsWith(github.ref, 'refs/tags/v') || contains(github.event.head_commit.message, '[zip]')"
container: ghcr.io/tuna/thuthesis-test-env
steps:
- uses: actions/checkout@v4
- name: Install required packages
run: bash .github/workflows/install-packages.sh
- name: Build release zip with l3build
run: l3build ctan --config build-ctan
- name: Upload release zip
uses: actions/upload-artifact@v3
with:
name: thuthesis-ctan
path: thuthesis-ctan.zip

0 comments on commit b1d8f02

Please sign in to comment.