Skip to content

Commit

Permalink
ci(workflow): update release trigger to pull_request and condition
Browse files Browse the repository at this point in the history
  • Loading branch information
nullswan committed Oct 21, 2024
1 parent 0d0b2b0 commit 0cf6821
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ name: Release

on:
push:
tags:
- "*"
pull_request:

permissions:
contents: write
Expand Down Expand Up @@ -35,7 +34,6 @@ jobs:
shell: bash
env:
CGO_ENABLED: 1
PKG_CONFIG_PATH: ${{ env.PKG_CONFIG_PATH }}
run: |
go build \
-ldflags "-X main.buildDate=$(date -u +'%Y-%m-%dT%H:%M:%SZ') \
Expand All @@ -55,6 +53,7 @@ jobs:

release:
needs: build
if: startsWith(github.ref, 'refs/tags/')
runs-on: ubuntu-latest
steps:
- name: Download Artifacts
Expand Down

0 comments on commit 0cf6821

Please sign in to comment.