cmdauth

package
v1.0.47993 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewAuthCmd

func NewAuthCmd() *cobra.Command

NewAuthCmd returns the "circleci auth" command group.

Types

type SignupOutcome

type SignupOutcome string

SignupOutcome describes what SignupIfNeeded did.

const (
	SignupAlreadyAuthenticated SignupOutcome = "already_authenticated"
	SignupCompleted            SignupOutcome = "completed"
)

Possible SignupOutcome values.

type SignupResult

type SignupResult struct {
	Outcome SignupOutcome
}

SignupResult is returned by SignupIfNeeded so callers can distinguish between "already signed in" and "signup just completed."

func SignupIfNeeded

func SignupIfNeeded(ctx context.Context, noBrowser, secureStorage bool, configPath string) (SignupResult, error)

SignupIfNeeded is the idempotent variant of signup used by orchestrators like `circleci onboard`. If a valid token already exists, it prints a confirmation and returns the AlreadyAuthenticated outcome. Otherwise it runs the standard signup flow and returns the Completed outcome.

Jump to

Keyboard shortcuts

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