UNPKG

@sudoo/coco

Version:

:ocean: A simple command line tool framework

15 lines (14 loc) 331 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.isCallingRoot = (args) => { if (args.length === 0) { return true; } if (exports.isOption(args[0])) { return true; } return false; }; exports.isOption = (piece) => { return piece.substring(0, 1) === '-'; };