extension

package
v2.49.2 Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: MIT Imports: 35 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInitialCommitFailed = errors.New("initial commit failed")

ErrInitialCommitFailed indicates the initial commit when making a new extension failed.

Functions

func NewCmdExtension

func NewCmdExtension(f *cmdutil.Factory) *cobra.Command

Types

type Extension

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

func (*Extension) CurrentVersion added in v2.6.0

func (e *Extension) CurrentVersion() string

func (*Extension) IsBinary added in v2.2.0

func (e *Extension) IsBinary() bool

func (*Extension) IsLocal

func (e *Extension) IsLocal() bool

func (*Extension) IsPinned added in v2.7.0

func (e *Extension) IsPinned() bool

func (*Extension) LatestVersion added in v2.31.0

func (e *Extension) LatestVersion() string

func (*Extension) Name

func (e *Extension) Name() string

func (*Extension) Owner added in v2.38.0

func (e *Extension) Owner() string

func (*Extension) Path

func (e *Extension) Path() string

func (*Extension) URL

func (e *Extension) URL() string

func (*Extension) UpdateAvailable

func (e *Extension) UpdateAvailable() bool

type ExtensionKind

type ExtensionKind int
const (
	GitKind ExtensionKind = iota
	BinaryKind
	LocalKind
)

type Manager

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

func NewManager

func NewManager(ios *iostreams.IOStreams, gc *git.Client) *Manager

func (*Manager) Create

func (m *Manager) Create(name string, tmplType extensions.ExtTemplateType) error

func (*Manager) Dispatch

func (m *Manager) Dispatch(args []string, stdin io.Reader, stdout, stderr io.Writer) (bool, error)

func (*Manager) EnableDryRunMode added in v2.8.0

func (m *Manager) EnableDryRunMode()

func (*Manager) Install

func (m *Manager) Install(repo ghrepo.Interface, target string) error

Install installs an extension from repo, and pins to commitish if provided

func (*Manager) InstallLocal

func (m *Manager) InstallLocal(dir string) error

func (*Manager) List

func (m *Manager) List() []extensions.Extension

func (*Manager) Remove

func (m *Manager) Remove(name string) error

func (*Manager) SetClient

func (m *Manager) SetClient(client *http.Client)

func (*Manager) SetConfig

func (m *Manager) SetConfig(cfg gh.Config)

func (*Manager) Upgrade

func (m *Manager) Upgrade(name string, force bool) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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