MCPcopy Create free account
hub / github.com/SmartThingsCommunity/smartthings-cli / prompt

Function prompt

src/lib/user-query.ts:112–118  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

110 // Using `inquirer`'s `number` function instead of `input` would be nice but it doesn't allow
111 // us to accept `?` for help text.
112 const prompt = async (): Promise<string | undefined> => await input({
113 message: options.helpText ? `${message} (? for help)` : message,
114 transformer: displayNoneForEmpty,
115 validate,
116 default: (typeof options.default === 'function' ? options.default() : options.default)?.toString(),
117 required: options.required,
118 })
119
120 let entered = await prompt()
121 while (options.helpText && entered === '?') {

Callers 2

internalIntegerInputFunction · 0.85
internalNumberInputFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected