HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/SBogers10/shop.komma.nl/node_modules/@oclif/parser/lib/flags.js
"use strict";
// tslint:disable interface-over-type-literal
Object.defineProperty(exports, "__esModule", { value: true });
function build(defaults) {
    return (options = {}) => {
        return Object.assign({ parse: (i, _) => i }, defaults, options, { input: [], multiple: Boolean(options.multiple), type: 'option' });
    };
}
exports.build = build;
function boolean(options = {}) {
    return Object.assign({ parse: (b, _) => b }, options, { allowNo: Boolean(options.allowNo), type: 'boolean' });
}
exports.boolean = boolean;
exports.integer = build({
    parse: input => {
        if (!/^-?\d+$/.test(input))
            throw new Error(`Expected an integer but received: ${input}`);
        return parseInt(input, 10);
    },
});
function option(options) {
    return build(options)();
}
exports.option = option;
const stringFlag = build({});
exports.string = stringFlag;
exports.defaultFlags = {
    color: boolean({ allowNo: true }),
};