installer

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DefaultInstaller

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

DefaultInstaller implements Installer using go install.

func NewDefaultInstaller

func NewDefaultInstaller() *DefaultInstaller

NewDefaultInstaller creates a new DefaultInstaller.

func NewDefaultInstallerWithGOPROXY added in v0.1.4

func NewDefaultInstallerWithGOPROXY(goproxy string) *DefaultInstaller

NewDefaultInstallerWithGOPROXY creates a new DefaultInstaller that overrides the GOPROXY environment variable with the provided value when it is non-empty.

func (*DefaultInstaller) Install

func (d *DefaultInstaller) Install(modulePath string, version string) (string, error)

Install runs "go install {modulePath}@{version}" and returns the combined output.

type Installer

type Installer interface {
	Install(modulePath string, version string) (string, error)
}

Installer defines the interface for installing Go modules.

Jump to

Keyboard shortcuts

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