Documentation ¶
Overview ¶
Package module package
Index ¶
- Variables
- func NewCharmSelect(title string, versions []string) *tea.Program
- func NewCharmSpinner(loadingMsg string) *tea.Program
- type Golang
- func (g *Golang) Configure() error
- func (g *Golang) GetGlobalVersion() (string, error)
- func (g *Golang) GetInstalledVersions() ([]string, error)
- func (g *Golang) GetLocalVersion(dir string) (string, error)
- func (g *Golang) GetVersions() []string
- func (g *Golang) Install(version string) error
- func (g *Golang) Rehash() error
- func (g *Golang) SetGlobalVersion(version string) error
- func (g *Golang) SetLocalVersion(version string) error
- func (g *Golang) SetVersion(path, version string) error
- func (g *Golang) Uninstall(version string) error
- func (g *Golang) ValidateInstalledVersion(version string) (bool, error)
- func (g *Golang) ValidateVersion(version string) bool
Constants ¶
This section is empty.
Variables ¶
var GolangReleases = []string{}/* 273 elements not displayed */
GolangReleases a list of golang releases
var SelectedValue string
SelectedValue the list selected value
Functions ¶
func NewCharmSelect ¶
NewCharmSelect Creates a new instance of tea.Program
func NewCharmSpinner ¶
NewCharmSpinner Creates a new instance of tea.Program
Types ¶
type Golang ¶
type Golang struct { RootPath string EnvironmentDir string VersionsDir string ShimsDir string VersionFile string FileSystem *service.FileSystem Installer *service.Installer }
Golang type
func NewGolangEnvironment ¶
NewGolangEnvironment creates a new instance
func (*Golang) GetGlobalVersion ¶
GetGlobalVersion returns the global golang version
func (*Golang) GetInstalledVersions ¶
GetInstalledVersions returns a list of installed versions
func (*Golang) GetLocalVersion ¶
GetLocalVersion returns the local golang version
func (*Golang) GetVersions ¶
GetVersions returns a list of all available versions
func (*Golang) Rehash ¶
Rehash gets a list of binaries under a certain go bin directory and create shim for them
func (*Golang) SetGlobalVersion ¶
SetGlobalVersion sets the global golang version
func (*Golang) SetLocalVersion ¶
SetLocalVersion sets the local golang version
func (*Golang) SetVersion ¶
SetVersion sets the local or global golang version
func (*Golang) ValidateInstalledVersion ¶
ValidateInstalledVersion validates if an installed version is valid
func (*Golang) ValidateVersion ¶
ValidateVersion validates if a version is valid