Skip to content

Commit

Permalink
feat: add semantic-release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
bartventer committed Jan 12, 2024
1 parent f4e6cd2 commit edc9587
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 39 deletions.
19 changes: 16 additions & 3 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,13 @@ jobs:
steps:

- name: Set up Go 1.21
uses: actions/setup-go@v1
uses: actions/setup-go@v5
with:
go-version: 1.21
id: go

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

- name: Get dependencies
run: |
Expand All @@ -52,4 +52,17 @@ jobs:

- uses: shogo82148/actions-goveralls@v1
with:
path-to-profile: ./profile.cov
path-to-profile: ./profile.cov

semantic-release:
needs: [build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run semantic-release
if: github.repository == 'bartventer/gorm-multitenancy' && github.event_name == 'push'
run: |
yarn global add semantic-release@17
semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
36 changes: 0 additions & 36 deletions .github/workflows/release.yml

This file was deleted.

16 changes: 16 additions & 0 deletions .releaserc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"debug": true,
"branches": [
"+([0-9])?(.{+([0-9]),x}).x",
"master",
{
"name": "beta",
"prerelease": true
}
],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/github"
]
}

0 comments on commit edc9587

Please sign in to comment.