migratesvc

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2026 License: MIT Imports: 7 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package migratesvc moves a legacy home (~/.config/sshmgr from before the rename, or the older ~/.sshmgr) to the OS-standard home, ported from facade.migrate_home. It is the guided path for when both already exist (auto-migration can't handle that); doctor flags such a stranded legacy home.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Result

type Result struct {
	Moved   bool
	Legacy  string
	Home    string
	Backup  string
	Message string
}

Result is the outcome of a migrate run.

func Migrate

func Migrate(p paths.Paths, force bool, stamp string) (Result, error)

Migrate moves the legacy home into the standard home. If the standard home is absent, the legacy is moved in. If both exist, it refuses unless force - with force the current home is backed up aside (using stamp) and replaced with the legacy one. Mirrors facade.migrate_home (sans the advisory lock).

func (Result) Format

func (r Result) Format() string

Format renders the message.

Jump to

Keyboard shortcuts

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