ci(release): setup release-please for release automation

This commit is contained in:
2024-03-25 02:03:35 +00:00
parent 563d447be9
commit 03bfa1a8f8
3 changed files with 27 additions and 0 deletions

3
.github/.release-please-manifest.json vendored Normal file
View File

@@ -0,0 +1,3 @@
{
".": "0.0.0"
}

14
.github/release-please-config.json vendored Normal file
View File

@@ -0,0 +1,14 @@
{
"initial-version": "0.0.1",
"packages": {
".": {
"release-type": "go",
"changelog-path": "CHANGELOG.md",
"bump-minor-pre-major": true,
"bump-patch-for-minor-pre-major": true,
"draft": false,
"prerelease": false
}
},
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json"
}

View File

@@ -67,3 +67,13 @@ jobs:
go-version: ${{ matrix.go_version }}
- name: Run tests
run: go test -v -count=1 -race ./...
release-please:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
outputs:
release_created: ${{ steps.release-please.outputs.release_created }}
version: ${{ steps.release-please.outputs.version }}
steps:
- uses: jimeh/release-please-manifest-action@v1
id: release-please