From e2649eaeab01064bdc0e123e96494eeecfa6d282 Mon Sep 17 00:00:00 2001 From: VTrelat Date: Wed, 29 Oct 2025 16:23:36 +0100 Subject: [PATCH 1/3] feat: add CI for automatic release generation --- .github/workflows/CI.yml | 62 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 .github/workflows/CI.yml diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml new file mode 100644 index 0000000..6454116 --- /dev/null +++ b/.github/workflows/CI.yml @@ -0,0 +1,62 @@ +name: CI + +on: + push: + branches: ["main"] # replace "main" with the default branch + pull_request: + branches: ["main"] + workflow_dispatch: + +jobs: + build: + runs_on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + # uses lean standard action with all default input values + - uses: leanprover/lean-action@v1 + with: + use-github-cache: true + build: true + # pack release + - name: Fetch release by tag + id: fetch-release + uses: pdamianik/release-tag-to-upload-url-action@v1.0.1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag: beer + token: ${{ github.token }} + continue-on-error: true + + - uses: dev-drprasad/delete-tag-and-release@v1.1 + name: Delete release if already existing + with: + delete_release: true + tag_name: beer + github_token: ${{ secrets.GITHUB_TOKEN }} + if: steps.fetch-release.outcome == 'success' + + - name: Create release + id: create-release + uses: actions/create-release@latest + with: + tag_name: beer + release_name: "BEer" + body: | + Automated release of BEer for ubuntu. + prerelease: false + draft: false + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: Upload beer + id: 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: .lake/build/bin/BEer + asset_name: BEer + asset_content_type: application/octet-stream \ No newline at end of file From 8efd4e03c8c648a5ae958154aa222adf6a319c3d Mon Sep 17 00:00:00 2001 From: VTrelat Date: Wed, 29 Oct 2025 16:24:40 +0100 Subject: [PATCH 2/3] fix: typo --- .github/workflows/CI.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 6454116..d8fc7d7 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -9,7 +9,7 @@ on: jobs: build: - runs_on: ubuntu-latest + runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 From 170b0405aa624be541450b7bf51ad0e80a536581 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vincent=20Tr=C3=A9lat?= <74003273+VTrelat@users.noreply.github.com> Date: Wed, 29 Oct 2025 16:25:59 +0100 Subject: [PATCH 3/3] Change CI trigger branches to all Updated CI workflow to trigger on all branches. --- .github/workflows/CI.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index d8fc7d7..77f178e 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -2,9 +2,9 @@ name: CI on: push: - branches: ["main"] # replace "main" with the default branch + branches: ["*"] # replace "main" with the default branch pull_request: - branches: ["main"] + branches: ["*"] workflow_dispatch: jobs: @@ -59,4 +59,4 @@ jobs: upload_url: ${{ steps.create-release.outputs.upload_url }} asset_path: .lake/build/bin/BEer asset_name: BEer - asset_content_type: application/octet-stream \ No newline at end of file + asset_content_type: application/octet-stream