MCPcopy Create free account
hub / github.com/chainloop-dev/chainloop / confirmationPrompt

Function confirmationPrompt

app/cli/cmd/casbackend.go:128–134  ·  view source on GitHub ↗

y/n confirmation prompt

(msg string)

Source from the content-addressed store, hash-verified

126
127// y/n confirmation prompt
128func confirmationPrompt(msg string) bool {
129 fmt.Printf("%s\nPlease confirm to continue y/N\n", msg)
130 var gotChallenge string
131 fmt.Scanln(&gotChallenge)
132
133 return gotChallenge == "y" || gotChallenge == "Y"
134}
135
136// parseMaxBytesOption validates and parses the --max-bytes flag value.
137// It stores the parsed result in parsedMaxBytes for child commands to use.

Callers 3

NewRootCmdFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected