1.0.0 • Published 2 years ago
@fordi-org/get-options v1.0.0
getOptions
Quick library for grabbing command line options.
Usage
const { usage, read } = getOptions({
description: 'My CLI app',
A: {
description: 'Do it to them all',
trigger: () => ({ all: true }),
},
});
type MyCLIOptions = {
all?: boolean;
};
const { usage, read } = getOptions<MyCLIOptions>({
description: 'My CLI app',
A: {
description: 'Do it to them all',
trigger: () => ({ all: true }),
},
});
See included types for details on the spec.
1.0.0
2 years ago