cli

package
v1.5.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 18, 2026 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package cli holds shared helpers for the warden CLI binaries.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MaybeMigrate

func MaybeMigrate(ctx context.Context, s store.Store, skip bool) error

MaybeMigrate runs the store's auto-migrations unless skip is true.

func OpenStore

func OpenStore(ctx context.Context, dsn string) (store.Store, func() error, error)

OpenStore opens a warden Store from a DSN string.

Supported DSN forms:

memory:                              — in-memory (testing only; data is lost on exit)
sqlite:<path>                        — SQLite file
postgres://user:pass@host:port/db    — Postgres connection URL
postgresql://user:pass@host:port/db  — same as above

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL