MCPcopy Index your code
hub / github.com/Effect-TS/effect / makeChoice

Function makeChoice

packages/cli/src/internal/commandDescriptor.ts:937–940  ·  view source on GitHub ↗
(title: string, index: number)

Source from the content-addressed store, hash-verified

935 const description = InternalHelpDoc.p("Select which command you would like to execute")
936 const message = InternalHelpDoc.toAnsiText(description).trimEnd()
937 const makeChoice = (title: string, index: number) => ({
938 title,
939 value: [title, index] as const
940 })
941 const choices = pipe(
942 getSubcommandsInternal(self),
943 Arr.map(([name], index) => makeChoice(name, index))

Callers 1

loopFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected