Refactor module startup #47
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: releaser | |
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
permissions: | |
contents: write | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: '1.22.x' | |
- name: Install dependencies | |
run: | | |
go mod tidy | |
- name: Build | |
run: | | |
make build | |
- name: Create Release | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
gh release create `date -u +%Y%m%d`.${GITHUB_RUN_ID} \ | |
--repo="$GIT_REPOSITORY" \ | |
--title="Release `date -u +%Y%m%d`.${GITHUB_RUN_ID}" \ | |
--notes="`git log --pretty=format:'- %s' $GITHUB_SHA...HEAD`" \ | |
./dist/* | |
# steps: | |
# - | |
# name: Checkout | |
# uses: actions/checkout@v4 | |
# with: | |
# fetch-depth: 0 | |
# - | |
# name: Set up Go | |
# uses: actions/setup-go@v5 | |
# - | |
# name: Run GoReleaser | |
# uses: goreleaser/goreleaser-action@v6 | |
# with: | |
# # either 'goreleaser' (default) or 'goreleaser-pro' | |
# distribution: goreleaser | |
# # 'latest', 'nightly', or a semver | |
# version: '~> v2' | |
# args: release --clean --snapshot | |
# env: | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
# # Your GoReleaser Pro key, if you are using the 'goreleaser-pro' distribution | |
# # GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }} |