2026-01-08 04:05:10 +01:00
|
|
|
import type { Command } from "commander";
|
|
|
|
|
|
2026-01-14 14:31:43 +00:00
|
|
|
export function hasExplicitOptions(command: Command, names: readonly string[]): boolean {
|
2026-01-08 04:05:10 +01:00
|
|
|
if (typeof command.getOptionValueSource !== "function") {
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
return names.some((name) => command.getOptionValueSource(name) === "cli");
|
|
|
|
|
}
|