Something went wrong. Try again.
[READ-ONLY] Mirror of https://github.com/Schniz/cmd-ts. 💻 A type-driven command line argument parser cmd-ts.now.sh
Something went wrong. Try again.
123456789101112131415161718192021222324import { binary, command, number, option, run } from "../src";
export function createCmd() { const cmd = command({ name: "test", args: { number: option({ long: "number", type: number, }), }, async handler(args) { console.log({ args }); }, });
return cmd;}
if (require.main === module) { const cmd = createCmd(); run(binary(cmd), process.argv);}