create-go-repositorylisted
Install: claude install-skill labspangaea/pangaealabs-claude-plugins-marketplace
# Skill: create-go-repository
Generate domain struct, port interface, repository adapter, and apperr error codes for one entity. Use this skill whenever someone wants to add a new entity's data layer to an existing Go project, create a repository for a domain model, generate a GORM or bun model and port interface, or scaffold the persistence layer without generating the full application. Trigger even if the user just says "I need a repo for X" or "create the domain and repository for Y".
## Parameters
| Parameter | Required | Default | Values |
|-----------|----------|---------|--------|
| `database` | no | `gorm-postgres` | `gorm-postgres` · `gorm-mysql` · `bun-postgres` · `bun-mysql` · `none` |
| `cache` | no | `none` | `none` · `redis` · `memory` · `couchbase` (forced to `none` when `database` is `bun-*`) |
**Match the project you are adding to.** Read an existing
`internal/adapter/outbound/repository/*.go` before asking — if it imports
`go-lib/db/bunrepo` the project is on bun, if `go-lib/db/repo` it is on GORM.
Mixing both in one service compiles, but leaves two repository idioms and both ORMs
in the binary, which is rarely what anyone wants. When the project already has a
repository, treat its flavour as the default and only ask if the user hints
otherwise.
## Prerequisites
| Item | Action if missing |
|------|-------------------|
| `go.mod` in working directory | Tell user this skill works inside an existing Go project; suggest `/create-go-app` to start fresh |
|