plugin

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrAuthSourceNotSet           = errors.New("either SSH key or netrc password is required")
	ErrPagesDirectoryNotExist     = errors.New("pages directory must exist")
	ErrPagesDirectoryNotValid     = errors.New("pages directory not valid")
	ErrPagesSourceNotSet          = errors.New("pages source directory must be set")
	ErrPagesActionNotExclusive    = errors.New("pages action is mutual exclusive")
	ErrActionUnknown              = errors.New("action not found")
	ErrGitCloneDestintionNotValid = errors.New("destination not valid")
)

Functions

This section is empty.

Types

type Netrc

type Netrc struct {
	Machine  string
	Login    string
	Password string
}

type Pages

type Pages struct {
	Directory string
	Exclude   cli.StringSlice
	Delete    bool
}

type Plugin

type Plugin struct {
	*wp.Plugin
	Settings *Settings
}

Plugin implements provide the plugin.

func New

func New(options wp.Options, settings *Settings) *Plugin

func (*Plugin) Execute

func (p *Plugin) Execute() error

Execute provides the implementation of the plugin.

func (*Plugin) Validate

func (p *Plugin) Validate() error

Validate handles the settings validation of the plugin.

type Settings

type Settings struct {
	Action cli.StringSlice
	SSHKey string

	Netrc Netrc
	Pages Pages
	Repo  git.Repository
}

Settings for the Plugin.

Jump to

Keyboard shortcuts

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