Skip to content

Merge pull request #9 from odanado/main #2

Merge pull request #9 from odanado/main

Merge pull request #9 from odanado/main #2

Workflow file for this run

name: Release
on:
push:
branches:
- release/cli
jobs:
get-new-version:
runs-on: ubuntu-latest
outputs:
value: ${{ steps.bump-semver.outputs.new_version }}
steps:
- uses: actions/checkout@v4
- uses: actions-ecosystem/action-get-merged-pull-request@v1
id: get-merged-pull-request
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
- uses: actions-ecosystem/action-release-label@v1
id: release-label
with:
labels: ${{ steps.get-merged-pull-request.outputs.labels }}
label_prefix: "bump:"
- uses: actions-ecosystem/action-get-latest-tag@v1
id: get-latest-tag
- uses: actions-ecosystem/action-bump-semver@v1
id: bump-semver
with:
current_version: ${{ steps.get-latest-tag.outputs.tag }}
level: ${{ steps.release-label.outputs.level }}
goreleaser:
runs-on: ubuntu-latest
needs: [get-new-version]
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: stable
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
version: ${{ needs.get-new-version.outputs.value }}
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}