compat

package
v1.1.6 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package compat detects old-style SSU flags (from the bash version) and prints friendly migration hints pointing users to the new subcommand syntax.

Index

Constants

This section is empty.

Variables

View Source
var OldFlagHints = map[string]string{
	"--status":   "ssu status",
	"--push":     "ssu push",
	"--rollback": "ssu rollback",
	"--auto":     "ssu update --auto  (or: ssu push --auto)",
	"--dry-run":  "ssu update --dry-run  (or: ssu status)",
}

OldFlagHints maps deprecated top-level flags to their new subcommand equivalents.

Functions

func CheckOldFlags

func CheckOldFlags(args []string, w io.Writer) bool

CheckOldFlags inspects the first argument after the binary name. If it matches a deprecated flag, a migration hint is printed to w and the function returns true. Only args[1] is checked so that valid subcommand flags (e.g. "ssu update --dry-run") are not falsely flagged.

Types

This section is empty.

Jump to

Keyboard shortcuts

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