Skip to content

Release by @jonathanlam 88d4fea52a7e43024a302ede5dd05b7fb1fe5915 #8

Release by @jonathanlam 88d4fea52a7e43024a302ede5dd05b7fb1fe5915

Release by @jonathanlam 88d4fea52a7e43024a302ede5dd05b7fb1fe5915 #8

Workflow file for this run

name: Release
on:
push:
branches:
- main
concurrency:
group: release
cancel-in-progress: true
run-name: Release by @${{ github.actor }} ${{ github.sha }}
permissions:
contents: write
pull-requests: read
jobs:
get-version:
name: Version
runs-on: ubuntu-latest
outputs:
version: ${{ steps.get-version.outputs.version }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Get Release Version
id: get-version
uses: nullify-platform/github-actions/actions/release-version@main
- run: |
echo "**Version:** ${{ steps.get-version.outputs.version }}" >> $GITHUB_STEP_SUMMARY
build:
if: ${{ needs.get-version.outputs.version != 'undefined' }}
needs: [get-version]
runs-on: ubuntu-latest
strategy:
matrix:
include:
- goos: linux
goarch: amd64
- goos: linux
goarch: arm64
- goos: darwin
goarch: amd64
- goos: darwin
goarch: arm64
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.23'
- name: Build
env:
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
CGO_ENABLED: '0'
run: go build -o slack-cli-${{ matrix.goos }}-${{ matrix.goarch }} .
- uses: actions/upload-artifact@v4
with:
name: slack-cli-${{ matrix.goos }}-${{ matrix.goarch }}
path: slack-cli-${{ matrix.goos }}-${{ matrix.goarch }}
release:
needs: [get-version, build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
path: artifacts
merge-multiple: true
- name: Create release
env:
GH_TOKEN: ${{ github.token }}
run: gh release create "v${{ needs.get-version.outputs.version }}" artifacts/* --repo ${{ github.repository }} --title "v${{ needs.get-version.outputs.version }}" --generate-notes