Gokart banner
dotcommander dotcommander

Gokart

DevOps community

Description

Modular Go infrastructure toolkit and CLI generator with safe defaults and user-owned generated code.

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

GoKart

![GoKart logo](logo.png)

GoKart is a modular Go toolkit for recurring infrastructure setup, safe defaults, and user-owned generated code. Its enforceable boundary is defined in [PHILOSOPHY.md](PHILOSOPHY.md).

Install the tagged CLI and scaffold a project:

go install github.com/dotcommander/gokart/cmd/gokart@v0.13.0
gokart new tvguide --example
cd tvguide
go run . greet --name World
go build -o tvguide .

Continue with the [TV-guide tutorial](docs/getting-started.md) to turn the generated command into a tested, filterable program listing.

Packages

  • gokart: typed configuration, platform config directories, and JSON state persistence.
  • gokart/cli: Cobra application construction for established ecosystem-style consumers plus process-stream presentation helpers. Focused generated CLIs use Kong directly.
  • gokart/web: chi router/server construction, JSON responses, bounded binding, and validation.
  • gokart/postgres: pgx pool setup and transaction helpers.
  • gokart/sqlite: zero-CGO SQLite setup and operations.
  • gokart/migrate: goose migrations.
  • gokart/cache: Redis construction, prefixes, JSON operations, and Remember.
  • gokart/logger: log/slog setup.

All modules isolate their dependencies. Constructors expose real upstream types or an explicit `Client` escape hatch.

Generator

`gokart new` creates ordinary Go code. Plain, example, local, and global CLIs default to a flat `main.go`; selecting an integration chooses the structured layout automatically. Use `--structured` when you want the multi-package layout without an integration.

gokart new mycli
gokart new mycli --structured
gokart new mycli --structured --global
gokart new service --db postgres --ai --redis
gokart add sqlite --dry-run

Flat scaffolds are unmanaged and manifest-free. Structured scaffolds are managed by default and support later integration updates through `gokart add`.

Dependencies are pinned for deterministic generation. PostgreSQ