diff options
| author | Evsyukov Denis Anatolyevich <[email protected]> | 2020-03-11 10:22:21 +0300 |
|---|---|---|
| committer | Evsyukov Denis Anatolyevich <[email protected]> | 2020-03-11 10:48:13 +0300 |
| commit | da6d83dd4b7b176227e9bb2dc38167680e53aa5f (patch) | |
| tree | 7936685086d21f306e4d7bc203b32be11dad2554 | |
| parent | [+] build (diff) | |
| download | t-da6d83dd4b7b176227e9bb2dc38167680e53aa5f.tar.xz t-da6d83dd4b7b176227e9bb2dc38167680e53aa5f.zip | |
[~] build workflow
| -rw-r--r-- | .github/workflows/build.yml | 42 |
1 files changed, 26 insertions, 16 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 75812b9..6abba75 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,20 +6,29 @@ on: jobs: build: - name: Publish for ${{ matrix.os }} - runs-on: ${{ matrix.os }} + name: Build + runs-on: ${{ matrix.config.os }} strategy: matrix: - include: - - os: ubuntu-latest - artifact_name: t - asset_name: t-linux-amd64 - - os: windows-latest - artifact_name: t.exe - asset_name: t-windows-amd64 - - os: macos-latest - artifact_name: t - asset_name: t-macos-amd64 + config: + - { + os: ubuntu-latest, + artifact_name: t, + asset_name: t-linux-amd64, + strip: true + } + - { + os: windows-latest, + artifact_name: t.exe, + asset_name: t-windows-amd64, + strip: false + } + - { + os: macos-latest, + artifact_name: t, + asset_name: t-macos-amd64, + strip: true + } steps: - uses: hecrj/setup-rust-action@v1 with: @@ -27,8 +36,9 @@ jobs: - uses: actions/checkout@v2 - name: Build run: cargo build --release - - name: UPX binary - uses: docker://gact/upx:latest + - name: Compress binaries + uses: svenstaro/upx-action@v1-release with: - file: target/release/${{ matrix.artifact_name }} - upx_args: '-9' + file: target/release/${{ matrix.config.artifact_name }} + args: '-9' + strip: ${{ matrix.config.strip }}
\ No newline at end of file |