credentials

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package credentials provide credentials from user input.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithCredentialsAtLast

func WithCredentialsAtLast(options ...Option) n26api.Option

WithCredentialsAtLast sets CredentialsProvider as a n26api.CredentialsProvider.

Types

type Option

type Option func(p *Prompt)

Option configures Prompt.

func WithLogger

func WithLogger(logger ctxd.Logger) Option

WithLogger sets logger for Prompt.

func WithStdio

func WithStdio(stdio terminal.Stdio) Option

WithStdio sets stdio for the prompts.

func WithStdioProvider added in v0.1.5

func WithStdioProvider(stdio cobra.StdioProvider) Option

WithStdioProvider sets stdio for the prompts.

type Prompt

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

Prompt provides the credentials using cli prompt.

func New

func New(options ...Option) *Prompt

New initiates a new CredentialsProvider.

func (*Prompt) Password

func (p *Prompt) Password() string

Password provides a password via cli prompt.

func (*Prompt) Username

func (p *Prompt) Username() string

Username provides a username via cli prompt.

Jump to

Keyboard shortcuts

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