Skip to content

Commit

Permalink
migrated to go releaser
Browse files Browse the repository at this point in the history
  • Loading branch information
wingsuitist committed Oct 5, 2023
1 parent fe56c4e commit 7b56c3a
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 63 deletions.
63 changes: 0 additions & 63 deletions .github/workflows/main.yml

This file was deleted.

31 changes: 31 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: goreleaser

on:
push:
# run only against tags
tags:
- "*"

permissions:
contents: write
# packages: write
# issues: write

jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- run: git fetch --force --tags
- uses: actions/setup-go@v4
with:
go-version: stable
- uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31 changes: 31 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Go

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:

build:
name: Build
runs-on: ubuntu-latest
steps:

- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: 1.19

- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Test
run: go test ./...

- name: Build
env:
GOOS: linux
GOARCH: amd64
run: go build -v -o build/retry-${{ env.GOOS }}-${{ env.GOARCH }} ./cmd/main.go

0 comments on commit 7b56c3a

Please sign in to comment.