Skip to content

Commit 7a085af

Browse files
authored
feat: Initial Release
2 parents df36765 + 13f9d24 commit 7a085af

2 files changed

Lines changed: 114 additions & 0 deletions

File tree

.github/workflows/pr-check.yml

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
name: PR Checks
2+
3+
on:
4+
pull_request:
5+
6+
permissions:
7+
contents: read
8+
9+
jobs:
10+
Format:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v5
14+
15+
- name: Set up Go
16+
uses: actions/setup-go@v6
17+
with:
18+
go-version: '1.25.4'
19+
check-latest: true
20+
21+
- name: Format
22+
run: |
23+
# List files that would be reformatted
24+
unformatted=$(go fmt ./...)
25+
if [ -n "$unformatted" ]; then
26+
echo "The following files are not properly formatted:"
27+
echo "$unformatted"
28+
exit 1
29+
fi
30+
31+
Vet:
32+
runs-on: ubuntu-latest
33+
steps:
34+
- uses: actions/checkout@v5
35+
36+
- name: Set up Go
37+
uses: actions/setup-go@v6
38+
with:
39+
go-version: '1.25.4'
40+
check-latest: true
41+
42+
- name: Vet
43+
run: |
44+
result=$(go vet ./...)
45+
if [ -n "$result" ]; then
46+
echo "The following errors were reported by 'vet':"
47+
echo "$result"
48+
exit 1
49+
fi
50+
51+
Build:
52+
runs-on: ubuntu-latest
53+
steps:
54+
- uses: actions/checkout@v5
55+
56+
- name: Set up Go
57+
uses: actions/setup-go@v6
58+
with:
59+
go-version: '1.25.4'
60+
check-latest: true
61+
62+
- name: Build
63+
run: |
64+
result=$(go build ./...)
65+
if [ -n "$result" ]; then
66+
echo "The following errors were reported by 'build':"
67+
echo "$result"
68+
exit 1
69+
fi
70+
71+
Test:
72+
runs-on: ubuntu-latest
73+
steps:
74+
- uses: actions/checkout@v5
75+
76+
- name: Set up Go
77+
uses: actions/setup-go@v6
78+
with:
79+
go-version: '1.25.4'
80+
check-latest: true
81+
82+
- name: Build
83+
run: |
84+
go test -v ./...

.github/workflows/release.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
Release:
10+
runs-on: ubuntu-latest
11+
12+
permissions:
13+
contents: write
14+
15+
steps:
16+
- name: Checkout Code
17+
uses: actions/checkout@v5
18+
19+
- name: Bump version and push tag
20+
id: tag_version
21+
uses: mathieudutour/github-tag-action@v6.2
22+
with:
23+
github_token: ${{ secrets.GITHUB_TOKEN }}
24+
25+
- name: Publish Release
26+
uses: ncipollo/release-action@v1
27+
with:
28+
generateReleaseNotes: true
29+
tag: ${{ steps.tag_version.outputs.new_tag }}
30+
prerelease: true

0 commit comments

Comments
 (0)