Compare commits
14 Commits
v0.1.0
...
379a820a70
| Author | SHA1 | Date | |
|---|---|---|---|
| 379a820a70 | |||
|
2025050f72
|
|||
| 2341ab5a10 | |||
| f01cfc08af | |||
| 082a672a34 | |||
| 3fee690ea3 | |||
| 3b8d953aa4 | |||
| 37740b6bc2 | |||
| 731464b9a9 | |||
|
f1a91fdd40
|
|||
| 76097b8ff2 | |||
| 69786d9b8d | |||
| 661f95fb5f | |||
| 7b740036d0 |
@@ -9,7 +9,8 @@
|
||||
"Bash(pre-commit run:*)",
|
||||
"Bash(go build:*)",
|
||||
"Bash(go test:*)",
|
||||
"Bash(but status)"
|
||||
"Bash(but status)",
|
||||
"Bash(but --help:*)"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ jobs:
|
||||
- uses: actions/setup-go@v6
|
||||
with:
|
||||
go-version: 'stable'
|
||||
- uses: actions/setup-python@v5
|
||||
- uses: actions/setup-python@v6
|
||||
with:
|
||||
python-version: '3.14'
|
||||
- name: Install goimports
|
||||
|
||||
@@ -1,38 +0,0 @@
|
||||
include:
|
||||
- template: 'Workflows/MergeRequest-Pipelines.gitlab-ci.yml'
|
||||
- project: unboundsoftware/ci-templates
|
||||
file: Defaults.gitlab-ci.yml
|
||||
- project: unboundsoftware/ci-templates
|
||||
file: Release.gitlab-ci.yml
|
||||
- project: unboundsoftware/ci-templates
|
||||
file: Pre-Commit-Go.gitlab-ci.yml
|
||||
|
||||
image: amd64/golang:1.25.5@sha256:ad03ba93327b8a6143b49373790b5d92c28067bdb814418509466122ee9c9e63
|
||||
|
||||
stages:
|
||||
- deps
|
||||
- test
|
||||
|
||||
deps:
|
||||
stage: deps
|
||||
script:
|
||||
- go mod download
|
||||
|
||||
test:
|
||||
stage: test
|
||||
dependencies:
|
||||
- deps
|
||||
script:
|
||||
- CGO_ENABLED=1 go test -mod=readonly -race -coverprofile=coverage.txt -covermode=atomic -coverpkg=$(go list ./... | tr '\n' , | sed 's/,$//') ./...
|
||||
- go tool cover -html=coverage.txt -o coverage.html
|
||||
- go tool cover -func=coverage.txt
|
||||
- curl -Os https://uploader.codecov.io/latest/linux/codecov
|
||||
- chmod +x codecov
|
||||
- ./codecov -t ${CODECOV_TOKEN} -R $CI_PROJECT_DIR -C $CI_COMMIT_SHA -r $CI_PROJECT_PATH
|
||||
|
||||
vulnerabilities:
|
||||
stage: test
|
||||
image: amd64/golang:1.25.5@sha256:ad03ba93327b8a6143b49373790b5d92c28067bdb814418509466122ee9c9e63
|
||||
script:
|
||||
- go install golang.org/x/vuln/cmd/govulncheck@latest
|
||||
- govulncheck ./...
|
||||
@@ -11,7 +11,7 @@ repos:
|
||||
- --allow-multiple-documents
|
||||
- id: check-added-large-files
|
||||
- repo: https://github.com/alessandrojcm/commitlint-pre-commit-hook
|
||||
rev: v9.23.0
|
||||
rev: v9.24.0
|
||||
hooks:
|
||||
- id: commitlint
|
||||
stages: [ commit-msg ]
|
||||
@@ -23,7 +23,7 @@ repos:
|
||||
- id: go-imports
|
||||
args:
|
||||
- -local
|
||||
- git.unbound.se/unboundsoftware/shiny/presenter
|
||||
- gitea.unbound.se/unboundsoftware/dbsetup
|
||||
- repo: https://github.com/lietu/go-pre-commit
|
||||
rev: v1.0.0
|
||||
hooks:
|
||||
|
||||
@@ -2,6 +2,13 @@
|
||||
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
## [0.1.1] - 2026-01-09
|
||||
|
||||
### ⚙️ Miscellaneous Tasks
|
||||
|
||||
- *(deps)* Update actions/setup-python action to v6
|
||||
- Migrate module path to gitea.unbound.se
|
||||
|
||||
## [0.1.0] - 2026-01-09
|
||||
|
||||
### 🚀 Features
|
||||
|
||||
@@ -6,7 +6,7 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
|
||||
|
||||
**dbsetup** is a Go helper module for database connection pool initialization with OpenTelemetry (OTEL) instrumentation. It wraps database connections with OTEL to automatically add SQL queries to tracing spans.
|
||||
|
||||
- Module path: `git.unbound.se/unboundsoftware/dbsetup`
|
||||
- Module path: `gitea.unbound.se/unboundsoftware/dbsetup`
|
||||
- Primary dependencies: sqlx, goose (migrations), otelsqlx (OTEL wrapper)
|
||||
|
||||
## Common Commands
|
||||
@@ -44,7 +44,7 @@ Single-package module with one source file (`database.go`):
|
||||
Pre-commit hooks enforce:
|
||||
- gofumpt formatting (stricter than gofmt)
|
||||
- golangci-lint
|
||||
- go-imports with local path `git.unbound.se/unboundsoftware/`
|
||||
- go-imports with local path `gitea.unbound.se/unboundsoftware/`
|
||||
- Conventional commits format (feat:, fix:, chore:, etc.)
|
||||
- Gitleaks for secret detection
|
||||
|
||||
|
||||
Reference in New Issue
Block a user