login

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Mar 23, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewLoginCmd

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

NewLoginCmd returns a new instance of the login command.

func RunOAuthFlow

func RunOAuthFlow(opts *LoginOptions, signup bool) error

RunOAuthFlow runs the full browser-based OAuth + profile setup flow. If signup is true, the browser opens to the sign-up page instead of sign-in.

Types

type LoginOptions

type LoginOptions struct {
	IO     *iostreams.IOStreams
	Config config.IConfig

	AppName     string
	ProfileName string
	Default     bool

	// NoBrowser disables automatic browser opening; the authorize URL is
	// printed instead. The CLI still starts a local callback server and
	// waits for the redirect.
	NoBrowser bool

	NewDashboardClient func(clientID string) *dashboard.Client
}

LoginOptions holds all options for the login command.

Jump to

Keyboard shortcuts

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