You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gpt-pilot/src/cli/command-options.ts

9 lines
294 B
TypeScript

import type { Command } from "commander";
export function hasExplicitOptions(command: Command, names: readonly string[]): boolean {
if (typeof command.getOptionValueSource !== "function") {
return false;
}
return names.some((name) => command.getOptionValueSource(name) === "cli");
}