Skip to content

Commit

Permalink
chore: release github action
Browse files Browse the repository at this point in the history
  • Loading branch information
zaucy committed Apr 23, 2023
1 parent 078fa74 commit 411fed3
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: release

on:
release:
types: [published]

jobs:
release-linux-x64-binary:
runs-on: ubuntu-latest
steps:
- uses: actions/cache@v3
with:
path: |
~/.cache/bazelisk
~/.cache/bazel-disk-cache
key: ${{runner.os}}-bazel-cache
- uses: actions/checkout@v3
- run: 'bazel build --config=ci //cli:ecsact_rtb'
- run: 'cp ./bazel-bin/cli/ecsact_rtb ecsact_rtb_${{ github.ref_name }}_linux_x64'
- run: 'gh release upload ${{ github.ref_name }} ecsact_rtb_${{ github.ref_name }}_linux_x64'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
OWNER: ${{ github.repository_owner }}
REPO: ${{ github.event.repository.name }}

release-windows-x64-binary:
runs-on: windows-latest
steps:
- uses: actions/cache@v3
with:
path: |
/Users/runneradmin/AppData/Local/bazelisk
/Users/runneradmin/.cache/bazel-disk-cache
key: ${{runner.os}}-bazel-cache
- uses: actions/checkout@v3
- run: 'bazel build --config=ci //cli:ecsact_rtb'
- run: 'Copy-Item .\bazel-bin\cli\ecsact_rtb.exe -Destination .\ecsact_rtb_${{ github.ref_name }}_windows_x64.exe'
- run: 'gh release upload ${{ github.ref_name }} ./ecsact_rtb_${{ github.ref_name }}_windows_x64.exe'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
OWNER: ${{ github.repository_owner }}
REPO: ${{ github.event.repository.name }}

0 comments on commit 411fed3

Please sign in to comment.