update: bump GitHub Actions dependencies to latest versions #44
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Rust | |
| on: [push] | |
| env: | |
| CARGO_TERM_COLOR: always | |
| RELEASE_TAG: idl-latest | |
| jobs: | |
| linux: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Get processor arch | |
| run: echo "PROCESSOR_ARCH=`uname -p`" >> $GITHUB_ENV | |
| - name: Build | |
| run: cargo build --release --verbose | |
| - name: Run tests | |
| run: cargo test --verbose | |
| - name: Prepare Release | |
| run: tar --transform 's/.*\///g' -zcvf ${{github.workspace}}/${{ runner.os }}-${{ env.PROCESSOR_ARCH }}-packet_generator.tar.gz target/*/packet_generator | |
| - name: Upload linux build | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: linux_build | |
| path: ${{github.workspace}}/${{ runner.os }}-${{ env.PROCESSOR_ARCH }}-packet_generator.tar.gz | |
| windows: | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Build | |
| run: cargo build --release --verbose | |
| - name: Run tests | |
| run: cargo test --verbose | |
| - name: Prepare Release | |
| run: | | |
| copy-item ${{github.workspace}}\target\release\packet_generator.exe -destination ${{github.workspace}}\packet_generator.exe | |
| 7z a ${{github.workspace}}/windows-amd64-packet_generator.zip ${{github.workspace}}\packet_generator.exe | |
| - name: Upload windows build | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: windows_build | |
| path: ${{github.workspace}}/windows-amd64-packet_generator.zip | |
| release: | |
| runs-on: ubuntu-latest | |
| needs: [linux, windows] | |
| if: github.ref == 'refs/heads/master' | |
| steps: | |
| - name: Download linux build | |
| uses: actions/download-artifact@v6 | |
| with: | |
| name: linux_build | |
| - name: Download windows build | |
| uses: actions/download-artifact@v6 | |
| with: | |
| name: windows_build | |
| - name: Release | |
| uses: ncipollo/release-action@v1.8.1 | |
| with: | |
| allowUpdates: true | |
| omitBodyDuringUpdate: true | |
| omitNameDuringUpdate: true | |
| replacesArtifacts: true | |
| body: latest packet_generator build | |
| artifacts: "*-packet_generator.tar.gz,*-packet_generator.zip" | |
| tag: ${{env.RELEASE_TAG}} | |
| token: ${{ secrets.GITHUB_TOKEN }} | |