Skip to content

Commit

Permalink
add goreleaser and git ignore
Browse files Browse the repository at this point in the history
  • Loading branch information
Yonah Dissen committed Jul 23, 2023
1 parent 73bbf63 commit cc5c3e9
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 12 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/merge-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: build

on:
pull_request:
types:
- opened
- synchronize
branches:
- main

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.20.2

- name: Build
run: go build -v ./...

- name: Test
run: go test -v ./...
24 changes: 12 additions & 12 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
name: Release

on:
pull_request:
types:
- opened
- synchronize
branches:
- main
push:
tags:
- '*'

jobs:
build:
release:
name: Release
runs-on: ubuntu-latest

steps:
Expand All @@ -19,10 +17,12 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.20.2
go-version: 1.x # Specify the Go version

- name: Build
run: go build -v ./...
- name: Install goreleaser
run: go install github.com/goreleaser/goreleaser@latest

- name: Test
run: go test -v ./...
- name: Run goreleaser
run: |
export GITHUB_TOKEN=$RELEASE_GITHUB_TOKEN # Replace with your actual GitHub token
goreleaser release

0 comments on commit cc5c3e9

Please sign in to comment.