From 0c2b152c7c04886b0d1a42be3482a0b7cca1aaca Mon Sep 17 00:00:00 2001 From: VSteveHL Date: Mon, 7 Jul 2025 10:51:51 +0800 Subject: [PATCH 1/4] feat: Modify GitHub workflow file MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit I have modified the `.github/workflows/release.yaml` file and made the following changes: - Removed the `repo` variable: - This variable specifies which repository the release targets. Since its default value is the current repository, I believe leaving it empty is reasonable. - Added `name` - Added `tag_name` - Added `body` to provide some contextual information. --- .github/workflows/release.yaml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index d2a887c2..376beb70 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -46,8 +46,15 @@ jobs: - name: Release uses: softprops/action-gh-release@v2 with: - repo: ufo5260987423/scheme-langserver + name: Scheme LangServer Auto-generated Build + tag_name: automated_build files: | build/scheme-langserver-x86_64-linux-glibc build/scheme-langserver-x86_64-linux-musl + body: | + This is an automated release of Scheme LangServer. + + **Commit:** ${{ github.sha }} + **Branch:** ${{ github.ref_name }} + **Pipeline Run:** ${{ github.run_id }} From 25e88a9122d24db45c8830c5339bfa3ac284aba4 Mon Sep 17 00:00:00 2001 From: VSteveHL Date: Mon, 7 Jul 2025 13:27:03 +0800 Subject: [PATCH 2/4] fix: Fix Dockerfile.musl issue preventing --static compilation In commit 0d7952775bf576ae2cc862319c54b831e571411e, a modification was made to `.github/workflows/release.yaml`, adding the `--static` parameter in the "Compile executable on Linux musl" step. However, the corresponding `Dockerfile.musl` was not updated, which caused errors during the build process. This commit adds the `util-linux-static` package to `Dockerfile.musl`, allowing the build to proceed successfully. --- Dockerfile.musl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile.musl b/Dockerfile.musl index a507f523..50bf9eb6 100644 --- a/Dockerfile.musl +++ b/Dockerfile.musl @@ -52,8 +52,8 @@ RUN akku install FROM alpine:latest ENV DEBIAN_FRONTEND=noninteractive -RUN apk update && apk add \ - git alpine-sdk util-linux-dev libuuid make +RUN apk update && apk add --no-cache \ + git alpine-sdk util-linux-dev libuuid make util-linux-static # add chez scheme COPY --from=build-chez /usr/bin/scheme /usr/bin/ From 6177f9c3183b5306646740514f9d463f1b794b13 Mon Sep 17 00:00:00 2001 From: VSteveHL Date: Thu, 10 Jul 2025 14:58:14 +0800 Subject: [PATCH 3/4] Create release.yml --- .github/workflows/release.yml | 61 +++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 00000000..70e74a02 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,61 @@ +# stub from https://github.com/softprops/action-gh-release +name: Release +on: + push: + tags: + - "*.*.*" + pull_request: + branches: main + workflow_dispatch: + +jobs: + build-and-release: + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Build Linux glibc image + run: docker build . + + - name: Build Linux musl image + run: docker build -f Dockerfile.musl . + + - name: Compile executable on Linux glibc + run: | + mkdir -p build + docker run \ + -v ./build:/root/scheme-langserver/build/ \ + $(docker build -q .) \ + bash -c 'source .akku/bin/activate + compile-chez-program run.ss --static + mv run build/scheme-langserver-x86_64-linux-glibc || exit 1 + ' + + - name: Compile executable on Linux musl + run: | + mkdir -p build + docker run \ + -v ./build:/root/scheme-langserver/build/ \ + $(docker build -f Dockerfile.musl -q .) \ + ash -c 'source .akku/bin/activate + compile-chez-program run.ss --static + mv run build/scheme-langserver-x86_64-linux-musl || exit 1 + ' + + - name: Release + uses: softprops/action-gh-release@v2 + with: + name: Scheme LangServer Auto-generated Build + tag_name: automated_build + files: | + build/scheme-langserver-x86_64-linux-glibc + build/scheme-langserver-x86_64-linux-musl + body: | + This is an automated release of Scheme LangServer. + + **Commit:** ${{ github.sha }} + **Branch:** ${{ github.ref_name }} + **Pipeline Run:** ${{ github.run_id }} + From 3b0754634460e7d04b1bf9def624a9273748ede4 Mon Sep 17 00:00:00 2001 From: VSteveHL Date: Thu, 10 Jul 2025 15:06:38 +0800 Subject: [PATCH 4/4] test --- .github/workflows/release.yml | 61 ----------------------------------- 1 file changed, 61 deletions(-) delete mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index 70e74a02..00000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,61 +0,0 @@ -# stub from https://github.com/softprops/action-gh-release -name: Release -on: - push: - tags: - - "*.*.*" - pull_request: - branches: main - workflow_dispatch: - -jobs: - build-and-release: - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@v4 - - - name: Build Linux glibc image - run: docker build . - - - name: Build Linux musl image - run: docker build -f Dockerfile.musl . - - - name: Compile executable on Linux glibc - run: | - mkdir -p build - docker run \ - -v ./build:/root/scheme-langserver/build/ \ - $(docker build -q .) \ - bash -c 'source .akku/bin/activate - compile-chez-program run.ss --static - mv run build/scheme-langserver-x86_64-linux-glibc || exit 1 - ' - - - name: Compile executable on Linux musl - run: | - mkdir -p build - docker run \ - -v ./build:/root/scheme-langserver/build/ \ - $(docker build -f Dockerfile.musl -q .) \ - ash -c 'source .akku/bin/activate - compile-chez-program run.ss --static - mv run build/scheme-langserver-x86_64-linux-musl || exit 1 - ' - - - name: Release - uses: softprops/action-gh-release@v2 - with: - name: Scheme LangServer Auto-generated Build - tag_name: automated_build - files: | - build/scheme-langserver-x86_64-linux-glibc - build/scheme-langserver-x86_64-linux-musl - body: | - This is an automated release of Scheme LangServer. - - **Commit:** ${{ github.sha }} - **Branch:** ${{ github.ref_name }} - **Pipeline Run:** ${{ github.run_id }} -