Skip to content

Commit

Permalink
fix file hierarchy in release.zip also make the final release zip nam…
Browse files Browse the repository at this point in the history
…e better
  • Loading branch information
roffidaijoubu committed Dec 14, 2024
1 parent 7074ff4 commit 16a8a0a
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,24 @@ jobs:
- name: Build
run: |
cd backend
go build -v -ldflags="-s -w -H=windowsgui" -trimpath -o app.exe
go build -v -ldflags="-s -w" -trimpath -o app.exe
- name: Create ZIP
run: |
Compress-Archive -Path backend/app.exe, backend/static/* -DestinationPath release.zip
# Create a temporary directory for the release
New-Item -ItemType Directory -Path release
# Copy executable to release dir
Copy-Item backend/app.exe release/
# Create static directory and copy files
New-Item -ItemType Directory -Path release/static
Copy-Item backend/static/* release/static/
# Create the final ZIP
Compress-Archive -Path release/* -DestinationPath "chat-tools-${{ github.ref_name }}.zip"
- name: Create Release
uses: softprops/action-gh-release@v1
with:
files: release.zip
files: chat-tools-${{ github.ref_name }}.zip
name: Release ${{ github.ref_name }}
draft: false
prerelease: false
Expand Down

0 comments on commit 16a8a0a

Please sign in to comment.