Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update release.yml #4

Merged
merged 1 commit into from
Sep 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 19 additions & 6 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,15 +50,27 @@ jobs:
uses: actions/checkout@v4
- name: Build
run: cargo build --release --verbose
- name: Package (Linux)
if: matrix.os == 'ubuntu-latest'
run: tar -czvf ./target/release/ratisui-linux-amd64.tar.gz LICENSE README.md -C ./target/release ratisui

- name: Package (Mac)
if: matrix.os == 'macos-latest'
run: tar -czvf ./target/release/ratisui-mac.tar.gz LICENSE README.md -C ./target/release ratisui

- name: Package (Windows)
if: matrix.os == 'windows-latest'
run: Compress-Archive -Path '.\README.md', '.\LICENSE', '.\target\release\ratisui.exe' -DestinationPath '.\target\release\ratisui-windows-amd64.zip'

- name: Upload Release Asset (Linux)
if: matrix.os == 'ubuntu-latest'
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create_release.outputs.upload_url }}
asset_path: ./target/release/ratisui
asset_name: ratisui-linux
asset_path: ./target/release/ratisui-linux-amd64.tar.gz
asset_name: ratisui-linux-amd64.tar.gz
asset_content_type: application/octet-stream
- name: Upload Release Asset (Mac)
if: matrix.os == 'macos-latest'
Expand All @@ -67,16 +79,17 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create_release.outputs.upload_url }}
asset_path: ./target/release/ratisui
asset_name: ratisui-mac
asset_path: ./target/release/ratisui-mac.tar.gz
asset_name: ratisui-mac.tar.gz
asset_content_type: application/octet-stream

- name: Upload Release Asset (Windows)
if: matrix.os == 'windows-latest'
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create_release.outputs.upload_url }}
asset_path: .\target\release\ratisui.exe
asset_name: ratisui.exe
asset_path: .\target\release\ratisui-windows-amd64.zip
asset_name: ratisui-windows-amd64.zip
asset_content_type: application/octet-stream
Loading