cli

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2026 License: MIT Imports: 28 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Execute

func Execute() error

func SetVersionInfo

func SetVersionInfo(version, buildDate, gitCommit string)

SetVersionInfo records the build stamp from main's ldflags. Empty values keep the buildinfo fallback.

Types

type BranchSafetyChecker

type BranchSafetyChecker struct {
	// contains filtered or unexported fields
}

BranchSafetyChecker checks if it's safe to squash on the current branch

func NewBranchSafetyChecker

func NewBranchSafetyChecker() *BranchSafetyChecker

NewBranchSafetyChecker creates a new branch safety checker

func (*BranchSafetyChecker) CheckBranchSafety

func (bsc *BranchSafetyChecker) CheckBranchSafety(branchCheck, force bool) (bool, error)

CheckBranchSafety checks if it's safe to squash and prompts user if needed Returns true if safe to proceed, false otherwise

func (*BranchSafetyChecker) FormatBranchWarning

func (bsc *BranchSafetyChecker) FormatBranchWarning(currentBranch string) string

FormatBranchWarning formats a warning message about branch safety

func (*BranchSafetyChecker) GetCurrentBranch

func (bsc *BranchSafetyChecker) GetCurrentBranch() (string, error)

GetCurrentBranch gets the current git branch name

func (*BranchSafetyChecker) IsProtectedBranch

func (bsc *BranchSafetyChecker) IsProtectedBranch(branch string) bool

IsProtectedBranch checks if the branch is a protected branch

type MigrationWithContent

type MigrationWithContent struct {
	*types.Migration
	Content  string
	FullPath string
}

MigrationWithContent contains both parsed migration and original file content

Jump to

Keyboard shortcuts

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