alias

package
v0.0.0-...-b2cb311 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AliasCmd = &cobra.Command{
	Use:   "alias",
	Short: "Use server aliases",
	Long:  "Use server aliases to connect to servers",
}

AliasCmd represents the base alias command

View Source
var AliasFilePath string

Functions

This section is empty.

Types

type Alias

type Alias struct {
	Description string `yaml:"description"`
	Value       string `yaml:"value"`
}

type Aliases

type Aliases struct {
	Aliases map[string]Alias `yaml:"aliases"`
}

func (*Aliases) Add

func (aliases *Aliases) Add(name, value, description string)

func (*Aliases) ReadFromFile

func (aliases *Aliases) ReadFromFile() error

func (*Aliases) Remove

func (aliases *Aliases) Remove(name string)

func (*Aliases) RemoveAll

func (aliases *Aliases) RemoveAll()

func (*Aliases) Update

func (aliases *Aliases) Update(name, fieldToUpdate, fieldNewValue string) bool

func (*Aliases) WriteToFile

func (aliases *Aliases) WriteToFile() error

Jump to

Keyboard shortcuts

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