migrations

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 4, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package migrations runs one-shot settings upgrades on startup. Each migration has a stable ID; completed IDs are written to ~/.claude/settings.json under "completedMigrations" (matching the TS implementation) so they never re-run across restarts.

Mirrors src/migrations/ in the CC TypeScript source.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(claudeDir string)

Run executes all pending migrations for claudeDir. Already-completed migrations are skipped. Errors from individual migrations are logged but do not abort subsequent ones.

Types

type Migration

type Migration struct {
	ID  string
	Run func(claudeDir string) error
}

Migration is a one-shot upgrade to run against settings.json.

Jump to

Keyboard shortcuts

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