Documentation ¶
Index ¶
- type Command
- func (c *Command) Complete(ctx context.Context, r *readline.Readline) []goprompt.Suggest
- func (c *Command) Description() string
- func (c *Command) Execute(ctx context.Context, r *readline.Readline) error
- func (c *Command) Help(ctx context.Context, r *readline.Readline) string
- func (c *Command) Name() string
- type CommandOption
- type Config
- type Option
- type Zip
- func (c *Zip) Config() Config
- func (c *Zip) Create(ctx context.Context, filename string) error
- func (c *Zip) CreateWithPassword(ctx context.Context, filename, credential string) error
- func (c *Zip) Extract(ctx context.Context, filename string) error
- func (c *Zip) ExtractWithPassword(ctx context.Context, filename, credential string) error
- func (c *Zip) GetCredentialPassword(ctx context.Context, name string) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Command ¶
type Command struct {
// contains filtered or unexported fields
}
func NewCommand ¶
func NewCommand(l log.Logger, zip *Zip, opts ...CommandOption) *Command
func (*Command) Description ¶
type CommandOption ¶
type CommandOption func(*Command)
type Config ¶
type Config struct {
Credentials map[string]onepassword.Secret `json:"credentials" yaml:"credentials"`
}
func (Config) Credential ¶
func (c Config) Credential(name string) (onepassword.Secret, bool)
func (Config) CredentialNames ¶
type Zip ¶
type Zip struct {
// contains filtered or unexported fields
}
func New ¶
func New(l log.Logger, op *onepassword.OnePassword, opts ...Option) (*Zip, error)
func (*Zip) CreateWithPassword ¶
func (*Zip) ExtractWithPassword ¶
Click to show internal directories.
Click to hide internal directories.