From 837dbfdb2cdc73f3107f2e0dbb000f1629b7d7b5 Mon Sep 17 00:00:00 2001 From: nathabonfim59 Date: Fri, 20 Dec 2024 04:29:55 -0300 Subject: [PATCH] build(ci): updated artefacts generation --- .github/workflows/editai-release.yaml | 37 ++++++++++++++++++++------- wails.json | 2 +- 2 files changed, 29 insertions(+), 10 deletions(-) diff --git a/.github/workflows/editai-release.yaml b/.github/workflows/editai-release.yaml index a932026..0b70a23 100644 --- a/.github/workflows/editai-release.yaml +++ b/.github/workflows/editai-release.yaml @@ -36,11 +36,14 @@ jobs: build: true wails-build-webview2: "embed" go-version: ^1.22 + - name: Rename artifact + run: | + VERSION=${GITHUB_REF#refs/tags/v} + mv build/bin/editai "build/bin/editai-${VERSION}-linux-amd64" - name: Upload Release Artifact uses: softprops/action-gh-release@v1 with: - files: "build/bin/editai" - name: "editai-${{ github.ref_name }}-linux-amd64" + files: "build/bin/editai-*-linux-amd64" env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -59,11 +62,19 @@ jobs: package: true build: true go-version: ^1.22 - - name: Upload Release Artifact + - name: Package macOS artifacts + run: | + VERSION=${GITHUB_REF#refs/tags/v} + cd build/bin + mv editai.app "editai-${VERSION}-mac.app" + zip -r "editai-${VERSION}-mac.app.zip" "editai-${VERSION}-mac.app" + mv editai.pkg "editai-${VERSION}-mac.pkg" + - name: Upload Release Artifacts uses: softprops/action-gh-release@v1 with: - files: "build/bin/editai" - name: "editai-${{ github.ref_name }}-darwin-universal" + files: | + build/bin/editai-*-mac.app.zip + build/bin/editai-*-mac.pkg env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -76,7 +87,7 @@ jobs: submodules: recursive - uses: ./.github/actions/wails with: - build-name: editai.exe + build-name: editai build-platform: windows/amd64 wails-version: "v2.9.2" package: true @@ -84,10 +95,18 @@ jobs: nsis: true wails-build-webview2: "embed" go-version: ^1.22 - - name: Upload Release Artifact + - name: Rename artifacts + shell: bash + run: | + VERSION=${GITHUB_REF#refs/tags/v} + cd build/bin + mv editai.exe "editai-${VERSION}-windows-amd64-portable.exe" + mv editai-installer.exe "editai-${VERSION}-windows-amd64-installer.exe" + - name: Upload Release Artifacts uses: softprops/action-gh-release@v1 with: - files: "build/bin/editai.exe" - name: "editai-${{ github.ref_name }}-windows-amd64" + files: | + build/bin/editai-*-windows-amd64-portable.exe + build/bin/editai-*-windows-amd64-installer.exe env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/wails.json b/wails.json index 6184916..eded8f9 100644 --- a/wails.json +++ b/wails.json @@ -14,7 +14,7 @@ "info": { "companyName": "EditAI", "productName": "EditAI", - "productVersion": "0.1.4", + "productVersion": "0.1.5", "copyright": "Copyright 2024 © - EditAI", "comments": "An AI-powered code editor" }