Skip to content

Commit

Permalink
chore: add outputs to jobs #major
Browse files Browse the repository at this point in the history
  • Loading branch information
grinish21 committed Jun 23, 2021
1 parent bd4c3c1 commit 1a41783
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pullRequest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ on:
pull_request:
branches: [ chore/gh-actions-update ]

name: check pullRequest
name: Test pullRequest

jobs:
build:
Expand Down
24 changes: 14 additions & 10 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ name: Release EarlyBird

jobs:
build:
name: Build and Release
name: Build and Tag
runs-on: ubuntu-latest
outputs:
new_tag: ${{ steps.bump-version.outputs.new_tag }}
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
Expand All @@ -17,11 +19,6 @@ jobs:
uses: actions/checkout@v2
- name: Build project
run: ./build.sh
release:
needs: build
name: Tag and Release
runs-on: ubuntu-latest
steps:
- name: Bump version and push tag
id: bump-version
uses: anothrNick/[email protected]
Expand All @@ -30,12 +27,19 @@ jobs:
WITH_V: true
RELEASE_BRANCHES: .*
INITIAL_VERSION: 2.0.0
release:
needs: build
name: Tag and Release
runs-on: ubuntu-latest
outputs:
upload_url: ${{ steps.create-release.outputs.upload_url }}
steps:
- name: Create Release
id: create-release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ steps.bump-version.outputs.new_tag }}
tag: ${{ needs.build.outputs.new_tag }}
draft: false
prerelease: false
publishLinux:
Expand All @@ -49,7 +53,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create-release.outputs.upload_url }}
upload_url: ${{ needs.release.outputs.upload_url }}
asset_path: ./binaries/go-earlybird-linux
asset_name: go-earlybird-linux
asset_content_type: application/octet-stream
Expand All @@ -64,7 +68,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create-release.outputs.upload_url }}
upload_url: ${{ needs.release.outputs.upload_url }}
asset_path: ./binaries/go-earlybird
asset_name: go-earlybird-macos
asset_content_type: application/octet-stream
Expand All @@ -79,7 +83,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create-release.outputs.upload_url }}
upload_url: ${{ needs.release.outputs.upload_url }}
asset_path: ./binaries/go-earlybird.exe
asset_name: go-earlybird.exe
asset_content_type: application/x-msdownload

0 comments on commit 1a41783

Please sign in to comment.