Skip to content
This repository has been archived by the owner on Aug 16, 2022. It is now read-only.

Commit

Permalink
ci: fix build workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
rot1024 committed Jun 17, 2022
1 parent 647eb4f commit 5181985
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ jobs:
build:
name: Build and release
runs-on: ubuntu-latest
if: github.event.workflow_run.head_branch == 'main' && !startsWith(github.event.head_commit.message, 'v') || github.event.workflow_run.head_branch == 'release'
needs:
- info
env:
Expand All @@ -72,8 +73,9 @@ jobs:
env:
GORELEASER_CURRENT_TAG: ${{ needs.info.outputs.tag || '0.0.0' }}
- name: Rename artifacts
if: "!needs.info.outputs.tag"
run: for f in $ARTIFACTS; do mv $f $(echo $f | sed -E 's/_0\.0\.0-SNAPSHOT-[^_]*/_${{ needs.info.outputs.name }}/'); done
run: for f in $ARTIFACTS; do mv $f $(echo $f | sed -E 's/_0\.0\.0-SNAPSHOT-[^_]*/_${NAME}/'); done
env:
NAME: ${{ needs.info.outputs.tag || needs.info.outputs.name }}
- name: Release nightly/rc
if: "!needs.info.outputs.tag"
uses: ncipollo/release-action@v1
Expand Down Expand Up @@ -105,6 +107,7 @@ jobs:
runs-on: ubuntu-latest
needs:
- info
if: github.event.workflow_run.head_branch == 'main' && !startsWith(github.event.head_commit.message, 'v') || github.event.workflow_run.head_branch == 'release'
env:
IMAGE_NAME: reearth/reearth-backend
steps:
Expand Down

0 comments on commit 5181985

Please sign in to comment.