Skip to content

Commit 312e24a

Browse files
committed
Initial commit
0 parents  commit 312e24a

71 files changed

Lines changed: 8534 additions & 0 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.codecov.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
coverage:
2+
status:
3+
project:
4+
default:
5+
target: 80%
6+
patch:
7+
default:
8+
target: 70%
9+
10+
ignore:
11+
- "cmd/github-ci"
12+
- "internal/cmd"
13+
- "internal/testutil"

.github/workflows/build.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches:
6+
- '**'
7+
pull_request:
8+
branches:
9+
- main
10+
11+
permissions:
12+
contents: read
13+
14+
jobs:
15+
build:
16+
runs-on: ubuntu-latest
17+
strategy:
18+
matrix:
19+
go-version: [1.24.x, 1.25.x]
20+
21+
steps:
22+
- name: Setup Go
23+
uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
24+
with:
25+
go-version: ${{ matrix.go-version }}
26+
27+
- name: Checkout code
28+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
29+
30+
- name: Run coverage
31+
run: go test -race ./... -coverprofile=coverage.out -covermode=atomic
32+
33+
- name: Upload coverage to Codecov
34+
if: ${{ matrix.go-version == '1.24.x' }}
35+
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
36+
with:
37+
token: ${{ secrets.CODECOV_TOKEN }}

.github/workflows/docs.yml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: Deploy Documentation
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
paths:
8+
- 'docs/**'
9+
- '.github/workflows/docs.yml'
10+
workflow_dispatch:
11+
12+
permissions:
13+
contents: read
14+
pages: write
15+
id-token: write
16+
17+
concurrency:
18+
group: "pages"
19+
cancel-in-progress: false
20+
21+
jobs:
22+
build:
23+
runs-on: ubuntu-latest
24+
steps:
25+
- name: Checkout
26+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
27+
28+
- name: Setup Pages
29+
uses: actions/configure-pages@983d7736d9b0ae728b81ab479565c72886d7745b # v5.0.0
30+
31+
- name: Build with Jekyll
32+
uses: actions/jekyll-build-pages@44a6e6beabd48582f863aeeb6cb2151cc1716697 # v1.0.13
33+
with:
34+
source: ./docs
35+
destination: ./_site
36+
37+
- name: Upload artifact
38+
uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0
39+
40+
deploy:
41+
environment:
42+
name: github-pages
43+
url: ${{ steps.deployment.outputs.page_url }}
44+
runs-on: ubuntu-latest
45+
needs: build
46+
steps:
47+
- name: Deploy to GitHub Pages
48+
id: deployment
49+
uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4.0.5
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: golangci-lint
2+
3+
on:
4+
push:
5+
branches:
6+
- '**'
7+
pull_request:
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
golangci:
14+
name: lint
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
20+
21+
- name: Get go version from go.mod
22+
run: |
23+
echo "GO_VERSION=$(grep '^go ' go.mod | cut -d " " -f 2)" >> $GITHUB_ENV
24+
25+
- name: Setup-go
26+
uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
27+
with:
28+
go-version: ${{ env.GO_VERSION }}
29+
30+
- name: Run golangci-lint
31+
uses: golangci/golangci-lint-action@1e7e51e771db61008b38414a730f564565cf7c20 # v9.2.0
32+
with:
33+
version: v2.7.2

.gitignore

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
.idea/
2+
.vscode/
3+
4+
coverage.out
5+
.github-ci.yaml
6+
/github-ci
7+
8+
# Jekyll (docs)
9+
docs/_site/
10+
docs/.jekyll-cache/
11+
docs/.jekyll-metadata
12+
docs/.sass-cache/
13+
docs/Gemfile.lock
14+
docs/vendor/

.golangci.yml

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
version: "2"
2+
run:
3+
timeout: 2m
4+
linters:
5+
default: none
6+
enable:
7+
- dupl
8+
- errcheck
9+
- errname
10+
- errorlint
11+
- funlen
12+
- goconst
13+
- gocritic
14+
- gocyclo
15+
- gosec
16+
- govet
17+
- ineffassign
18+
- lll
19+
- misspell
20+
- nolintlint
21+
- prealloc
22+
- reassign
23+
- revive
24+
- staticcheck
25+
- thelper
26+
- tparallel
27+
- unconvert
28+
- unparam
29+
- unused
30+
- whitespace
31+
settings:
32+
thelper:
33+
test:
34+
begin: false
35+
exclusions:
36+
generated: lax
37+
presets:
38+
- comments
39+
- common-false-positives
40+
- legacy
41+
- std-error-handling
42+
rules:
43+
- linters:
44+
- funlen
45+
- unparam
46+
path: _test\.go
47+
paths:
48+
- third_party$
49+
- builtin$
50+
- examples$
51+
formatters:
52+
enable:
53+
- gci
54+
- gofmt
55+
- goimports
56+
exclusions:
57+
generated: lax
58+
paths:
59+
- third_party$
60+
- builtin$
61+
- examples$

0 commit comments

Comments
 (0)