piral-cli 0.14.28-beta.4360 → 0.14.28-beta.4363

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1462,7 +1462,7 @@ var Observable_1 = __webpack_require__(780);
1462
1462
  exports.Observable = Observable_1.Observable;
1463
1463
  var ConnectableObservable_1 = __webpack_require__(962);
1464
1464
  exports.ConnectableObservable = ConnectableObservable_1.ConnectableObservable;
1465
- var groupBy_1 = __webpack_require__(195);
1465
+ var groupBy_1 = __webpack_require__(665);
1466
1466
  exports.GroupedObservable = groupBy_1.GroupedObservable;
1467
1467
  var observable_1 = __webpack_require__(620);
1468
1468
  exports.observable = observable_1.observable;
@@ -19992,289 +19992,7 @@ module.exports = Separator;
19992
19992
 
19993
19993
 
19994
19994
  /***/ }),
19995
- /* 82 */
19996
- /***/ (function(module, __unusedexports, __webpack_require__) {
19997
-
19998
- "use strict";
19999
-
20000
- /**
20001
- * `rawlist` type prompt
20002
- */
20003
-
20004
- var _ = __webpack_require__(53);
20005
- var chalk = __webpack_require__(393);
20006
- var { map, takeUntil } = __webpack_require__(605);
20007
- var Base = __webpack_require__(966);
20008
- var Separator = __webpack_require__(81);
20009
- var observe = __webpack_require__(595);
20010
- var Paginator = __webpack_require__(784);
20011
-
20012
- class ExpandPrompt extends Base {
20013
- constructor(questions, rl, answers) {
20014
- super(questions, rl, answers);
20015
-
20016
- if (!this.opt.choices) {
20017
- this.throwParamError('choices');
20018
- }
20019
-
20020
- this.validateChoices(this.opt.choices);
20021
-
20022
- // Add the default `help` (/expand) option
20023
- this.opt.choices.push({
20024
- key: 'h',
20025
- name: 'Help, list all options',
20026
- value: 'help'
20027
- });
20028
-
20029
- this.opt.validate = choice => {
20030
- if (choice == null) {
20031
- return 'Please enter a valid command';
20032
- }
20033
-
20034
- return choice !== 'help';
20035
- };
20036
-
20037
- // Setup the default string (capitalize the default key)
20038
- this.opt.default = this.generateChoicesString(this.opt.choices, this.opt.default);
20039
-
20040
- this.paginator = new Paginator(this.screen);
20041
- }
20042
-
20043
- /**
20044
- * Start the Inquiry session
20045
- * @param {Function} cb Callback when prompt is done
20046
- * @return {this}
20047
- */
20048
-
20049
- _run(cb) {
20050
- this.done = cb;
20051
-
20052
- // Save user answer and update prompt to show selected option.
20053
- var events = observe(this.rl);
20054
- var validation = this.handleSubmitEvents(
20055
- events.line.pipe(map(this.getCurrentValue.bind(this)))
20056
- );
20057
- validation.success.forEach(this.onSubmit.bind(this));
20058
- validation.error.forEach(this.onError.bind(this));
20059
- this.keypressObs = events.keypress
20060
- .pipe(takeUntil(validation.success))
20061
- .forEach(this.onKeypress.bind(this));
20062
-
20063
- // Init the prompt
20064
- this.render();
20065
-
20066
- return this;
20067
- }
20068
-
20069
- /**
20070
- * Render the prompt to screen
20071
- * @return {ExpandPrompt} self
20072
- */
20073
-
20074
- render(error, hint) {
20075
- var message = this.getQuestion();
20076
- var bottomContent = '';
20077
-
20078
- if (this.status === 'answered') {
20079
- message += chalk.cyan(this.answer);
20080
- } else if (this.status === 'expanded') {
20081
- var choicesStr = renderChoices(this.opt.choices, this.selectedKey);
20082
- message += this.paginator.paginate(choicesStr, this.selectedKey, this.opt.pageSize);
20083
- message += '\n Answer: ';
20084
- }
20085
-
20086
- message += this.rl.line;
20087
-
20088
- if (error) {
20089
- bottomContent = chalk.red('>> ') + error;
20090
- }
20091
-
20092
- if (hint) {
20093
- bottomContent = chalk.cyan('>> ') + hint;
20094
- }
20095
-
20096
- this.screen.render(message, bottomContent);
20097
- }
20098
-
20099
- getCurrentValue(input) {
20100
- if (!input) {
20101
- input = this.rawDefault;
20102
- }
20103
-
20104
- var selected = this.opt.choices.where({ key: input.toLowerCase().trim() })[0];
20105
- if (!selected) {
20106
- return null;
20107
- }
20108
-
20109
- return selected.value;
20110
- }
20111
-
20112
- /**
20113
- * Generate the prompt choices string
20114
- * @return {String} Choices string
20115
- */
20116
-
20117
- getChoices() {
20118
- var output = '';
20119
-
20120
- this.opt.choices.forEach(choice => {
20121
- output += '\n ';
20122
-
20123
- if (choice.type === 'separator') {
20124
- output += ' ' + choice;
20125
- return;
20126
- }
20127
-
20128
- var choiceStr = choice.key + ') ' + choice.name;
20129
- if (this.selectedKey === choice.key) {
20130
- choiceStr = chalk.cyan(choiceStr);
20131
- }
20132
-
20133
- output += choiceStr;
20134
- });
20135
-
20136
- return output;
20137
- }
20138
-
20139
- onError(state) {
20140
- if (state.value === 'help') {
20141
- this.selectedKey = '';
20142
- this.status = 'expanded';
20143
- this.render();
20144
- return;
20145
- }
20146
-
20147
- this.render(state.isValid);
20148
- }
20149
-
20150
- /**
20151
- * When user press `enter` key
20152
- */
20153
-
20154
- onSubmit(state) {
20155
- this.status = 'answered';
20156
- var choice = this.opt.choices.where({ value: state.value })[0];
20157
- this.answer = choice.short || choice.name;
20158
-
20159
- // Re-render prompt
20160
- this.render();
20161
- this.screen.done();
20162
- this.done(state.value);
20163
- }
20164
-
20165
- /**
20166
- * When user press a key
20167
- */
20168
-
20169
- onKeypress() {
20170
- this.selectedKey = this.rl.line.toLowerCase();
20171
- var selected = this.opt.choices.where({ key: this.selectedKey })[0];
20172
- if (this.status === 'expanded') {
20173
- this.render();
20174
- } else {
20175
- this.render(null, selected ? selected.name : null);
20176
- }
20177
- }
20178
-
20179
- /**
20180
- * Validate the choices
20181
- * @param {Array} choices
20182
- */
20183
-
20184
- validateChoices(choices) {
20185
- var formatError;
20186
- var errors = [];
20187
- var keymap = {};
20188
- choices.filter(Separator.exclude).forEach(choice => {
20189
- if (!choice.key || choice.key.length !== 1) {
20190
- formatError = true;
20191
- }
20192
-
20193
- if (keymap[choice.key]) {
20194
- errors.push(choice.key);
20195
- }
20196
-
20197
- keymap[choice.key] = true;
20198
- choice.key = String(choice.key).toLowerCase();
20199
- });
20200
-
20201
- if (formatError) {
20202
- throw new Error(
20203
- 'Format error: `key` param must be a single letter and is required.'
20204
- );
20205
- }
20206
-
20207
- if (keymap.h) {
20208
- throw new Error(
20209
- 'Reserved key error: `key` param cannot be `h` - this value is reserved.'
20210
- );
20211
- }
20212
-
20213
- if (errors.length) {
20214
- throw new Error(
20215
- 'Duplicate key error: `key` param must be unique. Duplicates: ' +
20216
- _.uniq(errors).join(', ')
20217
- );
20218
- }
20219
- }
20220
-
20221
- /**
20222
- * Generate a string out of the choices keys
20223
- * @param {Array} choices
20224
- * @param {Number|String} default - the choice index or name to capitalize
20225
- * @return {String} The rendered choices key string
20226
- */
20227
- generateChoicesString(choices, defaultChoice) {
20228
- var defIndex = choices.realLength - 1;
20229
- if (_.isNumber(defaultChoice) && this.opt.choices.getChoice(defaultChoice)) {
20230
- defIndex = defaultChoice;
20231
- } else if (_.isString(defaultChoice)) {
20232
- let index = _.findIndex(
20233
- choices.realChoices,
20234
- ({ value }) => value === defaultChoice
20235
- );
20236
- defIndex = index === -1 ? defIndex : index;
20237
- }
20238
-
20239
- var defStr = this.opt.choices.pluck('key');
20240
- this.rawDefault = defStr[defIndex];
20241
- defStr[defIndex] = String(defStr[defIndex]).toUpperCase();
20242
- return defStr.join('');
20243
- }
20244
- }
20245
-
20246
- /**
20247
- * Function for rendering checkbox choices
20248
- * @param {String} pointer Selected key
20249
- * @return {String} Rendered content
20250
- */
20251
-
20252
- function renderChoices(choices, pointer) {
20253
- var output = '';
20254
-
20255
- choices.forEach(choice => {
20256
- output += '\n ';
20257
-
20258
- if (choice.type === 'separator') {
20259
- output += ' ' + choice;
20260
- return;
20261
- }
20262
-
20263
- var choiceStr = choice.key + ') ' + choice.name;
20264
- if (pointer === choice.key) {
20265
- choiceStr = chalk.cyan(choiceStr);
20266
- }
20267
-
20268
- output += choiceStr;
20269
- });
20270
-
20271
- return output;
20272
- }
20273
-
20274
- module.exports = ExpandPrompt;
20275
-
20276
-
20277
- /***/ }),
19995
+ /* 82 */,
20278
19996
  /* 83 */,
20279
19997
  /* 84 */
20280
19998
  /***/ (function(module, __unusedexports, __webpack_require__) {
@@ -20620,140 +20338,9 @@ module.exports = safer
20620
20338
  /***/ }),
20621
20339
  /* 93 */,
20622
20340
  /* 94 */
20623
- /***/ (function(module, __unusedexports, __webpack_require__) {
20624
-
20625
- "use strict";
20626
-
20627
- const os = __webpack_require__(87);
20628
- const hasFlag = __webpack_require__(601);
20629
-
20630
- const env = process.env;
20631
-
20632
- let forceColor;
20633
- if (hasFlag('no-color') ||
20634
- hasFlag('no-colors') ||
20635
- hasFlag('color=false')) {
20636
- forceColor = false;
20637
- } else if (hasFlag('color') ||
20638
- hasFlag('colors') ||
20639
- hasFlag('color=true') ||
20640
- hasFlag('color=always')) {
20641
- forceColor = true;
20642
- }
20643
- if ('FORCE_COLOR' in env) {
20644
- forceColor = env.FORCE_COLOR.length === 0 || parseInt(env.FORCE_COLOR, 10) !== 0;
20645
- }
20646
-
20647
- function translateLevel(level) {
20648
- if (level === 0) {
20649
- return false;
20650
- }
20651
-
20652
- return {
20653
- level,
20654
- hasBasic: true,
20655
- has256: level >= 2,
20656
- has16m: level >= 3
20657
- };
20658
- }
20659
-
20660
- function supportsColor(stream) {
20661
- if (forceColor === false) {
20662
- return 0;
20663
- }
20664
-
20665
- if (hasFlag('color=16m') ||
20666
- hasFlag('color=full') ||
20667
- hasFlag('color=truecolor')) {
20668
- return 3;
20669
- }
20670
-
20671
- if (hasFlag('color=256')) {
20672
- return 2;
20673
- }
20674
-
20675
- if (stream && !stream.isTTY && forceColor !== true) {
20676
- return 0;
20677
- }
20678
-
20679
- const min = forceColor ? 1 : 0;
20680
-
20681
- if (process.platform === 'win32') {
20682
- // Node.js 7.5.0 is the first version of Node.js to include a patch to
20683
- // libuv that enables 256 color output on Windows. Anything earlier and it
20684
- // won't work. However, here we target Node.js 8 at minimum as it is an LTS
20685
- // release, and Node.js 7 is not. Windows 10 build 10586 is the first Windows
20686
- // release that supports 256 colors. Windows 10 build 14931 is the first release
20687
- // that supports 16m/TrueColor.
20688
- const osRelease = os.release().split('.');
20689
- if (
20690
- Number(process.versions.node.split('.')[0]) >= 8 &&
20691
- Number(osRelease[0]) >= 10 &&
20692
- Number(osRelease[2]) >= 10586
20693
- ) {
20694
- return Number(osRelease[2]) >= 14931 ? 3 : 2;
20695
- }
20696
-
20697
- return 1;
20698
- }
20699
-
20700
- if ('CI' in env) {
20701
- if (['TRAVIS', 'CIRCLECI', 'APPVEYOR', 'GITLAB_CI'].some(sign => sign in env) || env.CI_NAME === 'codeship') {
20702
- return 1;
20703
- }
20704
-
20705
- return min;
20706
- }
20707
-
20708
- if ('TEAMCITY_VERSION' in env) {
20709
- return /^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(env.TEAMCITY_VERSION) ? 1 : 0;
20710
- }
20711
-
20712
- if (env.COLORTERM === 'truecolor') {
20713
- return 3;
20714
- }
20715
-
20716
- if ('TERM_PROGRAM' in env) {
20717
- const version = parseInt((env.TERM_PROGRAM_VERSION || '').split('.')[0], 10);
20718
-
20719
- switch (env.TERM_PROGRAM) {
20720
- case 'iTerm.app':
20721
- return version >= 3 ? 3 : 2;
20722
- case 'Apple_Terminal':
20723
- return 2;
20724
- // No default
20725
- }
20726
- }
20727
-
20728
- if (/-256(color)?$/i.test(env.TERM)) {
20729
- return 2;
20730
- }
20731
-
20732
- if (/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(env.TERM)) {
20733
- return 1;
20734
- }
20735
-
20736
- if ('COLORTERM' in env) {
20737
- return 1;
20738
- }
20739
-
20740
- if (env.TERM === 'dumb') {
20741
- return min;
20742
- }
20743
-
20744
- return min;
20745
- }
20746
-
20747
- function getSupportLevel(stream) {
20748
- const level = supportsColor(stream);
20749
- return translateLevel(level);
20750
- }
20341
+ /***/ (function(module) {
20751
20342
 
20752
- module.exports = {
20753
- supportsColor: getSupportLevel,
20754
- stdout: getSupportLevel(process.stdout),
20755
- stderr: getSupportLevel(process.stderr)
20756
- };
20343
+ module.exports = eval("require")("./lib/WorkerFarm");
20757
20344
 
20758
20345
 
20759
20346
  /***/ }),
@@ -21934,179 +21521,7 @@ exports.DistinctSubscriber = DistinctSubscriber;
21934
21521
  //# sourceMappingURL=distinct.js.map
21935
21522
 
21936
21523
  /***/ }),
21937
- /* 142 */
21938
- /***/ (function(module, __unusedexports, __webpack_require__) {
21939
-
21940
- "use strict";
21941
- /* module decorator */ module = __webpack_require__.nmd(module);
21942
-
21943
- const colorConvert = __webpack_require__(91);
21944
-
21945
- const wrapAnsi16 = (fn, offset) => function () {
21946
- const code = fn.apply(colorConvert, arguments);
21947
- return `\u001B[${code + offset}m`;
21948
- };
21949
-
21950
- const wrapAnsi256 = (fn, offset) => function () {
21951
- const code = fn.apply(colorConvert, arguments);
21952
- return `\u001B[${38 + offset};5;${code}m`;
21953
- };
21954
-
21955
- const wrapAnsi16m = (fn, offset) => function () {
21956
- const rgb = fn.apply(colorConvert, arguments);
21957
- return `\u001B[${38 + offset};2;${rgb[0]};${rgb[1]};${rgb[2]}m`;
21958
- };
21959
-
21960
- function assembleStyles() {
21961
- const codes = new Map();
21962
- const styles = {
21963
- modifier: {
21964
- reset: [0, 0],
21965
- // 21 isn't widely supported and 22 does the same thing
21966
- bold: [1, 22],
21967
- dim: [2, 22],
21968
- italic: [3, 23],
21969
- underline: [4, 24],
21970
- inverse: [7, 27],
21971
- hidden: [8, 28],
21972
- strikethrough: [9, 29]
21973
- },
21974
- color: {
21975
- black: [30, 39],
21976
- red: [31, 39],
21977
- green: [32, 39],
21978
- yellow: [33, 39],
21979
- blue: [34, 39],
21980
- magenta: [35, 39],
21981
- cyan: [36, 39],
21982
- white: [37, 39],
21983
- gray: [90, 39],
21984
-
21985
- // Bright color
21986
- redBright: [91, 39],
21987
- greenBright: [92, 39],
21988
- yellowBright: [93, 39],
21989
- blueBright: [94, 39],
21990
- magentaBright: [95, 39],
21991
- cyanBright: [96, 39],
21992
- whiteBright: [97, 39]
21993
- },
21994
- bgColor: {
21995
- bgBlack: [40, 49],
21996
- bgRed: [41, 49],
21997
- bgGreen: [42, 49],
21998
- bgYellow: [43, 49],
21999
- bgBlue: [44, 49],
22000
- bgMagenta: [45, 49],
22001
- bgCyan: [46, 49],
22002
- bgWhite: [47, 49],
22003
-
22004
- // Bright color
22005
- bgBlackBright: [100, 49],
22006
- bgRedBright: [101, 49],
22007
- bgGreenBright: [102, 49],
22008
- bgYellowBright: [103, 49],
22009
- bgBlueBright: [104, 49],
22010
- bgMagentaBright: [105, 49],
22011
- bgCyanBright: [106, 49],
22012
- bgWhiteBright: [107, 49]
22013
- }
22014
- };
22015
-
22016
- // Fix humans
22017
- styles.color.grey = styles.color.gray;
22018
-
22019
- for (const groupName of Object.keys(styles)) {
22020
- const group = styles[groupName];
22021
-
22022
- for (const styleName of Object.keys(group)) {
22023
- const style = group[styleName];
22024
-
22025
- styles[styleName] = {
22026
- open: `\u001B[${style[0]}m`,
22027
- close: `\u001B[${style[1]}m`
22028
- };
22029
-
22030
- group[styleName] = styles[styleName];
22031
-
22032
- codes.set(style[0], style[1]);
22033
- }
22034
-
22035
- Object.defineProperty(styles, groupName, {
22036
- value: group,
22037
- enumerable: false
22038
- });
22039
-
22040
- Object.defineProperty(styles, 'codes', {
22041
- value: codes,
22042
- enumerable: false
22043
- });
22044
- }
22045
-
22046
- const ansi2ansi = n => n;
22047
- const rgb2rgb = (r, g, b) => [r, g, b];
22048
-
22049
- styles.color.close = '\u001B[39m';
22050
- styles.bgColor.close = '\u001B[49m';
22051
-
22052
- styles.color.ansi = {
22053
- ansi: wrapAnsi16(ansi2ansi, 0)
22054
- };
22055
- styles.color.ansi256 = {
22056
- ansi256: wrapAnsi256(ansi2ansi, 0)
22057
- };
22058
- styles.color.ansi16m = {
22059
- rgb: wrapAnsi16m(rgb2rgb, 0)
22060
- };
22061
-
22062
- styles.bgColor.ansi = {
22063
- ansi: wrapAnsi16(ansi2ansi, 10)
22064
- };
22065
- styles.bgColor.ansi256 = {
22066
- ansi256: wrapAnsi256(ansi2ansi, 10)
22067
- };
22068
- styles.bgColor.ansi16m = {
22069
- rgb: wrapAnsi16m(rgb2rgb, 10)
22070
- };
22071
-
22072
- for (let key of Object.keys(colorConvert)) {
22073
- if (typeof colorConvert[key] !== 'object') {
22074
- continue;
22075
- }
22076
-
22077
- const suite = colorConvert[key];
22078
-
22079
- if (key === 'ansi16') {
22080
- key = 'ansi';
22081
- }
22082
-
22083
- if ('ansi16' in suite) {
22084
- styles.color.ansi[key] = wrapAnsi16(suite.ansi16, 0);
22085
- styles.bgColor.ansi[key] = wrapAnsi16(suite.ansi16, 10);
22086
- }
22087
-
22088
- if ('ansi256' in suite) {
22089
- styles.color.ansi256[key] = wrapAnsi256(suite.ansi256, 0);
22090
- styles.bgColor.ansi256[key] = wrapAnsi256(suite.ansi256, 10);
22091
- }
22092
-
22093
- if ('rgb' in suite) {
22094
- styles.color.ansi16m[key] = wrapAnsi16m(suite.rgb, 0);
22095
- styles.bgColor.ansi16m[key] = wrapAnsi16m(suite.rgb, 10);
22096
- }
22097
- }
22098
-
22099
- return styles;
22100
- }
22101
-
22102
- // Make the export immutable
22103
- Object.defineProperty(module, 'exports', {
22104
- enumerable: true,
22105
- get: assembleStyles
22106
- });
22107
-
22108
-
22109
- /***/ }),
21524
+ /* 142 */,
22110
21525
  /* 143 */,
22111
21526
  /* 144 */,
22112
21527
  /* 145 */,
@@ -23706,19 +23121,7 @@ function plucker(props, length) {
23706
23121
  //# sourceMappingURL=pluck.js.map
23707
23122
 
23708
23123
  /***/ }),
23709
- /* 174 */
23710
- /***/ (function(__unusedmodule, exports) {
23711
-
23712
- "use strict";
23713
-
23714
- Object.defineProperty(exports, "__esModule", { value: true });
23715
- function isPromise(value) {
23716
- return !!value && typeof value.subscribe !== 'function' && typeof value.then === 'function';
23717
- }
23718
- exports.isPromise = isPromise;
23719
- //# sourceMappingURL=isPromise.js.map
23720
-
23721
- /***/ }),
23124
+ /* 174 */,
23722
23125
  /* 175 */,
23723
23126
  /* 176 */,
23724
23127
  /* 177 */
@@ -24256,208 +23659,7 @@ exports.EmptyError = EmptyErrorImpl;
24256
23659
  //# sourceMappingURL=EmptyError.js.map
24257
23660
 
24258
23661
  /***/ }),
24259
- /* 195 */
24260
- /***/ (function(__unusedmodule, exports, __webpack_require__) {
24261
-
24262
- "use strict";
24263
-
24264
- var __extends = (this && this.__extends) || (function () {
24265
- var extendStatics = function (d, b) {
24266
- extendStatics = Object.setPrototypeOf ||
24267
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
24268
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
24269
- return extendStatics(d, b);
24270
- }
24271
- return function (d, b) {
24272
- extendStatics(d, b);
24273
- function __() { this.constructor = d; }
24274
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
24275
- };
24276
- })();
24277
- Object.defineProperty(exports, "__esModule", { value: true });
24278
- var Subscriber_1 = __webpack_require__(223);
24279
- var Subscription_1 = __webpack_require__(177);
24280
- var Observable_1 = __webpack_require__(780);
24281
- var Subject_1 = __webpack_require__(441);
24282
- function groupBy(keySelector, elementSelector, durationSelector, subjectSelector) {
24283
- return function (source) {
24284
- return source.lift(new GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector));
24285
- };
24286
- }
24287
- exports.groupBy = groupBy;
24288
- var GroupByOperator = (function () {
24289
- function GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector) {
24290
- this.keySelector = keySelector;
24291
- this.elementSelector = elementSelector;
24292
- this.durationSelector = durationSelector;
24293
- this.subjectSelector = subjectSelector;
24294
- }
24295
- GroupByOperator.prototype.call = function (subscriber, source) {
24296
- return source.subscribe(new GroupBySubscriber(subscriber, this.keySelector, this.elementSelector, this.durationSelector, this.subjectSelector));
24297
- };
24298
- return GroupByOperator;
24299
- }());
24300
- var GroupBySubscriber = (function (_super) {
24301
- __extends(GroupBySubscriber, _super);
24302
- function GroupBySubscriber(destination, keySelector, elementSelector, durationSelector, subjectSelector) {
24303
- var _this = _super.call(this, destination) || this;
24304
- _this.keySelector = keySelector;
24305
- _this.elementSelector = elementSelector;
24306
- _this.durationSelector = durationSelector;
24307
- _this.subjectSelector = subjectSelector;
24308
- _this.groups = null;
24309
- _this.attemptedToUnsubscribe = false;
24310
- _this.count = 0;
24311
- return _this;
24312
- }
24313
- GroupBySubscriber.prototype._next = function (value) {
24314
- var key;
24315
- try {
24316
- key = this.keySelector(value);
24317
- }
24318
- catch (err) {
24319
- this.error(err);
24320
- return;
24321
- }
24322
- this._group(value, key);
24323
- };
24324
- GroupBySubscriber.prototype._group = function (value, key) {
24325
- var groups = this.groups;
24326
- if (!groups) {
24327
- groups = this.groups = new Map();
24328
- }
24329
- var group = groups.get(key);
24330
- var element;
24331
- if (this.elementSelector) {
24332
- try {
24333
- element = this.elementSelector(value);
24334
- }
24335
- catch (err) {
24336
- this.error(err);
24337
- }
24338
- }
24339
- else {
24340
- element = value;
24341
- }
24342
- if (!group) {
24343
- group = (this.subjectSelector ? this.subjectSelector() : new Subject_1.Subject());
24344
- groups.set(key, group);
24345
- var groupedObservable = new GroupedObservable(key, group, this);
24346
- this.destination.next(groupedObservable);
24347
- if (this.durationSelector) {
24348
- var duration = void 0;
24349
- try {
24350
- duration = this.durationSelector(new GroupedObservable(key, group));
24351
- }
24352
- catch (err) {
24353
- this.error(err);
24354
- return;
24355
- }
24356
- this.add(duration.subscribe(new GroupDurationSubscriber(key, group, this)));
24357
- }
24358
- }
24359
- if (!group.closed) {
24360
- group.next(element);
24361
- }
24362
- };
24363
- GroupBySubscriber.prototype._error = function (err) {
24364
- var groups = this.groups;
24365
- if (groups) {
24366
- groups.forEach(function (group, key) {
24367
- group.error(err);
24368
- });
24369
- groups.clear();
24370
- }
24371
- this.destination.error(err);
24372
- };
24373
- GroupBySubscriber.prototype._complete = function () {
24374
- var groups = this.groups;
24375
- if (groups) {
24376
- groups.forEach(function (group, key) {
24377
- group.complete();
24378
- });
24379
- groups.clear();
24380
- }
24381
- this.destination.complete();
24382
- };
24383
- GroupBySubscriber.prototype.removeGroup = function (key) {
24384
- this.groups.delete(key);
24385
- };
24386
- GroupBySubscriber.prototype.unsubscribe = function () {
24387
- if (!this.closed) {
24388
- this.attemptedToUnsubscribe = true;
24389
- if (this.count === 0) {
24390
- _super.prototype.unsubscribe.call(this);
24391
- }
24392
- }
24393
- };
24394
- return GroupBySubscriber;
24395
- }(Subscriber_1.Subscriber));
24396
- var GroupDurationSubscriber = (function (_super) {
24397
- __extends(GroupDurationSubscriber, _super);
24398
- function GroupDurationSubscriber(key, group, parent) {
24399
- var _this = _super.call(this, group) || this;
24400
- _this.key = key;
24401
- _this.group = group;
24402
- _this.parent = parent;
24403
- return _this;
24404
- }
24405
- GroupDurationSubscriber.prototype._next = function (value) {
24406
- this.complete();
24407
- };
24408
- GroupDurationSubscriber.prototype._unsubscribe = function () {
24409
- var _a = this, parent = _a.parent, key = _a.key;
24410
- this.key = this.parent = null;
24411
- if (parent) {
24412
- parent.removeGroup(key);
24413
- }
24414
- };
24415
- return GroupDurationSubscriber;
24416
- }(Subscriber_1.Subscriber));
24417
- var GroupedObservable = (function (_super) {
24418
- __extends(GroupedObservable, _super);
24419
- function GroupedObservable(key, groupSubject, refCountSubscription) {
24420
- var _this = _super.call(this) || this;
24421
- _this.key = key;
24422
- _this.groupSubject = groupSubject;
24423
- _this.refCountSubscription = refCountSubscription;
24424
- return _this;
24425
- }
24426
- GroupedObservable.prototype._subscribe = function (subscriber) {
24427
- var subscription = new Subscription_1.Subscription();
24428
- var _a = this, refCountSubscription = _a.refCountSubscription, groupSubject = _a.groupSubject;
24429
- if (refCountSubscription && !refCountSubscription.closed) {
24430
- subscription.add(new InnerRefCountSubscription(refCountSubscription));
24431
- }
24432
- subscription.add(groupSubject.subscribe(subscriber));
24433
- return subscription;
24434
- };
24435
- return GroupedObservable;
24436
- }(Observable_1.Observable));
24437
- exports.GroupedObservable = GroupedObservable;
24438
- var InnerRefCountSubscription = (function (_super) {
24439
- __extends(InnerRefCountSubscription, _super);
24440
- function InnerRefCountSubscription(parent) {
24441
- var _this = _super.call(this) || this;
24442
- _this.parent = parent;
24443
- parent.count++;
24444
- return _this;
24445
- }
24446
- InnerRefCountSubscription.prototype.unsubscribe = function () {
24447
- var parent = this.parent;
24448
- if (!parent.closed && !this.closed) {
24449
- _super.prototype.unsubscribe.call(this);
24450
- parent.count -= 1;
24451
- if (parent.count === 0 && parent.attemptedToUnsubscribe) {
24452
- parent.unsubscribe();
24453
- }
24454
- }
24455
- };
24456
- return InnerRefCountSubscription;
24457
- }(Subscription_1.Subscription));
24458
- //# sourceMappingURL=groupBy.js.map
24459
-
24460
- /***/ }),
23662
+ /* 195 */,
24461
23663
  /* 196 */
24462
23664
  /***/ (function(__unusedmodule, exports, __webpack_require__) {
24463
23665
 
@@ -25212,157 +24414,7 @@ const twosComp = byte => ((0xff ^ byte) + 1) & 0xff
25212
24414
 
25213
24415
  /***/ }),
25214
24416
  /* 201 */,
25215
- /* 202 */
25216
- /***/ (function(module, __unusedexports, __webpack_require__) {
25217
-
25218
- var Stream = __webpack_require__(413)
25219
-
25220
- module.exports = MuteStream
25221
-
25222
- // var out = new MuteStream(process.stdout)
25223
- // argument auto-pipes
25224
- function MuteStream (opts) {
25225
- Stream.apply(this)
25226
- opts = opts || {}
25227
- this.writable = this.readable = true
25228
- this.muted = false
25229
- this.on('pipe', this._onpipe)
25230
- this.replace = opts.replace
25231
-
25232
- // For readline-type situations
25233
- // This much at the start of a line being redrawn after a ctrl char
25234
- // is seen (such as backspace) won't be redrawn as the replacement
25235
- this._prompt = opts.prompt || null
25236
- this._hadControl = false
25237
- }
25238
-
25239
- MuteStream.prototype = Object.create(Stream.prototype)
25240
-
25241
- Object.defineProperty(MuteStream.prototype, 'constructor', {
25242
- value: MuteStream,
25243
- enumerable: false
25244
- })
25245
-
25246
- MuteStream.prototype.mute = function () {
25247
- this.muted = true
25248
- }
25249
-
25250
- MuteStream.prototype.unmute = function () {
25251
- this.muted = false
25252
- }
25253
-
25254
- Object.defineProperty(MuteStream.prototype, '_onpipe', {
25255
- value: onPipe,
25256
- enumerable: false,
25257
- writable: true,
25258
- configurable: true
25259
- })
25260
-
25261
- function onPipe (src) {
25262
- this._src = src
25263
- }
25264
-
25265
- Object.defineProperty(MuteStream.prototype, 'isTTY', {
25266
- get: getIsTTY,
25267
- set: setIsTTY,
25268
- enumerable: true,
25269
- configurable: true
25270
- })
25271
-
25272
- function getIsTTY () {
25273
- return( (this._dest) ? this._dest.isTTY
25274
- : (this._src) ? this._src.isTTY
25275
- : false
25276
- )
25277
- }
25278
-
25279
- // basically just get replace the getter/setter with a regular value
25280
- function setIsTTY (isTTY) {
25281
- Object.defineProperty(this, 'isTTY', {
25282
- value: isTTY,
25283
- enumerable: true,
25284
- writable: true,
25285
- configurable: true
25286
- })
25287
- }
25288
-
25289
- Object.defineProperty(MuteStream.prototype, 'rows', {
25290
- get: function () {
25291
- return( this._dest ? this._dest.rows
25292
- : this._src ? this._src.rows
25293
- : undefined )
25294
- }, enumerable: true, configurable: true })
25295
-
25296
- Object.defineProperty(MuteStream.prototype, 'columns', {
25297
- get: function () {
25298
- return( this._dest ? this._dest.columns
25299
- : this._src ? this._src.columns
25300
- : undefined )
25301
- }, enumerable: true, configurable: true })
25302
-
25303
-
25304
- MuteStream.prototype.pipe = function (dest, options) {
25305
- this._dest = dest
25306
- return Stream.prototype.pipe.call(this, dest, options)
25307
- }
25308
-
25309
- MuteStream.prototype.pause = function () {
25310
- if (this._src) return this._src.pause()
25311
- }
25312
-
25313
- MuteStream.prototype.resume = function () {
25314
- if (this._src) return this._src.resume()
25315
- }
25316
-
25317
- MuteStream.prototype.write = function (c) {
25318
- if (this.muted) {
25319
- if (!this.replace) return true
25320
- if (c.match(/^\u001b/)) {
25321
- if(c.indexOf(this._prompt) === 0) {
25322
- c = c.substr(this._prompt.length);
25323
- c = c.replace(/./g, this.replace);
25324
- c = this._prompt + c;
25325
- }
25326
- this._hadControl = true
25327
- return this.emit('data', c)
25328
- } else {
25329
- if (this._prompt && this._hadControl &&
25330
- c.indexOf(this._prompt) === 0) {
25331
- this._hadControl = false
25332
- this.emit('data', this._prompt)
25333
- c = c.substr(this._prompt.length)
25334
- }
25335
- c = c.toString().replace(/./g, this.replace)
25336
- }
25337
- }
25338
- this.emit('data', c)
25339
- }
25340
-
25341
- MuteStream.prototype.end = function (c) {
25342
- if (this.muted) {
25343
- if (c && this.replace) {
25344
- c = c.toString().replace(/./g, this.replace)
25345
- } else {
25346
- c = null
25347
- }
25348
- }
25349
- if (c) this.emit('data', c)
25350
- this.emit('end')
25351
- }
25352
-
25353
- function proxy (fn) { return function () {
25354
- var d = this._dest
25355
- var s = this._src
25356
- if (d && d[fn]) d[fn].apply(d, arguments)
25357
- if (s && s[fn]) s[fn].apply(s, arguments)
25358
- }}
25359
-
25360
- MuteStream.prototype.destroy = proxy('destroy')
25361
- MuteStream.prototype.destroySoon = proxy('destroySoon')
25362
- MuteStream.prototype.close = proxy('close')
25363
-
25364
-
25365
- /***/ }),
24417
+ /* 202 */,
25366
24418
  /* 203 */,
25367
24419
  /* 204 */,
25368
24420
  /* 205 */,
@@ -25612,7 +24664,7 @@ function state(list, sortMethod)
25612
24664
  "use strict";
25613
24665
 
25614
24666
  var _ = __webpack_require__(53);
25615
- var MuteStream = __webpack_require__(202);
24667
+ var MuteStream = __webpack_require__(738);
25616
24668
  var readline = __webpack_require__(58);
25617
24669
 
25618
24670
  /**
@@ -26855,7 +25907,7 @@ var schedulePromise_1 = __webpack_require__(414);
26855
25907
  var scheduleArray_1 = __webpack_require__(362);
26856
25908
  var scheduleIterable_1 = __webpack_require__(549);
26857
25909
  var isInteropObservable_1 = __webpack_require__(982);
26858
- var isPromise_1 = __webpack_require__(174);
25910
+ var isPromise_1 = __webpack_require__(275);
26859
25911
  var isArrayLike_1 = __webpack_require__(936);
26860
25912
  var isIterable_1 = __webpack_require__(226);
26861
25913
  function scheduled(input, scheduler) {
@@ -27704,10 +26756,16 @@ exports.not = not;
27704
26756
  /***/ }),
27705
26757
  /* 274 */,
27706
26758
  /* 275 */
27707
- /***/ (function(module) {
26759
+ /***/ (function(__unusedmodule, exports) {
27708
26760
 
27709
- module.exports = eval("require")("./lib/WorkerFarm");
26761
+ "use strict";
27710
26762
 
26763
+ Object.defineProperty(exports, "__esModule", { value: true });
26764
+ function isPromise(value) {
26765
+ return !!value && typeof value.subscribe !== 'function' && typeof value.then === 'function';
26766
+ }
26767
+ exports.isPromise = isPromise;
26768
+ //# sourceMappingURL=isPromise.js.map
27711
26769
 
27712
26770
  /***/ }),
27713
26771
  /* 276 */,
@@ -27739,7 +26797,7 @@ module.exports = eval("require")("./lib/WorkerFarm");
27739
26797
 
27740
26798
  const warner = __webpack_require__(458)
27741
26799
  const path = __webpack_require__(622)
27742
- const Header = __webpack_require__(660)
26800
+ const Header = __webpack_require__(745)
27743
26801
  const EE = __webpack_require__(614)
27744
26802
  const Yallist = __webpack_require__(722)
27745
26803
  const maxMetaEntrySize = 1024 * 1024
@@ -31214,7 +30272,7 @@ exports.isArray = (function () { return Array.isArray || (function (x) { return
31214
30272
  if (typeof process !== 'undefined' && process.type === 'renderer') {
31215
30273
  module.exports = __webpack_require__(576);
31216
30274
  } else {
31217
- module.exports = __webpack_require__(845);
30275
+ module.exports = __webpack_require__(875);
31218
30276
  }
31219
30277
 
31220
30278
 
@@ -31561,7 +30619,7 @@ const path = __webpack_require__(622)
31561
30619
  // and try again.
31562
30620
  // Write the new Pack stream starting there.
31563
30621
 
31564
- const Header = __webpack_require__(660)
30622
+ const Header = __webpack_require__(745)
31565
30623
 
31566
30624
  const r = module.exports = (opt_, files, cb) => {
31567
30625
  const opt = hlo(opt_)
@@ -40336,7 +39394,7 @@ var WindowSubscriber = (function (_super) {
40336
39394
  "use strict";
40337
39395
 
40338
39396
  const Buffer = __webpack_require__(559)
40339
- const Header = __webpack_require__(660)
39397
+ const Header = __webpack_require__(745)
40340
39398
  const path = __webpack_require__(622)
40341
39399
 
40342
39400
  class Pax {
@@ -41516,7 +40574,7 @@ var deepExtend = module.exports = function (/*obj_1, [obj_2], [obj_N]*/) {
41516
40574
  const chalk = __webpack_require__(860);
41517
40575
  const cliCursor = __webpack_require__(806);
41518
40576
  const cliSpinners = __webpack_require__(260);
41519
- const logSymbols = __webpack_require__(745);
40577
+ const logSymbols = __webpack_require__(845);
41520
40578
  const stripAnsi = __webpack_require__(832);
41521
40579
  const wcwidth = __webpack_require__(493);
41522
40580
 
@@ -42585,7 +41643,7 @@ inquirer.createPromptModule = function(opt) {
42585
41643
  this.registerPrompt('number', __webpack_require__(736));
42586
41644
  this.registerPrompt('confirm', __webpack_require__(756));
42587
41645
  this.registerPrompt('rawlist', __webpack_require__(775));
42588
- this.registerPrompt('expand', __webpack_require__(82));
41646
+ this.registerPrompt('expand', __webpack_require__(601));
42589
41647
  this.registerPrompt('checkbox', __webpack_require__(27));
42590
41648
  this.registerPrompt('password', __webpack_require__(574));
42591
41649
  this.registerPrompt('editor', __webpack_require__(712));
@@ -42645,17 +41703,285 @@ module.exports = function createError(message, config, code, request, response)
42645
41703
  /* 599 */,
42646
41704
  /* 600 */,
42647
41705
  /* 601 */
42648
- /***/ (function(module) {
41706
+ /***/ (function(module, __unusedexports, __webpack_require__) {
42649
41707
 
42650
41708
  "use strict";
42651
41709
 
42652
- module.exports = (flag, argv) => {
42653
- argv = argv || process.argv;
42654
- const prefix = flag.startsWith('-') ? '' : (flag.length === 1 ? '-' : '--');
42655
- const pos = argv.indexOf(prefix + flag);
42656
- const terminatorPos = argv.indexOf('--');
42657
- return pos !== -1 && (terminatorPos === -1 ? true : pos < terminatorPos);
42658
- };
41710
+ /**
41711
+ * `rawlist` type prompt
41712
+ */
41713
+
41714
+ var _ = __webpack_require__(53);
41715
+ var chalk = __webpack_require__(393);
41716
+ var { map, takeUntil } = __webpack_require__(605);
41717
+ var Base = __webpack_require__(966);
41718
+ var Separator = __webpack_require__(81);
41719
+ var observe = __webpack_require__(595);
41720
+ var Paginator = __webpack_require__(784);
41721
+
41722
+ class ExpandPrompt extends Base {
41723
+ constructor(questions, rl, answers) {
41724
+ super(questions, rl, answers);
41725
+
41726
+ if (!this.opt.choices) {
41727
+ this.throwParamError('choices');
41728
+ }
41729
+
41730
+ this.validateChoices(this.opt.choices);
41731
+
41732
+ // Add the default `help` (/expand) option
41733
+ this.opt.choices.push({
41734
+ key: 'h',
41735
+ name: 'Help, list all options',
41736
+ value: 'help'
41737
+ });
41738
+
41739
+ this.opt.validate = choice => {
41740
+ if (choice == null) {
41741
+ return 'Please enter a valid command';
41742
+ }
41743
+
41744
+ return choice !== 'help';
41745
+ };
41746
+
41747
+ // Setup the default string (capitalize the default key)
41748
+ this.opt.default = this.generateChoicesString(this.opt.choices, this.opt.default);
41749
+
41750
+ this.paginator = new Paginator(this.screen);
41751
+ }
41752
+
41753
+ /**
41754
+ * Start the Inquiry session
41755
+ * @param {Function} cb Callback when prompt is done
41756
+ * @return {this}
41757
+ */
41758
+
41759
+ _run(cb) {
41760
+ this.done = cb;
41761
+
41762
+ // Save user answer and update prompt to show selected option.
41763
+ var events = observe(this.rl);
41764
+ var validation = this.handleSubmitEvents(
41765
+ events.line.pipe(map(this.getCurrentValue.bind(this)))
41766
+ );
41767
+ validation.success.forEach(this.onSubmit.bind(this));
41768
+ validation.error.forEach(this.onError.bind(this));
41769
+ this.keypressObs = events.keypress
41770
+ .pipe(takeUntil(validation.success))
41771
+ .forEach(this.onKeypress.bind(this));
41772
+
41773
+ // Init the prompt
41774
+ this.render();
41775
+
41776
+ return this;
41777
+ }
41778
+
41779
+ /**
41780
+ * Render the prompt to screen
41781
+ * @return {ExpandPrompt} self
41782
+ */
41783
+
41784
+ render(error, hint) {
41785
+ var message = this.getQuestion();
41786
+ var bottomContent = '';
41787
+
41788
+ if (this.status === 'answered') {
41789
+ message += chalk.cyan(this.answer);
41790
+ } else if (this.status === 'expanded') {
41791
+ var choicesStr = renderChoices(this.opt.choices, this.selectedKey);
41792
+ message += this.paginator.paginate(choicesStr, this.selectedKey, this.opt.pageSize);
41793
+ message += '\n Answer: ';
41794
+ }
41795
+
41796
+ message += this.rl.line;
41797
+
41798
+ if (error) {
41799
+ bottomContent = chalk.red('>> ') + error;
41800
+ }
41801
+
41802
+ if (hint) {
41803
+ bottomContent = chalk.cyan('>> ') + hint;
41804
+ }
41805
+
41806
+ this.screen.render(message, bottomContent);
41807
+ }
41808
+
41809
+ getCurrentValue(input) {
41810
+ if (!input) {
41811
+ input = this.rawDefault;
41812
+ }
41813
+
41814
+ var selected = this.opt.choices.where({ key: input.toLowerCase().trim() })[0];
41815
+ if (!selected) {
41816
+ return null;
41817
+ }
41818
+
41819
+ return selected.value;
41820
+ }
41821
+
41822
+ /**
41823
+ * Generate the prompt choices string
41824
+ * @return {String} Choices string
41825
+ */
41826
+
41827
+ getChoices() {
41828
+ var output = '';
41829
+
41830
+ this.opt.choices.forEach(choice => {
41831
+ output += '\n ';
41832
+
41833
+ if (choice.type === 'separator') {
41834
+ output += ' ' + choice;
41835
+ return;
41836
+ }
41837
+
41838
+ var choiceStr = choice.key + ') ' + choice.name;
41839
+ if (this.selectedKey === choice.key) {
41840
+ choiceStr = chalk.cyan(choiceStr);
41841
+ }
41842
+
41843
+ output += choiceStr;
41844
+ });
41845
+
41846
+ return output;
41847
+ }
41848
+
41849
+ onError(state) {
41850
+ if (state.value === 'help') {
41851
+ this.selectedKey = '';
41852
+ this.status = 'expanded';
41853
+ this.render();
41854
+ return;
41855
+ }
41856
+
41857
+ this.render(state.isValid);
41858
+ }
41859
+
41860
+ /**
41861
+ * When user press `enter` key
41862
+ */
41863
+
41864
+ onSubmit(state) {
41865
+ this.status = 'answered';
41866
+ var choice = this.opt.choices.where({ value: state.value })[0];
41867
+ this.answer = choice.short || choice.name;
41868
+
41869
+ // Re-render prompt
41870
+ this.render();
41871
+ this.screen.done();
41872
+ this.done(state.value);
41873
+ }
41874
+
41875
+ /**
41876
+ * When user press a key
41877
+ */
41878
+
41879
+ onKeypress() {
41880
+ this.selectedKey = this.rl.line.toLowerCase();
41881
+ var selected = this.opt.choices.where({ key: this.selectedKey })[0];
41882
+ if (this.status === 'expanded') {
41883
+ this.render();
41884
+ } else {
41885
+ this.render(null, selected ? selected.name : null);
41886
+ }
41887
+ }
41888
+
41889
+ /**
41890
+ * Validate the choices
41891
+ * @param {Array} choices
41892
+ */
41893
+
41894
+ validateChoices(choices) {
41895
+ var formatError;
41896
+ var errors = [];
41897
+ var keymap = {};
41898
+ choices.filter(Separator.exclude).forEach(choice => {
41899
+ if (!choice.key || choice.key.length !== 1) {
41900
+ formatError = true;
41901
+ }
41902
+
41903
+ if (keymap[choice.key]) {
41904
+ errors.push(choice.key);
41905
+ }
41906
+
41907
+ keymap[choice.key] = true;
41908
+ choice.key = String(choice.key).toLowerCase();
41909
+ });
41910
+
41911
+ if (formatError) {
41912
+ throw new Error(
41913
+ 'Format error: `key` param must be a single letter and is required.'
41914
+ );
41915
+ }
41916
+
41917
+ if (keymap.h) {
41918
+ throw new Error(
41919
+ 'Reserved key error: `key` param cannot be `h` - this value is reserved.'
41920
+ );
41921
+ }
41922
+
41923
+ if (errors.length) {
41924
+ throw new Error(
41925
+ 'Duplicate key error: `key` param must be unique. Duplicates: ' +
41926
+ _.uniq(errors).join(', ')
41927
+ );
41928
+ }
41929
+ }
41930
+
41931
+ /**
41932
+ * Generate a string out of the choices keys
41933
+ * @param {Array} choices
41934
+ * @param {Number|String} default - the choice index or name to capitalize
41935
+ * @return {String} The rendered choices key string
41936
+ */
41937
+ generateChoicesString(choices, defaultChoice) {
41938
+ var defIndex = choices.realLength - 1;
41939
+ if (_.isNumber(defaultChoice) && this.opt.choices.getChoice(defaultChoice)) {
41940
+ defIndex = defaultChoice;
41941
+ } else if (_.isString(defaultChoice)) {
41942
+ let index = _.findIndex(
41943
+ choices.realChoices,
41944
+ ({ value }) => value === defaultChoice
41945
+ );
41946
+ defIndex = index === -1 ? defIndex : index;
41947
+ }
41948
+
41949
+ var defStr = this.opt.choices.pluck('key');
41950
+ this.rawDefault = defStr[defIndex];
41951
+ defStr[defIndex] = String(defStr[defIndex]).toUpperCase();
41952
+ return defStr.join('');
41953
+ }
41954
+ }
41955
+
41956
+ /**
41957
+ * Function for rendering checkbox choices
41958
+ * @param {String} pointer Selected key
41959
+ * @return {String} Rendered content
41960
+ */
41961
+
41962
+ function renderChoices(choices, pointer) {
41963
+ var output = '';
41964
+
41965
+ choices.forEach(choice => {
41966
+ output += '\n ';
41967
+
41968
+ if (choice.type === 'separator') {
41969
+ output += ' ' + choice;
41970
+ return;
41971
+ }
41972
+
41973
+ var choiceStr = choice.key + ') ' + choice.name;
41974
+ if (pointer === choice.key) {
41975
+ choiceStr = chalk.cyan(choiceStr);
41976
+ }
41977
+
41978
+ output += choiceStr;
41979
+ });
41980
+
41981
+ return output;
41982
+ }
41983
+
41984
+ module.exports = ExpandPrompt;
42659
41985
 
42660
41986
 
42661
41987
  /***/ }),
@@ -42754,7 +42080,7 @@ var findIndex_1 = __webpack_require__(700);
42754
42080
  exports.findIndex = findIndex_1.findIndex;
42755
42081
  var first_1 = __webpack_require__(430);
42756
42082
  exports.first = first_1.first;
42757
- var groupBy_1 = __webpack_require__(195);
42083
+ var groupBy_1 = __webpack_require__(665);
42758
42084
  exports.groupBy = groupBy_1.groupBy;
42759
42085
  var ignoreElements_1 = __webpack_require__(940);
42760
42086
  exports.ignoreElements = ignoreElements_1.ignoreElements;
@@ -45516,302 +44842,7 @@ exports.isObservable = isObservable;
45516
44842
  //# sourceMappingURL=isObservable.js.map
45517
44843
 
45518
44844
  /***/ }),
45519
- /* 660 */
45520
- /***/ (function(module, __unusedexports, __webpack_require__) {
45521
-
45522
- "use strict";
45523
-
45524
- // parse a 512-byte header block to a data object, or vice-versa
45525
- // encode returns `true` if a pax extended header is needed, because
45526
- // the data could not be faithfully encoded in a simple header.
45527
- // (Also, check header.needPax to see if it needs a pax header.)
45528
-
45529
- const Buffer = __webpack_require__(559)
45530
- const types = __webpack_require__(590)
45531
- const pathModule = __webpack_require__(622).posix
45532
- const large = __webpack_require__(200)
45533
-
45534
- const SLURP = Symbol('slurp')
45535
- const TYPE = Symbol('type')
45536
-
45537
- class Header {
45538
- constructor (data, off, ex, gex) {
45539
- this.cksumValid = false
45540
- this.needPax = false
45541
- this.nullBlock = false
45542
-
45543
- this.block = null
45544
- this.path = null
45545
- this.mode = null
45546
- this.uid = null
45547
- this.gid = null
45548
- this.size = null
45549
- this.mtime = null
45550
- this.cksum = null
45551
- this[TYPE] = '0'
45552
- this.linkpath = null
45553
- this.uname = null
45554
- this.gname = null
45555
- this.devmaj = 0
45556
- this.devmin = 0
45557
- this.atime = null
45558
- this.ctime = null
45559
-
45560
- if (Buffer.isBuffer(data))
45561
- this.decode(data, off || 0, ex, gex)
45562
- else if (data)
45563
- this.set(data)
45564
- }
45565
-
45566
- decode (buf, off, ex, gex) {
45567
- if (!off)
45568
- off = 0
45569
-
45570
- if (!buf || !(buf.length >= off + 512))
45571
- throw new Error('need 512 bytes for header')
45572
-
45573
- this.path = decString(buf, off, 100)
45574
- this.mode = decNumber(buf, off + 100, 8)
45575
- this.uid = decNumber(buf, off + 108, 8)
45576
- this.gid = decNumber(buf, off + 116, 8)
45577
- this.size = decNumber(buf, off + 124, 12)
45578
- this.mtime = decDate(buf, off + 136, 12)
45579
- this.cksum = decNumber(buf, off + 148, 12)
45580
-
45581
- // if we have extended or global extended headers, apply them now
45582
- // See https://github.com/npm/node-tar/pull/187
45583
- this[SLURP](ex)
45584
- this[SLURP](gex, true)
45585
-
45586
- // old tar versions marked dirs as a file with a trailing /
45587
- this[TYPE] = decString(buf, off + 156, 1)
45588
- if (this[TYPE] === '')
45589
- this[TYPE] = '0'
45590
- if (this[TYPE] === '0' && this.path.substr(-1) === '/')
45591
- this[TYPE] = '5'
45592
-
45593
- // tar implementations sometimes incorrectly put the stat(dir).size
45594
- // as the size in the tarball, even though Directory entries are
45595
- // not able to have any body at all. In the very rare chance that
45596
- // it actually DOES have a body, we weren't going to do anything with
45597
- // it anyway, and it'll just be a warning about an invalid header.
45598
- if (this[TYPE] === '5')
45599
- this.size = 0
45600
-
45601
- this.linkpath = decString(buf, off + 157, 100)
45602
- if (buf.slice(off + 257, off + 265).toString() === 'ustar\u000000') {
45603
- this.uname = decString(buf, off + 265, 32)
45604
- this.gname = decString(buf, off + 297, 32)
45605
- this.devmaj = decNumber(buf, off + 329, 8)
45606
- this.devmin = decNumber(buf, off + 337, 8)
45607
- if (buf[off + 475] !== 0) {
45608
- // definitely a prefix, definitely >130 chars.
45609
- const prefix = decString(buf, off + 345, 155)
45610
- this.path = prefix + '/' + this.path
45611
- } else {
45612
- const prefix = decString(buf, off + 345, 130)
45613
- if (prefix)
45614
- this.path = prefix + '/' + this.path
45615
- this.atime = decDate(buf, off + 476, 12)
45616
- this.ctime = decDate(buf, off + 488, 12)
45617
- }
45618
- }
45619
-
45620
- let sum = 8 * 0x20
45621
- for (let i = off; i < off + 148; i++) {
45622
- sum += buf[i]
45623
- }
45624
- for (let i = off + 156; i < off + 512; i++) {
45625
- sum += buf[i]
45626
- }
45627
- this.cksumValid = sum === this.cksum
45628
- if (this.cksum === null && sum === 8 * 0x20)
45629
- this.nullBlock = true
45630
- }
45631
-
45632
- [SLURP] (ex, global) {
45633
- for (let k in ex) {
45634
- // we slurp in everything except for the path attribute in
45635
- // a global extended header, because that's weird.
45636
- if (ex[k] !== null && ex[k] !== undefined &&
45637
- !(global && k === 'path'))
45638
- this[k] = ex[k]
45639
- }
45640
- }
45641
-
45642
- encode (buf, off) {
45643
- if (!buf) {
45644
- buf = this.block = Buffer.alloc(512)
45645
- off = 0
45646
- }
45647
-
45648
- if (!off)
45649
- off = 0
45650
-
45651
- if (!(buf.length >= off + 512))
45652
- throw new Error('need 512 bytes for header')
45653
-
45654
- const prefixSize = this.ctime || this.atime ? 130 : 155
45655
- const split = splitPrefix(this.path || '', prefixSize)
45656
- const path = split[0]
45657
- const prefix = split[1]
45658
- this.needPax = split[2]
45659
-
45660
- this.needPax = encString(buf, off, 100, path) || this.needPax
45661
- this.needPax = encNumber(buf, off + 100, 8, this.mode) || this.needPax
45662
- this.needPax = encNumber(buf, off + 108, 8, this.uid) || this.needPax
45663
- this.needPax = encNumber(buf, off + 116, 8, this.gid) || this.needPax
45664
- this.needPax = encNumber(buf, off + 124, 12, this.size) || this.needPax
45665
- this.needPax = encDate(buf, off + 136, 12, this.mtime) || this.needPax
45666
- buf[off + 156] = this[TYPE].charCodeAt(0)
45667
- this.needPax = encString(buf, off + 157, 100, this.linkpath) || this.needPax
45668
- buf.write('ustar\u000000', off + 257, 8)
45669
- this.needPax = encString(buf, off + 265, 32, this.uname) || this.needPax
45670
- this.needPax = encString(buf, off + 297, 32, this.gname) || this.needPax
45671
- this.needPax = encNumber(buf, off + 329, 8, this.devmaj) || this.needPax
45672
- this.needPax = encNumber(buf, off + 337, 8, this.devmin) || this.needPax
45673
- this.needPax = encString(buf, off + 345, prefixSize, prefix) || this.needPax
45674
- if (buf[off + 475] !== 0)
45675
- this.needPax = encString(buf, off + 345, 155, prefix) || this.needPax
45676
- else {
45677
- this.needPax = encString(buf, off + 345, 130, prefix) || this.needPax
45678
- this.needPax = encDate(buf, off + 476, 12, this.atime) || this.needPax
45679
- this.needPax = encDate(buf, off + 488, 12, this.ctime) || this.needPax
45680
- }
45681
-
45682
- let sum = 8 * 0x20
45683
- for (let i = off; i < off + 148; i++) {
45684
- sum += buf[i]
45685
- }
45686
- for (let i = off + 156; i < off + 512; i++) {
45687
- sum += buf[i]
45688
- }
45689
- this.cksum = sum
45690
- encNumber(buf, off + 148, 8, this.cksum)
45691
- this.cksumValid = true
45692
-
45693
- return this.needPax
45694
- }
45695
-
45696
- set (data) {
45697
- for (let i in data) {
45698
- if (data[i] !== null && data[i] !== undefined)
45699
- this[i] = data[i]
45700
- }
45701
- }
45702
-
45703
- get type () {
45704
- return types.name.get(this[TYPE]) || this[TYPE]
45705
- }
45706
-
45707
- get typeKey () {
45708
- return this[TYPE]
45709
- }
45710
-
45711
- set type (type) {
45712
- if (types.code.has(type))
45713
- this[TYPE] = types.code.get(type)
45714
- else
45715
- this[TYPE] = type
45716
- }
45717
- }
45718
-
45719
- const splitPrefix = (p, prefixSize) => {
45720
- const pathSize = 100
45721
- let pp = p
45722
- let prefix = ''
45723
- let ret
45724
- const root = pathModule.parse(p).root || '.'
45725
-
45726
- if (Buffer.byteLength(pp) < pathSize)
45727
- ret = [pp, prefix, false]
45728
- else {
45729
- // first set prefix to the dir, and path to the base
45730
- prefix = pathModule.dirname(pp)
45731
- pp = pathModule.basename(pp)
45732
-
45733
- do {
45734
- // both fit!
45735
- if (Buffer.byteLength(pp) <= pathSize &&
45736
- Buffer.byteLength(prefix) <= prefixSize)
45737
- ret = [pp, prefix, false]
45738
-
45739
- // prefix fits in prefix, but path doesn't fit in path
45740
- else if (Buffer.byteLength(pp) > pathSize &&
45741
- Buffer.byteLength(prefix) <= prefixSize)
45742
- ret = [pp.substr(0, pathSize - 1), prefix, true]
45743
-
45744
- else {
45745
- // make path take a bit from prefix
45746
- pp = pathModule.join(pathModule.basename(prefix), pp)
45747
- prefix = pathModule.dirname(prefix)
45748
- }
45749
- } while (prefix !== root && !ret)
45750
-
45751
- // at this point, found no resolution, just truncate
45752
- if (!ret)
45753
- ret = [p.substr(0, pathSize - 1), '', true]
45754
- }
45755
- return ret
45756
- }
45757
-
45758
- const decString = (buf, off, size) =>
45759
- buf.slice(off, off + size).toString('utf8').replace(/\0.*/, '')
45760
-
45761
- const decDate = (buf, off, size) =>
45762
- numToDate(decNumber(buf, off, size))
45763
-
45764
- const numToDate = num => num === null ? null : new Date(num * 1000)
45765
-
45766
- const decNumber = (buf, off, size) =>
45767
- buf[off] & 0x80 ? large.parse(buf.slice(off, off + size))
45768
- : decSmallNumber(buf, off, size)
45769
-
45770
- const nanNull = value => isNaN(value) ? null : value
45771
-
45772
- const decSmallNumber = (buf, off, size) =>
45773
- nanNull(parseInt(
45774
- buf.slice(off, off + size)
45775
- .toString('utf8').replace(/\0.*$/, '').trim(), 8))
45776
-
45777
- // the maximum encodable as a null-terminated octal, by field size
45778
- const MAXNUM = {
45779
- 12: 0o77777777777,
45780
- 8 : 0o7777777
45781
- }
45782
-
45783
- const encNumber = (buf, off, size, number) =>
45784
- number === null ? false :
45785
- number > MAXNUM[size] || number < 0
45786
- ? (large.encode(number, buf.slice(off, off + size)), true)
45787
- : (encSmallNumber(buf, off, size, number), false)
45788
-
45789
- const encSmallNumber = (buf, off, size, number) =>
45790
- buf.write(octalString(number, size), off, size, 'ascii')
45791
-
45792
- const octalString = (number, size) =>
45793
- padOctal(Math.floor(number).toString(8), size)
45794
-
45795
- const padOctal = (string, size) =>
45796
- (string.length === size - 1 ? string
45797
- : new Array(size - string.length - 1).join('0') + string + ' ') + '\0'
45798
-
45799
- const encDate = (buf, off, size, date) =>
45800
- date === null ? false :
45801
- encNumber(buf, off, size, date.getTime() / 1000)
45802
-
45803
- // enough to fill the longest string we've got
45804
- const NULLS = new Array(156).join('\0')
45805
- // pad with nulls, return true if it's longer or non-ascii
45806
- const encString = (buf, off, size, string) =>
45807
- string === null ? false :
45808
- (buf.write(string + NULLS, off, size, 'utf8'),
45809
- string.length !== Buffer.byteLength(string) || string.length > size)
45810
-
45811
- module.exports = Header
45812
-
45813
-
45814
- /***/ }),
44845
+ /* 660 */,
45815
44846
  /* 661 */
45816
44847
  /***/ (function(module) {
45817
44848
 
@@ -45822,238 +44853,205 @@ module.exports = [["0","\u0000",127],["8ea1","。",62],["a1a1"," 、。,.
45822
44853
  /* 663 */,
45823
44854
  /* 664 */,
45824
44855
  /* 665 */
45825
- /***/ (function(module, __unusedexports, __webpack_require__) {
44856
+ /***/ (function(__unusedmodule, exports, __webpack_require__) {
45826
44857
 
45827
44858
  "use strict";
45828
44859
 
45829
- const escapeStringRegexp = __webpack_require__(190);
45830
- const ansiStyles = __webpack_require__(142);
45831
- const stdoutColor = __webpack_require__(94).stdout;
45832
-
45833
- const template = __webpack_require__(738);
45834
-
45835
- const isSimpleWindowsTerm = process.platform === 'win32' && !(process.env.TERM || '').toLowerCase().startsWith('xterm');
45836
-
45837
- // `supportsColor.level` → `ansiStyles.color[name]` mapping
45838
- const levelMapping = ['ansi', 'ansi', 'ansi256', 'ansi16m'];
45839
-
45840
- // `color-convert` models to exclude from the Chalk API due to conflicts and such
45841
- const skipModels = new Set(['gray']);
45842
-
45843
- const styles = Object.create(null);
45844
-
45845
- function applyOptions(obj, options) {
45846
- options = options || {};
45847
-
45848
- // Detect level if not set manually
45849
- const scLevel = stdoutColor ? stdoutColor.level : 0;
45850
- obj.level = options.level === undefined ? scLevel : options.level;
45851
- obj.enabled = 'enabled' in options ? options.enabled : obj.level > 0;
45852
- }
45853
-
45854
- function Chalk(options) {
45855
- // We check for this.template here since calling `chalk.constructor()`
45856
- // by itself will have a `this` of a previously constructed chalk object
45857
- if (!this || !(this instanceof Chalk) || this.template) {
45858
- const chalk = {};
45859
- applyOptions(chalk, options);
45860
-
45861
- chalk.template = function () {
45862
- const args = [].slice.call(arguments);
45863
- return chalkTag.apply(null, [chalk.template].concat(args));
45864
- };
45865
-
45866
- Object.setPrototypeOf(chalk, Chalk.prototype);
45867
- Object.setPrototypeOf(chalk.template, chalk);
45868
-
45869
- chalk.template.constructor = Chalk;
45870
-
45871
- return chalk.template;
45872
- }
45873
-
45874
- applyOptions(this, options);
45875
- }
45876
-
45877
- // Use bright blue on Windows as the normal blue color is illegible
45878
- if (isSimpleWindowsTerm) {
45879
- ansiStyles.blue.open = '\u001B[94m';
45880
- }
45881
-
45882
- for (const key of Object.keys(ansiStyles)) {
45883
- ansiStyles[key].closeRe = new RegExp(escapeStringRegexp(ansiStyles[key].close), 'g');
45884
-
45885
- styles[key] = {
45886
- get() {
45887
- const codes = ansiStyles[key];
45888
- return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, key);
45889
- }
45890
- };
45891
- }
45892
-
45893
- styles.visible = {
45894
- get() {
45895
- return build.call(this, this._styles || [], true, 'visible');
45896
- }
45897
- };
45898
-
45899
- ansiStyles.color.closeRe = new RegExp(escapeStringRegexp(ansiStyles.color.close), 'g');
45900
- for (const model of Object.keys(ansiStyles.color.ansi)) {
45901
- if (skipModels.has(model)) {
45902
- continue;
45903
- }
45904
-
45905
- styles[model] = {
45906
- get() {
45907
- const level = this.level;
45908
- return function () {
45909
- const open = ansiStyles.color[levelMapping[level]][model].apply(null, arguments);
45910
- const codes = {
45911
- open,
45912
- close: ansiStyles.color.close,
45913
- closeRe: ansiStyles.color.closeRe
45914
- };
45915
- return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, model);
45916
- };
45917
- }
45918
- };
45919
- }
45920
-
45921
- ansiStyles.bgColor.closeRe = new RegExp(escapeStringRegexp(ansiStyles.bgColor.close), 'g');
45922
- for (const model of Object.keys(ansiStyles.bgColor.ansi)) {
45923
- if (skipModels.has(model)) {
45924
- continue;
45925
- }
45926
-
45927
- const bgModel = 'bg' + model[0].toUpperCase() + model.slice(1);
45928
- styles[bgModel] = {
45929
- get() {
45930
- const level = this.level;
45931
- return function () {
45932
- const open = ansiStyles.bgColor[levelMapping[level]][model].apply(null, arguments);
45933
- const codes = {
45934
- open,
45935
- close: ansiStyles.bgColor.close,
45936
- closeRe: ansiStyles.bgColor.closeRe
45937
- };
45938
- return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, model);
45939
- };
45940
- }
45941
- };
45942
- }
45943
-
45944
- const proto = Object.defineProperties(() => {}, styles);
45945
-
45946
- function build(_styles, _empty, key) {
45947
- const builder = function () {
45948
- return applyStyle.apply(builder, arguments);
45949
- };
45950
-
45951
- builder._styles = _styles;
45952
- builder._empty = _empty;
45953
-
45954
- const self = this;
45955
-
45956
- Object.defineProperty(builder, 'level', {
45957
- enumerable: true,
45958
- get() {
45959
- return self.level;
45960
- },
45961
- set(level) {
45962
- self.level = level;
45963
- }
45964
- });
45965
-
45966
- Object.defineProperty(builder, 'enabled', {
45967
- enumerable: true,
45968
- get() {
45969
- return self.enabled;
45970
- },
45971
- set(enabled) {
45972
- self.enabled = enabled;
45973
- }
45974
- });
45975
-
45976
- // See below for fix regarding invisible grey/dim combination on Windows
45977
- builder.hasGrey = this.hasGrey || key === 'gray' || key === 'grey';
45978
-
45979
- // `__proto__` is used because we must return a function, but there is
45980
- // no way to create a function with a different prototype
45981
- builder.__proto__ = proto; // eslint-disable-line no-proto
45982
-
45983
- return builder;
45984
- }
45985
-
45986
- function applyStyle() {
45987
- // Support varags, but simply cast to string in case there's only one arg
45988
- const args = arguments;
45989
- const argsLen = args.length;
45990
- let str = String(arguments[0]);
45991
-
45992
- if (argsLen === 0) {
45993
- return '';
45994
- }
45995
-
45996
- if (argsLen > 1) {
45997
- // Don't slice `arguments`, it prevents V8 optimizations
45998
- for (let a = 1; a < argsLen; a++) {
45999
- str += ' ' + args[a];
46000
- }
46001
- }
46002
-
46003
- if (!this.enabled || this.level <= 0 || !str) {
46004
- return this._empty ? '' : str;
46005
- }
46006
-
46007
- // Turns out that on Windows dimmed gray text becomes invisible in cmd.exe,
46008
- // see https://github.com/chalk/chalk/issues/58
46009
- // If we're on Windows and we're dealing with a gray color, temporarily make 'dim' a noop.
46010
- const originalDim = ansiStyles.dim.open;
46011
- if (isSimpleWindowsTerm && this.hasGrey) {
46012
- ansiStyles.dim.open = '';
46013
- }
46014
-
46015
- for (const code of this._styles.slice().reverse()) {
46016
- // Replace any instances already present with a re-opening code
46017
- // otherwise only the part of the string until said closing code
46018
- // will be colored, and the rest will simply be 'plain'.
46019
- str = code.open + str.replace(code.closeRe, code.open) + code.close;
46020
-
46021
- // Close the styling before a linebreak and reopen
46022
- // after next line to fix a bleed issue on macOS
46023
- // https://github.com/chalk/chalk/pull/92
46024
- str = str.replace(/\r?\n/g, `${code.close}$&${code.open}`);
46025
- }
46026
-
46027
- // Reset the original `dim` if we changed it to work around the Windows dimmed gray issue
46028
- ansiStyles.dim.open = originalDim;
46029
-
46030
- return str;
46031
- }
46032
-
46033
- function chalkTag(chalk, strings) {
46034
- if (!Array.isArray(strings)) {
46035
- // If chalk() was called by itself or with a string,
46036
- // return the string itself as a string.
46037
- return [].slice.call(arguments, 1).join(' ');
46038
- }
46039
-
46040
- const args = [].slice.call(arguments, 2);
46041
- const parts = [strings.raw[0]];
46042
-
46043
- for (let i = 1; i < strings.length; i++) {
46044
- parts.push(String(args[i - 1]).replace(/[{}\\]/g, '\\$&'));
46045
- parts.push(String(strings.raw[i]));
46046
- }
46047
-
46048
- return template(chalk, parts.join(''));
44860
+ var __extends = (this && this.__extends) || (function () {
44861
+ var extendStatics = function (d, b) {
44862
+ extendStatics = Object.setPrototypeOf ||
44863
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
44864
+ function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
44865
+ return extendStatics(d, b);
44866
+ }
44867
+ return function (d, b) {
44868
+ extendStatics(d, b);
44869
+ function __() { this.constructor = d; }
44870
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
44871
+ };
44872
+ })();
44873
+ Object.defineProperty(exports, "__esModule", { value: true });
44874
+ var Subscriber_1 = __webpack_require__(223);
44875
+ var Subscription_1 = __webpack_require__(177);
44876
+ var Observable_1 = __webpack_require__(780);
44877
+ var Subject_1 = __webpack_require__(441);
44878
+ function groupBy(keySelector, elementSelector, durationSelector, subjectSelector) {
44879
+ return function (source) {
44880
+ return source.lift(new GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector));
44881
+ };
46049
44882
  }
46050
-
46051
- Object.defineProperties(Chalk.prototype, styles);
46052
-
46053
- module.exports = Chalk(); // eslint-disable-line new-cap
46054
- module.exports.supportsColor = stdoutColor;
46055
- module.exports.default = module.exports; // For TypeScript
46056
-
44883
+ exports.groupBy = groupBy;
44884
+ var GroupByOperator = (function () {
44885
+ function GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector) {
44886
+ this.keySelector = keySelector;
44887
+ this.elementSelector = elementSelector;
44888
+ this.durationSelector = durationSelector;
44889
+ this.subjectSelector = subjectSelector;
44890
+ }
44891
+ GroupByOperator.prototype.call = function (subscriber, source) {
44892
+ return source.subscribe(new GroupBySubscriber(subscriber, this.keySelector, this.elementSelector, this.durationSelector, this.subjectSelector));
44893
+ };
44894
+ return GroupByOperator;
44895
+ }());
44896
+ var GroupBySubscriber = (function (_super) {
44897
+ __extends(GroupBySubscriber, _super);
44898
+ function GroupBySubscriber(destination, keySelector, elementSelector, durationSelector, subjectSelector) {
44899
+ var _this = _super.call(this, destination) || this;
44900
+ _this.keySelector = keySelector;
44901
+ _this.elementSelector = elementSelector;
44902
+ _this.durationSelector = durationSelector;
44903
+ _this.subjectSelector = subjectSelector;
44904
+ _this.groups = null;
44905
+ _this.attemptedToUnsubscribe = false;
44906
+ _this.count = 0;
44907
+ return _this;
44908
+ }
44909
+ GroupBySubscriber.prototype._next = function (value) {
44910
+ var key;
44911
+ try {
44912
+ key = this.keySelector(value);
44913
+ }
44914
+ catch (err) {
44915
+ this.error(err);
44916
+ return;
44917
+ }
44918
+ this._group(value, key);
44919
+ };
44920
+ GroupBySubscriber.prototype._group = function (value, key) {
44921
+ var groups = this.groups;
44922
+ if (!groups) {
44923
+ groups = this.groups = new Map();
44924
+ }
44925
+ var group = groups.get(key);
44926
+ var element;
44927
+ if (this.elementSelector) {
44928
+ try {
44929
+ element = this.elementSelector(value);
44930
+ }
44931
+ catch (err) {
44932
+ this.error(err);
44933
+ }
44934
+ }
44935
+ else {
44936
+ element = value;
44937
+ }
44938
+ if (!group) {
44939
+ group = (this.subjectSelector ? this.subjectSelector() : new Subject_1.Subject());
44940
+ groups.set(key, group);
44941
+ var groupedObservable = new GroupedObservable(key, group, this);
44942
+ this.destination.next(groupedObservable);
44943
+ if (this.durationSelector) {
44944
+ var duration = void 0;
44945
+ try {
44946
+ duration = this.durationSelector(new GroupedObservable(key, group));
44947
+ }
44948
+ catch (err) {
44949
+ this.error(err);
44950
+ return;
44951
+ }
44952
+ this.add(duration.subscribe(new GroupDurationSubscriber(key, group, this)));
44953
+ }
44954
+ }
44955
+ if (!group.closed) {
44956
+ group.next(element);
44957
+ }
44958
+ };
44959
+ GroupBySubscriber.prototype._error = function (err) {
44960
+ var groups = this.groups;
44961
+ if (groups) {
44962
+ groups.forEach(function (group, key) {
44963
+ group.error(err);
44964
+ });
44965
+ groups.clear();
44966
+ }
44967
+ this.destination.error(err);
44968
+ };
44969
+ GroupBySubscriber.prototype._complete = function () {
44970
+ var groups = this.groups;
44971
+ if (groups) {
44972
+ groups.forEach(function (group, key) {
44973
+ group.complete();
44974
+ });
44975
+ groups.clear();
44976
+ }
44977
+ this.destination.complete();
44978
+ };
44979
+ GroupBySubscriber.prototype.removeGroup = function (key) {
44980
+ this.groups.delete(key);
44981
+ };
44982
+ GroupBySubscriber.prototype.unsubscribe = function () {
44983
+ if (!this.closed) {
44984
+ this.attemptedToUnsubscribe = true;
44985
+ if (this.count === 0) {
44986
+ _super.prototype.unsubscribe.call(this);
44987
+ }
44988
+ }
44989
+ };
44990
+ return GroupBySubscriber;
44991
+ }(Subscriber_1.Subscriber));
44992
+ var GroupDurationSubscriber = (function (_super) {
44993
+ __extends(GroupDurationSubscriber, _super);
44994
+ function GroupDurationSubscriber(key, group, parent) {
44995
+ var _this = _super.call(this, group) || this;
44996
+ _this.key = key;
44997
+ _this.group = group;
44998
+ _this.parent = parent;
44999
+ return _this;
45000
+ }
45001
+ GroupDurationSubscriber.prototype._next = function (value) {
45002
+ this.complete();
45003
+ };
45004
+ GroupDurationSubscriber.prototype._unsubscribe = function () {
45005
+ var _a = this, parent = _a.parent, key = _a.key;
45006
+ this.key = this.parent = null;
45007
+ if (parent) {
45008
+ parent.removeGroup(key);
45009
+ }
45010
+ };
45011
+ return GroupDurationSubscriber;
45012
+ }(Subscriber_1.Subscriber));
45013
+ var GroupedObservable = (function (_super) {
45014
+ __extends(GroupedObservable, _super);
45015
+ function GroupedObservable(key, groupSubject, refCountSubscription) {
45016
+ var _this = _super.call(this) || this;
45017
+ _this.key = key;
45018
+ _this.groupSubject = groupSubject;
45019
+ _this.refCountSubscription = refCountSubscription;
45020
+ return _this;
45021
+ }
45022
+ GroupedObservable.prototype._subscribe = function (subscriber) {
45023
+ var subscription = new Subscription_1.Subscription();
45024
+ var _a = this, refCountSubscription = _a.refCountSubscription, groupSubject = _a.groupSubject;
45025
+ if (refCountSubscription && !refCountSubscription.closed) {
45026
+ subscription.add(new InnerRefCountSubscription(refCountSubscription));
45027
+ }
45028
+ subscription.add(groupSubject.subscribe(subscriber));
45029
+ return subscription;
45030
+ };
45031
+ return GroupedObservable;
45032
+ }(Observable_1.Observable));
45033
+ exports.GroupedObservable = GroupedObservable;
45034
+ var InnerRefCountSubscription = (function (_super) {
45035
+ __extends(InnerRefCountSubscription, _super);
45036
+ function InnerRefCountSubscription(parent) {
45037
+ var _this = _super.call(this) || this;
45038
+ _this.parent = parent;
45039
+ parent.count++;
45040
+ return _this;
45041
+ }
45042
+ InnerRefCountSubscription.prototype.unsubscribe = function () {
45043
+ var parent = this.parent;
45044
+ if (!parent.closed && !this.closed) {
45045
+ _super.prototype.unsubscribe.call(this);
45046
+ parent.count -= 1;
45047
+ if (parent.count === 0 && parent.attemptedToUnsubscribe) {
45048
+ parent.unsubscribe();
45049
+ }
45050
+ }
45051
+ };
45052
+ return InnerRefCountSubscription;
45053
+ }(Subscription_1.Subscription));
45054
+ //# sourceMappingURL=groupBy.js.map
46057
45055
 
46058
45056
  /***/ }),
46059
45057
  /* 666 */,
@@ -50053,7 +49051,7 @@ module.exports = class Minipass extends EE {
50053
49051
  const Buffer = __webpack_require__(559)
50054
49052
  const MiniPass = __webpack_require__(715)
50055
49053
  const Pax = __webpack_require__(544)
50056
- const Header = __webpack_require__(660)
49054
+ const Header = __webpack_require__(745)
50057
49055
  const ReadEntry = __webpack_require__(18)
50058
49056
  const fs = __webpack_require__(747)
50059
49057
  const path = __webpack_require__(622)
@@ -51617,137 +50615,153 @@ module.exports = NumberPrompt;
51617
50615
  /***/ }),
51618
50616
  /* 737 */,
51619
50617
  /* 738 */
51620
- /***/ (function(module) {
51621
-
51622
- "use strict";
50618
+ /***/ (function(module, __unusedexports, __webpack_require__) {
51623
50619
 
51624
- const TEMPLATE_REGEX = /(?:\\(u[a-f\d]{4}|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi;
51625
- const STYLE_REGEX = /(?:^|\.)(\w+)(?:\(([^)]*)\))?/g;
51626
- const STRING_REGEX = /^(['"])((?:\\.|(?!\1)[^\\])*)\1$/;
51627
- const ESCAPE_REGEX = /\\(u[a-f\d]{4}|x[a-f\d]{2}|.)|([^\\])/gi;
50620
+ var Stream = __webpack_require__(413)
51628
50621
 
51629
- const ESCAPES = new Map([
51630
- ['n', '\n'],
51631
- ['r', '\r'],
51632
- ['t', '\t'],
51633
- ['b', '\b'],
51634
- ['f', '\f'],
51635
- ['v', '\v'],
51636
- ['0', '\0'],
51637
- ['\\', '\\'],
51638
- ['e', '\u001B'],
51639
- ['a', '\u0007']
51640
- ]);
50622
+ module.exports = MuteStream
51641
50623
 
51642
- function unescape(c) {
51643
- if ((c[0] === 'u' && c.length === 5) || (c[0] === 'x' && c.length === 3)) {
51644
- return String.fromCharCode(parseInt(c.slice(1), 16));
51645
- }
50624
+ // var out = new MuteStream(process.stdout)
50625
+ // argument auto-pipes
50626
+ function MuteStream (opts) {
50627
+ Stream.apply(this)
50628
+ opts = opts || {}
50629
+ this.writable = this.readable = true
50630
+ this.muted = false
50631
+ this.on('pipe', this._onpipe)
50632
+ this.replace = opts.replace
51646
50633
 
51647
- return ESCAPES.get(c) || c;
50634
+ // For readline-type situations
50635
+ // This much at the start of a line being redrawn after a ctrl char
50636
+ // is seen (such as backspace) won't be redrawn as the replacement
50637
+ this._prompt = opts.prompt || null
50638
+ this._hadControl = false
51648
50639
  }
51649
50640
 
51650
- function parseArguments(name, args) {
51651
- const results = [];
51652
- const chunks = args.trim().split(/\s*,\s*/g);
51653
- let matches;
50641
+ MuteStream.prototype = Object.create(Stream.prototype)
51654
50642
 
51655
- for (const chunk of chunks) {
51656
- if (!isNaN(chunk)) {
51657
- results.push(Number(chunk));
51658
- } else if ((matches = chunk.match(STRING_REGEX))) {
51659
- results.push(matches[2].replace(ESCAPE_REGEX, (m, escape, chr) => escape ? unescape(escape) : chr));
51660
- } else {
51661
- throw new Error(`Invalid Chalk template style argument: ${chunk} (in style '${name}')`);
51662
- }
51663
- }
50643
+ Object.defineProperty(MuteStream.prototype, 'constructor', {
50644
+ value: MuteStream,
50645
+ enumerable: false
50646
+ })
51664
50647
 
51665
- return results;
50648
+ MuteStream.prototype.mute = function () {
50649
+ this.muted = true
51666
50650
  }
51667
50651
 
51668
- function parseStyle(style) {
51669
- STYLE_REGEX.lastIndex = 0;
50652
+ MuteStream.prototype.unmute = function () {
50653
+ this.muted = false
50654
+ }
51670
50655
 
51671
- const results = [];
51672
- let matches;
50656
+ Object.defineProperty(MuteStream.prototype, '_onpipe', {
50657
+ value: onPipe,
50658
+ enumerable: false,
50659
+ writable: true,
50660
+ configurable: true
50661
+ })
51673
50662
 
51674
- while ((matches = STYLE_REGEX.exec(style)) !== null) {
51675
- const name = matches[1];
50663
+ function onPipe (src) {
50664
+ this._src = src
50665
+ }
51676
50666
 
51677
- if (matches[2]) {
51678
- const args = parseArguments(name, matches[2]);
51679
- results.push([name].concat(args));
51680
- } else {
51681
- results.push([name]);
51682
- }
51683
- }
50667
+ Object.defineProperty(MuteStream.prototype, 'isTTY', {
50668
+ get: getIsTTY,
50669
+ set: setIsTTY,
50670
+ enumerable: true,
50671
+ configurable: true
50672
+ })
51684
50673
 
51685
- return results;
50674
+ function getIsTTY () {
50675
+ return( (this._dest) ? this._dest.isTTY
50676
+ : (this._src) ? this._src.isTTY
50677
+ : false
50678
+ )
51686
50679
  }
51687
50680
 
51688
- function buildStyle(chalk, styles) {
51689
- const enabled = {};
50681
+ // basically just get replace the getter/setter with a regular value
50682
+ function setIsTTY (isTTY) {
50683
+ Object.defineProperty(this, 'isTTY', {
50684
+ value: isTTY,
50685
+ enumerable: true,
50686
+ writable: true,
50687
+ configurable: true
50688
+ })
50689
+ }
51690
50690
 
51691
- for (const layer of styles) {
51692
- for (const style of layer.styles) {
51693
- enabled[style[0]] = layer.inverse ? null : style.slice(1);
51694
- }
51695
- }
50691
+ Object.defineProperty(MuteStream.prototype, 'rows', {
50692
+ get: function () {
50693
+ return( this._dest ? this._dest.rows
50694
+ : this._src ? this._src.rows
50695
+ : undefined )
50696
+ }, enumerable: true, configurable: true })
51696
50697
 
51697
- let current = chalk;
51698
- for (const styleName of Object.keys(enabled)) {
51699
- if (Array.isArray(enabled[styleName])) {
51700
- if (!(styleName in current)) {
51701
- throw new Error(`Unknown Chalk style: ${styleName}`);
51702
- }
50698
+ Object.defineProperty(MuteStream.prototype, 'columns', {
50699
+ get: function () {
50700
+ return( this._dest ? this._dest.columns
50701
+ : this._src ? this._src.columns
50702
+ : undefined )
50703
+ }, enumerable: true, configurable: true })
51703
50704
 
51704
- if (enabled[styleName].length > 0) {
51705
- current = current[styleName].apply(current, enabled[styleName]);
51706
- } else {
51707
- current = current[styleName];
51708
- }
51709
- }
51710
- }
51711
50705
 
51712
- return current;
50706
+ MuteStream.prototype.pipe = function (dest, options) {
50707
+ this._dest = dest
50708
+ return Stream.prototype.pipe.call(this, dest, options)
51713
50709
  }
51714
50710
 
51715
- module.exports = (chalk, tmp) => {
51716
- const styles = [];
51717
- const chunks = [];
51718
- let chunk = [];
50711
+ MuteStream.prototype.pause = function () {
50712
+ if (this._src) return this._src.pause()
50713
+ }
51719
50714
 
51720
- // eslint-disable-next-line max-params
51721
- tmp.replace(TEMPLATE_REGEX, (m, escapeChar, inverse, style, close, chr) => {
51722
- if (escapeChar) {
51723
- chunk.push(unescape(escapeChar));
51724
- } else if (style) {
51725
- const str = chunk.join('');
51726
- chunk = [];
51727
- chunks.push(styles.length === 0 ? str : buildStyle(chalk, styles)(str));
51728
- styles.push({inverse, styles: parseStyle(style)});
51729
- } else if (close) {
51730
- if (styles.length === 0) {
51731
- throw new Error('Found extraneous } in Chalk template literal');
51732
- }
50715
+ MuteStream.prototype.resume = function () {
50716
+ if (this._src) return this._src.resume()
50717
+ }
51733
50718
 
51734
- chunks.push(buildStyle(chalk, styles)(chunk.join('')));
51735
- chunk = [];
51736
- styles.pop();
51737
- } else {
51738
- chunk.push(chr);
51739
- }
51740
- });
50719
+ MuteStream.prototype.write = function (c) {
50720
+ if (this.muted) {
50721
+ if (!this.replace) return true
50722
+ if (c.match(/^\u001b/)) {
50723
+ if(c.indexOf(this._prompt) === 0) {
50724
+ c = c.substr(this._prompt.length);
50725
+ c = c.replace(/./g, this.replace);
50726
+ c = this._prompt + c;
50727
+ }
50728
+ this._hadControl = true
50729
+ return this.emit('data', c)
50730
+ } else {
50731
+ if (this._prompt && this._hadControl &&
50732
+ c.indexOf(this._prompt) === 0) {
50733
+ this._hadControl = false
50734
+ this.emit('data', this._prompt)
50735
+ c = c.substr(this._prompt.length)
50736
+ }
50737
+ c = c.toString().replace(/./g, this.replace)
50738
+ }
50739
+ }
50740
+ this.emit('data', c)
50741
+ }
51741
50742
 
51742
- chunks.push(chunk.join(''));
50743
+ MuteStream.prototype.end = function (c) {
50744
+ if (this.muted) {
50745
+ if (c && this.replace) {
50746
+ c = c.toString().replace(/./g, this.replace)
50747
+ } else {
50748
+ c = null
50749
+ }
50750
+ }
50751
+ if (c) this.emit('data', c)
50752
+ this.emit('end')
50753
+ }
51743
50754
 
51744
- if (styles.length > 0) {
51745
- const errMsg = `Chalk template literal is missing ${styles.length} closing bracket${styles.length === 1 ? '' : 's'} (\`}\`)`;
51746
- throw new Error(errMsg);
51747
- }
50755
+ function proxy (fn) { return function () {
50756
+ var d = this._dest
50757
+ var s = this._src
50758
+ if (d && d[fn]) d[fn].apply(d, arguments)
50759
+ if (s && s[fn]) s[fn].apply(s, arguments)
50760
+ }}
51748
50761
 
51749
- return chunks.join('');
51750
- };
50762
+ MuteStream.prototype.destroy = proxy('destroy')
50763
+ MuteStream.prototype.destroySoon = proxy('destroySoon')
50764
+ MuteStream.prototype.close = proxy('close')
51751
50765
 
51752
50766
 
51753
50767
  /***/ }),
@@ -52383,25 +51397,294 @@ exports.concatAll = concatAll;
52383
51397
 
52384
51398
  "use strict";
52385
51399
 
52386
- const chalk = __webpack_require__(665);
51400
+ // parse a 512-byte header block to a data object, or vice-versa
51401
+ // encode returns `true` if a pax extended header is needed, because
51402
+ // the data could not be faithfully encoded in a simple header.
51403
+ // (Also, check header.needPax to see if it needs a pax header.)
52387
51404
 
52388
- const isSupported = process.platform !== 'win32' || process.env.CI || process.env.TERM === 'xterm-256color';
51405
+ const Buffer = __webpack_require__(559)
51406
+ const types = __webpack_require__(590)
51407
+ const pathModule = __webpack_require__(622).posix
51408
+ const large = __webpack_require__(200)
52389
51409
 
52390
- const main = {
52391
- info: chalk.blue(''),
52392
- success: chalk.green('✔'),
52393
- warning: chalk.yellow('⚠'),
52394
- error: chalk.red('✖')
52395
- };
51410
+ const SLURP = Symbol('slurp')
51411
+ const TYPE = Symbol('type')
52396
51412
 
52397
- const fallbacks = {
52398
- info: chalk.blue('i'),
52399
- success: chalk.green('√'),
52400
- warning: chalk.yellow('‼'),
52401
- error: chalk.red('×')
52402
- };
51413
+ class Header {
51414
+ constructor (data, off, ex, gex) {
51415
+ this.cksumValid = false
51416
+ this.needPax = false
51417
+ this.nullBlock = false
52403
51418
 
52404
- module.exports = isSupported ? main : fallbacks;
51419
+ this.block = null
51420
+ this.path = null
51421
+ this.mode = null
51422
+ this.uid = null
51423
+ this.gid = null
51424
+ this.size = null
51425
+ this.mtime = null
51426
+ this.cksum = null
51427
+ this[TYPE] = '0'
51428
+ this.linkpath = null
51429
+ this.uname = null
51430
+ this.gname = null
51431
+ this.devmaj = 0
51432
+ this.devmin = 0
51433
+ this.atime = null
51434
+ this.ctime = null
51435
+
51436
+ if (Buffer.isBuffer(data))
51437
+ this.decode(data, off || 0, ex, gex)
51438
+ else if (data)
51439
+ this.set(data)
51440
+ }
51441
+
51442
+ decode (buf, off, ex, gex) {
51443
+ if (!off)
51444
+ off = 0
51445
+
51446
+ if (!buf || !(buf.length >= off + 512))
51447
+ throw new Error('need 512 bytes for header')
51448
+
51449
+ this.path = decString(buf, off, 100)
51450
+ this.mode = decNumber(buf, off + 100, 8)
51451
+ this.uid = decNumber(buf, off + 108, 8)
51452
+ this.gid = decNumber(buf, off + 116, 8)
51453
+ this.size = decNumber(buf, off + 124, 12)
51454
+ this.mtime = decDate(buf, off + 136, 12)
51455
+ this.cksum = decNumber(buf, off + 148, 12)
51456
+
51457
+ // if we have extended or global extended headers, apply them now
51458
+ // See https://github.com/npm/node-tar/pull/187
51459
+ this[SLURP](ex)
51460
+ this[SLURP](gex, true)
51461
+
51462
+ // old tar versions marked dirs as a file with a trailing /
51463
+ this[TYPE] = decString(buf, off + 156, 1)
51464
+ if (this[TYPE] === '')
51465
+ this[TYPE] = '0'
51466
+ if (this[TYPE] === '0' && this.path.substr(-1) === '/')
51467
+ this[TYPE] = '5'
51468
+
51469
+ // tar implementations sometimes incorrectly put the stat(dir).size
51470
+ // as the size in the tarball, even though Directory entries are
51471
+ // not able to have any body at all. In the very rare chance that
51472
+ // it actually DOES have a body, we weren't going to do anything with
51473
+ // it anyway, and it'll just be a warning about an invalid header.
51474
+ if (this[TYPE] === '5')
51475
+ this.size = 0
51476
+
51477
+ this.linkpath = decString(buf, off + 157, 100)
51478
+ if (buf.slice(off + 257, off + 265).toString() === 'ustar\u000000') {
51479
+ this.uname = decString(buf, off + 265, 32)
51480
+ this.gname = decString(buf, off + 297, 32)
51481
+ this.devmaj = decNumber(buf, off + 329, 8)
51482
+ this.devmin = decNumber(buf, off + 337, 8)
51483
+ if (buf[off + 475] !== 0) {
51484
+ // definitely a prefix, definitely >130 chars.
51485
+ const prefix = decString(buf, off + 345, 155)
51486
+ this.path = prefix + '/' + this.path
51487
+ } else {
51488
+ const prefix = decString(buf, off + 345, 130)
51489
+ if (prefix)
51490
+ this.path = prefix + '/' + this.path
51491
+ this.atime = decDate(buf, off + 476, 12)
51492
+ this.ctime = decDate(buf, off + 488, 12)
51493
+ }
51494
+ }
51495
+
51496
+ let sum = 8 * 0x20
51497
+ for (let i = off; i < off + 148; i++) {
51498
+ sum += buf[i]
51499
+ }
51500
+ for (let i = off + 156; i < off + 512; i++) {
51501
+ sum += buf[i]
51502
+ }
51503
+ this.cksumValid = sum === this.cksum
51504
+ if (this.cksum === null && sum === 8 * 0x20)
51505
+ this.nullBlock = true
51506
+ }
51507
+
51508
+ [SLURP] (ex, global) {
51509
+ for (let k in ex) {
51510
+ // we slurp in everything except for the path attribute in
51511
+ // a global extended header, because that's weird.
51512
+ if (ex[k] !== null && ex[k] !== undefined &&
51513
+ !(global && k === 'path'))
51514
+ this[k] = ex[k]
51515
+ }
51516
+ }
51517
+
51518
+ encode (buf, off) {
51519
+ if (!buf) {
51520
+ buf = this.block = Buffer.alloc(512)
51521
+ off = 0
51522
+ }
51523
+
51524
+ if (!off)
51525
+ off = 0
51526
+
51527
+ if (!(buf.length >= off + 512))
51528
+ throw new Error('need 512 bytes for header')
51529
+
51530
+ const prefixSize = this.ctime || this.atime ? 130 : 155
51531
+ const split = splitPrefix(this.path || '', prefixSize)
51532
+ const path = split[0]
51533
+ const prefix = split[1]
51534
+ this.needPax = split[2]
51535
+
51536
+ this.needPax = encString(buf, off, 100, path) || this.needPax
51537
+ this.needPax = encNumber(buf, off + 100, 8, this.mode) || this.needPax
51538
+ this.needPax = encNumber(buf, off + 108, 8, this.uid) || this.needPax
51539
+ this.needPax = encNumber(buf, off + 116, 8, this.gid) || this.needPax
51540
+ this.needPax = encNumber(buf, off + 124, 12, this.size) || this.needPax
51541
+ this.needPax = encDate(buf, off + 136, 12, this.mtime) || this.needPax
51542
+ buf[off + 156] = this[TYPE].charCodeAt(0)
51543
+ this.needPax = encString(buf, off + 157, 100, this.linkpath) || this.needPax
51544
+ buf.write('ustar\u000000', off + 257, 8)
51545
+ this.needPax = encString(buf, off + 265, 32, this.uname) || this.needPax
51546
+ this.needPax = encString(buf, off + 297, 32, this.gname) || this.needPax
51547
+ this.needPax = encNumber(buf, off + 329, 8, this.devmaj) || this.needPax
51548
+ this.needPax = encNumber(buf, off + 337, 8, this.devmin) || this.needPax
51549
+ this.needPax = encString(buf, off + 345, prefixSize, prefix) || this.needPax
51550
+ if (buf[off + 475] !== 0)
51551
+ this.needPax = encString(buf, off + 345, 155, prefix) || this.needPax
51552
+ else {
51553
+ this.needPax = encString(buf, off + 345, 130, prefix) || this.needPax
51554
+ this.needPax = encDate(buf, off + 476, 12, this.atime) || this.needPax
51555
+ this.needPax = encDate(buf, off + 488, 12, this.ctime) || this.needPax
51556
+ }
51557
+
51558
+ let sum = 8 * 0x20
51559
+ for (let i = off; i < off + 148; i++) {
51560
+ sum += buf[i]
51561
+ }
51562
+ for (let i = off + 156; i < off + 512; i++) {
51563
+ sum += buf[i]
51564
+ }
51565
+ this.cksum = sum
51566
+ encNumber(buf, off + 148, 8, this.cksum)
51567
+ this.cksumValid = true
51568
+
51569
+ return this.needPax
51570
+ }
51571
+
51572
+ set (data) {
51573
+ for (let i in data) {
51574
+ if (data[i] !== null && data[i] !== undefined)
51575
+ this[i] = data[i]
51576
+ }
51577
+ }
51578
+
51579
+ get type () {
51580
+ return types.name.get(this[TYPE]) || this[TYPE]
51581
+ }
51582
+
51583
+ get typeKey () {
51584
+ return this[TYPE]
51585
+ }
51586
+
51587
+ set type (type) {
51588
+ if (types.code.has(type))
51589
+ this[TYPE] = types.code.get(type)
51590
+ else
51591
+ this[TYPE] = type
51592
+ }
51593
+ }
51594
+
51595
+ const splitPrefix = (p, prefixSize) => {
51596
+ const pathSize = 100
51597
+ let pp = p
51598
+ let prefix = ''
51599
+ let ret
51600
+ const root = pathModule.parse(p).root || '.'
51601
+
51602
+ if (Buffer.byteLength(pp) < pathSize)
51603
+ ret = [pp, prefix, false]
51604
+ else {
51605
+ // first set prefix to the dir, and path to the base
51606
+ prefix = pathModule.dirname(pp)
51607
+ pp = pathModule.basename(pp)
51608
+
51609
+ do {
51610
+ // both fit!
51611
+ if (Buffer.byteLength(pp) <= pathSize &&
51612
+ Buffer.byteLength(prefix) <= prefixSize)
51613
+ ret = [pp, prefix, false]
51614
+
51615
+ // prefix fits in prefix, but path doesn't fit in path
51616
+ else if (Buffer.byteLength(pp) > pathSize &&
51617
+ Buffer.byteLength(prefix) <= prefixSize)
51618
+ ret = [pp.substr(0, pathSize - 1), prefix, true]
51619
+
51620
+ else {
51621
+ // make path take a bit from prefix
51622
+ pp = pathModule.join(pathModule.basename(prefix), pp)
51623
+ prefix = pathModule.dirname(prefix)
51624
+ }
51625
+ } while (prefix !== root && !ret)
51626
+
51627
+ // at this point, found no resolution, just truncate
51628
+ if (!ret)
51629
+ ret = [p.substr(0, pathSize - 1), '', true]
51630
+ }
51631
+ return ret
51632
+ }
51633
+
51634
+ const decString = (buf, off, size) =>
51635
+ buf.slice(off, off + size).toString('utf8').replace(/\0.*/, '')
51636
+
51637
+ const decDate = (buf, off, size) =>
51638
+ numToDate(decNumber(buf, off, size))
51639
+
51640
+ const numToDate = num => num === null ? null : new Date(num * 1000)
51641
+
51642
+ const decNumber = (buf, off, size) =>
51643
+ buf[off] & 0x80 ? large.parse(buf.slice(off, off + size))
51644
+ : decSmallNumber(buf, off, size)
51645
+
51646
+ const nanNull = value => isNaN(value) ? null : value
51647
+
51648
+ const decSmallNumber = (buf, off, size) =>
51649
+ nanNull(parseInt(
51650
+ buf.slice(off, off + size)
51651
+ .toString('utf8').replace(/\0.*$/, '').trim(), 8))
51652
+
51653
+ // the maximum encodable as a null-terminated octal, by field size
51654
+ const MAXNUM = {
51655
+ 12: 0o77777777777,
51656
+ 8 : 0o7777777
51657
+ }
51658
+
51659
+ const encNumber = (buf, off, size, number) =>
51660
+ number === null ? false :
51661
+ number > MAXNUM[size] || number < 0
51662
+ ? (large.encode(number, buf.slice(off, off + size)), true)
51663
+ : (encSmallNumber(buf, off, size, number), false)
51664
+
51665
+ const encSmallNumber = (buf, off, size, number) =>
51666
+ buf.write(octalString(number, size), off, size, 'ascii')
51667
+
51668
+ const octalString = (number, size) =>
51669
+ padOctal(Math.floor(number).toString(8), size)
51670
+
51671
+ const padOctal = (string, size) =>
51672
+ (string.length === size - 1 ? string
51673
+ : new Array(size - string.length - 1).join('0') + string + ' ') + '\0'
51674
+
51675
+ const encDate = (buf, off, size, date) =>
51676
+ date === null ? false :
51677
+ encNumber(buf, off, size, date.getTime() / 1000)
51678
+
51679
+ // enough to fill the longest string we've got
51680
+ const NULLS = new Array(156).join('\0')
51681
+ // pad with nulls, return true if it's longer or non-ascii
51682
+ const encString = (buf, off, size, string) =>
51683
+ string === null ? false :
51684
+ (buf.write(string + NULLS, off, size, 'utf8'),
51685
+ string.length !== Buffer.byteLength(string) || string.length > size)
51686
+
51687
+ module.exports = Header
52405
51688
 
52406
51689
 
52407
51690
  /***/ }),
@@ -52745,7 +52028,7 @@ module.exports = ConfirmPrompt;
52745
52028
  // Node 8 supports native async functions - no need to use compiled code!
52746
52029
  module.exports =
52747
52030
  parseInt(process.versions.node, 10) < 8
52748
- ? __webpack_require__(275)
52031
+ ? __webpack_require__(94)
52749
52032
  : __webpack_require__(839);
52750
52033
 
52751
52034
 
@@ -53132,7 +52415,7 @@ var subscribeToPromise_1 = __webpack_require__(487);
53132
52415
  var subscribeToIterable_1 = __webpack_require__(818);
53133
52416
  var subscribeToObservable_1 = __webpack_require__(2);
53134
52417
  var isArrayLike_1 = __webpack_require__(936);
53135
- var isPromise_1 = __webpack_require__(174);
52418
+ var isPromise_1 = __webpack_require__(275);
53136
52419
  var isObject_1 = __webpack_require__(306);
53137
52420
  var iterator_1 = __webpack_require__(330);
53138
52421
  var observable_1 = __webpack_require__(620);
@@ -53180,7 +52463,7 @@ exports.Unpack = __webpack_require__(650)
53180
52463
  exports.Parse = __webpack_require__(277)
53181
52464
  exports.ReadEntry = __webpack_require__(18)
53182
52465
  exports.WriteEntry = __webpack_require__(716)
53183
- exports.Header = __webpack_require__(660)
52466
+ exports.Header = __webpack_require__(745)
53184
52467
  exports.Pax = __webpack_require__(544)
53185
52468
  exports.types = __webpack_require__(590)
53186
52469
 
@@ -56329,256 +55612,29 @@ var WithLatestFromSubscriber = (function (_super) {
56329
55612
  /* 843 */,
56330
55613
  /* 844 */,
56331
55614
  /* 845 */
56332
- /***/ (function(module, exports, __webpack_require__) {
56333
-
56334
- /**
56335
- * Module dependencies.
56336
- */
56337
-
56338
- var tty = __webpack_require__(30);
56339
- var util = __webpack_require__(669);
56340
-
56341
- /**
56342
- * This is the Node.js implementation of `debug()`.
56343
- *
56344
- * Expose `debug()` as the module.
56345
- */
56346
-
56347
- exports = module.exports = __webpack_require__(271);
56348
- exports.init = init;
56349
- exports.log = log;
56350
- exports.formatArgs = formatArgs;
56351
- exports.save = save;
56352
- exports.load = load;
56353
- exports.useColors = useColors;
56354
-
56355
- /**
56356
- * Colors.
56357
- */
56358
-
56359
- exports.colors = [6, 2, 3, 4, 5, 1];
56360
-
56361
- /**
56362
- * Build up the default `inspectOpts` object from the environment variables.
56363
- *
56364
- * $ DEBUG_COLORS=no DEBUG_DEPTH=10 DEBUG_SHOW_HIDDEN=enabled node script.js
56365
- */
56366
-
56367
- exports.inspectOpts = Object.keys(process.env).filter(function (key) {
56368
- return /^debug_/i.test(key);
56369
- }).reduce(function (obj, key) {
56370
- // camel-case
56371
- var prop = key
56372
- .substring(6)
56373
- .toLowerCase()
56374
- .replace(/_([a-z])/g, function (_, k) { return k.toUpperCase() });
56375
-
56376
- // coerce string value into JS value
56377
- var val = process.env[key];
56378
- if (/^(yes|on|true|enabled)$/i.test(val)) val = true;
56379
- else if (/^(no|off|false|disabled)$/i.test(val)) val = false;
56380
- else if (val === 'null') val = null;
56381
- else val = Number(val);
56382
-
56383
- obj[prop] = val;
56384
- return obj;
56385
- }, {});
56386
-
56387
- /**
56388
- * The file descriptor to write the `debug()` calls to.
56389
- * Set the `DEBUG_FD` env variable to override with another value. i.e.:
56390
- *
56391
- * $ DEBUG_FD=3 node script.js 3>debug.log
56392
- */
56393
-
56394
- var fd = parseInt(process.env.DEBUG_FD, 10) || 2;
56395
-
56396
- if (1 !== fd && 2 !== fd) {
56397
- util.deprecate(function(){}, 'except for stderr(2) and stdout(1), any other usage of DEBUG_FD is deprecated. Override debug.log if you want to use a different log function (https://git.io/debug_fd)')()
56398
- }
56399
-
56400
- var stream = 1 === fd ? process.stdout :
56401
- 2 === fd ? process.stderr :
56402
- createWritableStdioStream(fd);
55615
+ /***/ (function(module, __unusedexports, __webpack_require__) {
56403
55616
 
56404
- /**
56405
- * Is stdout a TTY? Colored output is enabled when `true`.
56406
- */
55617
+ "use strict";
56407
55618
 
56408
- function useColors() {
56409
- return 'colors' in exports.inspectOpts
56410
- ? Boolean(exports.inspectOpts.colors)
56411
- : tty.isatty(fd);
56412
- }
55619
+ const chalk = __webpack_require__(860);
56413
55620
 
56414
- /**
56415
- * Map %o to `util.inspect()`, all on a single line.
56416
- */
55621
+ const isSupported = process.platform !== 'win32' || process.env.CI || process.env.TERM === 'xterm-256color';
56417
55622
 
56418
- exports.formatters.o = function(v) {
56419
- this.inspectOpts.colors = this.useColors;
56420
- return util.inspect(v, this.inspectOpts)
56421
- .split('\n').map(function(str) {
56422
- return str.trim()
56423
- }).join(' ');
55623
+ const main = {
55624
+ info: chalk.blue('ℹ'),
55625
+ success: chalk.green('✔'),
55626
+ warning: chalk.yellow(''),
55627
+ error: chalk.red('✖')
56424
55628
  };
56425
55629
 
56426
- /**
56427
- * Map %o to `util.inspect()`, allowing multiple lines if needed.
56428
- */
56429
-
56430
- exports.formatters.O = function(v) {
56431
- this.inspectOpts.colors = this.useColors;
56432
- return util.inspect(v, this.inspectOpts);
55630
+ const fallbacks = {
55631
+ info: chalk.blue('i'),
55632
+ success: chalk.green('√'),
55633
+ warning: chalk.yellow('‼'),
55634
+ error: chalk.red('×')
56433
55635
  };
56434
55636
 
56435
- /**
56436
- * Adds ANSI color escape codes if enabled.
56437
- *
56438
- * @api public
56439
- */
56440
-
56441
- function formatArgs(args) {
56442
- var name = this.namespace;
56443
- var useColors = this.useColors;
56444
-
56445
- if (useColors) {
56446
- var c = this.color;
56447
- var prefix = ' \u001b[3' + c + ';1m' + name + ' ' + '\u001b[0m';
56448
-
56449
- args[0] = prefix + args[0].split('\n').join('\n' + prefix);
56450
- args.push('\u001b[3' + c + 'm+' + exports.humanize(this.diff) + '\u001b[0m');
56451
- } else {
56452
- args[0] = new Date().toUTCString()
56453
- + ' ' + name + ' ' + args[0];
56454
- }
56455
- }
56456
-
56457
- /**
56458
- * Invokes `util.format()` with the specified arguments and writes to `stream`.
56459
- */
56460
-
56461
- function log() {
56462
- return stream.write(util.format.apply(util, arguments) + '\n');
56463
- }
56464
-
56465
- /**
56466
- * Save `namespaces`.
56467
- *
56468
- * @param {String} namespaces
56469
- * @api private
56470
- */
56471
-
56472
- function save(namespaces) {
56473
- if (null == namespaces) {
56474
- // If you set a process.env field to null or undefined, it gets cast to the
56475
- // string 'null' or 'undefined'. Just delete instead.
56476
- delete process.env.DEBUG;
56477
- } else {
56478
- process.env.DEBUG = namespaces;
56479
- }
56480
- }
56481
-
56482
- /**
56483
- * Load `namespaces`.
56484
- *
56485
- * @return {String} returns the previously persisted debug modes
56486
- * @api private
56487
- */
56488
-
56489
- function load() {
56490
- return process.env.DEBUG;
56491
- }
56492
-
56493
- /**
56494
- * Copied from `node/src/node.js`.
56495
- *
56496
- * XXX: It's lame that node doesn't expose this API out-of-the-box. It also
56497
- * relies on the undocumented `tty_wrap.guessHandleType()` which is also lame.
56498
- */
56499
-
56500
- function createWritableStdioStream (fd) {
56501
- var stream;
56502
- var tty_wrap = process.binding('tty_wrap');
56503
-
56504
- // Note stream._type is used for test-module-load-list.js
56505
-
56506
- switch (tty_wrap.guessHandleType(fd)) {
56507
- case 'TTY':
56508
- stream = new tty.WriteStream(fd);
56509
- stream._type = 'tty';
56510
-
56511
- // Hack to have stream not keep the event loop alive.
56512
- // See https://github.com/joyent/node/issues/1726
56513
- if (stream._handle && stream._handle.unref) {
56514
- stream._handle.unref();
56515
- }
56516
- break;
56517
-
56518
- case 'FILE':
56519
- var fs = __webpack_require__(747);
56520
- stream = new fs.SyncWriteStream(fd, { autoClose: false });
56521
- stream._type = 'fs';
56522
- break;
56523
-
56524
- case 'PIPE':
56525
- case 'TCP':
56526
- var net = __webpack_require__(60);
56527
- stream = new net.Socket({
56528
- fd: fd,
56529
- readable: false,
56530
- writable: true
56531
- });
56532
-
56533
- // FIXME Should probably have an option in net.Socket to create a
56534
- // stream from an existing fd which is writable only. But for now
56535
- // we'll just add this hack and set the `readable` member to false.
56536
- // Test: ./node test/fixtures/echo.js < /etc/passwd
56537
- stream.readable = false;
56538
- stream.read = null;
56539
- stream._type = 'pipe';
56540
-
56541
- // FIXME Hack to have stream not keep the event loop alive.
56542
- // See https://github.com/joyent/node/issues/1726
56543
- if (stream._handle && stream._handle.unref) {
56544
- stream._handle.unref();
56545
- }
56546
- break;
56547
-
56548
- default:
56549
- // Probably an error on in uv_guess_handle()
56550
- throw new Error('Implement me. Unknown stream file type!');
56551
- }
56552
-
56553
- // For supporting legacy API we put the FD here.
56554
- stream.fd = fd;
56555
-
56556
- stream._isStdio = true;
56557
-
56558
- return stream;
56559
- }
56560
-
56561
- /**
56562
- * Init logic for `debug` instances.
56563
- *
56564
- * Create a new `inspectOpts` object in case `useColors` is set
56565
- * differently for a particular `debug` instance.
56566
- */
56567
-
56568
- function init (debug) {
56569
- debug.inspectOpts = {};
56570
-
56571
- var keys = Object.keys(exports.inspectOpts);
56572
- for (var i = 0; i < keys.length; i++) {
56573
- debug.inspectOpts[keys[i]] = exports.inspectOpts[keys[i]];
56574
- }
56575
- }
56576
-
56577
- /**
56578
- * Enable namespaces listed in `process.env.DEBUG` initially.
56579
- */
56580
-
56581
- exports.enable(load());
55637
+ module.exports = isSupported ? main : fallbacks;
56582
55638
 
56583
55639
 
56584
55640
  /***/ }),
@@ -57949,7 +57005,260 @@ const extract = opt => {
57949
57005
  /* 872 */,
57950
57006
  /* 873 */,
57951
57007
  /* 874 */,
57952
- /* 875 */,
57008
+ /* 875 */
57009
+ /***/ (function(module, exports, __webpack_require__) {
57010
+
57011
+ /**
57012
+ * Module dependencies.
57013
+ */
57014
+
57015
+ var tty = __webpack_require__(30);
57016
+ var util = __webpack_require__(669);
57017
+
57018
+ /**
57019
+ * This is the Node.js implementation of `debug()`.
57020
+ *
57021
+ * Expose `debug()` as the module.
57022
+ */
57023
+
57024
+ exports = module.exports = __webpack_require__(271);
57025
+ exports.init = init;
57026
+ exports.log = log;
57027
+ exports.formatArgs = formatArgs;
57028
+ exports.save = save;
57029
+ exports.load = load;
57030
+ exports.useColors = useColors;
57031
+
57032
+ /**
57033
+ * Colors.
57034
+ */
57035
+
57036
+ exports.colors = [6, 2, 3, 4, 5, 1];
57037
+
57038
+ /**
57039
+ * Build up the default `inspectOpts` object from the environment variables.
57040
+ *
57041
+ * $ DEBUG_COLORS=no DEBUG_DEPTH=10 DEBUG_SHOW_HIDDEN=enabled node script.js
57042
+ */
57043
+
57044
+ exports.inspectOpts = Object.keys(process.env).filter(function (key) {
57045
+ return /^debug_/i.test(key);
57046
+ }).reduce(function (obj, key) {
57047
+ // camel-case
57048
+ var prop = key
57049
+ .substring(6)
57050
+ .toLowerCase()
57051
+ .replace(/_([a-z])/g, function (_, k) { return k.toUpperCase() });
57052
+
57053
+ // coerce string value into JS value
57054
+ var val = process.env[key];
57055
+ if (/^(yes|on|true|enabled)$/i.test(val)) val = true;
57056
+ else if (/^(no|off|false|disabled)$/i.test(val)) val = false;
57057
+ else if (val === 'null') val = null;
57058
+ else val = Number(val);
57059
+
57060
+ obj[prop] = val;
57061
+ return obj;
57062
+ }, {});
57063
+
57064
+ /**
57065
+ * The file descriptor to write the `debug()` calls to.
57066
+ * Set the `DEBUG_FD` env variable to override with another value. i.e.:
57067
+ *
57068
+ * $ DEBUG_FD=3 node script.js 3>debug.log
57069
+ */
57070
+
57071
+ var fd = parseInt(process.env.DEBUG_FD, 10) || 2;
57072
+
57073
+ if (1 !== fd && 2 !== fd) {
57074
+ util.deprecate(function(){}, 'except for stderr(2) and stdout(1), any other usage of DEBUG_FD is deprecated. Override debug.log if you want to use a different log function (https://git.io/debug_fd)')()
57075
+ }
57076
+
57077
+ var stream = 1 === fd ? process.stdout :
57078
+ 2 === fd ? process.stderr :
57079
+ createWritableStdioStream(fd);
57080
+
57081
+ /**
57082
+ * Is stdout a TTY? Colored output is enabled when `true`.
57083
+ */
57084
+
57085
+ function useColors() {
57086
+ return 'colors' in exports.inspectOpts
57087
+ ? Boolean(exports.inspectOpts.colors)
57088
+ : tty.isatty(fd);
57089
+ }
57090
+
57091
+ /**
57092
+ * Map %o to `util.inspect()`, all on a single line.
57093
+ */
57094
+
57095
+ exports.formatters.o = function(v) {
57096
+ this.inspectOpts.colors = this.useColors;
57097
+ return util.inspect(v, this.inspectOpts)
57098
+ .split('\n').map(function(str) {
57099
+ return str.trim()
57100
+ }).join(' ');
57101
+ };
57102
+
57103
+ /**
57104
+ * Map %o to `util.inspect()`, allowing multiple lines if needed.
57105
+ */
57106
+
57107
+ exports.formatters.O = function(v) {
57108
+ this.inspectOpts.colors = this.useColors;
57109
+ return util.inspect(v, this.inspectOpts);
57110
+ };
57111
+
57112
+ /**
57113
+ * Adds ANSI color escape codes if enabled.
57114
+ *
57115
+ * @api public
57116
+ */
57117
+
57118
+ function formatArgs(args) {
57119
+ var name = this.namespace;
57120
+ var useColors = this.useColors;
57121
+
57122
+ if (useColors) {
57123
+ var c = this.color;
57124
+ var prefix = ' \u001b[3' + c + ';1m' + name + ' ' + '\u001b[0m';
57125
+
57126
+ args[0] = prefix + args[0].split('\n').join('\n' + prefix);
57127
+ args.push('\u001b[3' + c + 'm+' + exports.humanize(this.diff) + '\u001b[0m');
57128
+ } else {
57129
+ args[0] = new Date().toUTCString()
57130
+ + ' ' + name + ' ' + args[0];
57131
+ }
57132
+ }
57133
+
57134
+ /**
57135
+ * Invokes `util.format()` with the specified arguments and writes to `stream`.
57136
+ */
57137
+
57138
+ function log() {
57139
+ return stream.write(util.format.apply(util, arguments) + '\n');
57140
+ }
57141
+
57142
+ /**
57143
+ * Save `namespaces`.
57144
+ *
57145
+ * @param {String} namespaces
57146
+ * @api private
57147
+ */
57148
+
57149
+ function save(namespaces) {
57150
+ if (null == namespaces) {
57151
+ // If you set a process.env field to null or undefined, it gets cast to the
57152
+ // string 'null' or 'undefined'. Just delete instead.
57153
+ delete process.env.DEBUG;
57154
+ } else {
57155
+ process.env.DEBUG = namespaces;
57156
+ }
57157
+ }
57158
+
57159
+ /**
57160
+ * Load `namespaces`.
57161
+ *
57162
+ * @return {String} returns the previously persisted debug modes
57163
+ * @api private
57164
+ */
57165
+
57166
+ function load() {
57167
+ return process.env.DEBUG;
57168
+ }
57169
+
57170
+ /**
57171
+ * Copied from `node/src/node.js`.
57172
+ *
57173
+ * XXX: It's lame that node doesn't expose this API out-of-the-box. It also
57174
+ * relies on the undocumented `tty_wrap.guessHandleType()` which is also lame.
57175
+ */
57176
+
57177
+ function createWritableStdioStream (fd) {
57178
+ var stream;
57179
+ var tty_wrap = process.binding('tty_wrap');
57180
+
57181
+ // Note stream._type is used for test-module-load-list.js
57182
+
57183
+ switch (tty_wrap.guessHandleType(fd)) {
57184
+ case 'TTY':
57185
+ stream = new tty.WriteStream(fd);
57186
+ stream._type = 'tty';
57187
+
57188
+ // Hack to have stream not keep the event loop alive.
57189
+ // See https://github.com/joyent/node/issues/1726
57190
+ if (stream._handle && stream._handle.unref) {
57191
+ stream._handle.unref();
57192
+ }
57193
+ break;
57194
+
57195
+ case 'FILE':
57196
+ var fs = __webpack_require__(747);
57197
+ stream = new fs.SyncWriteStream(fd, { autoClose: false });
57198
+ stream._type = 'fs';
57199
+ break;
57200
+
57201
+ case 'PIPE':
57202
+ case 'TCP':
57203
+ var net = __webpack_require__(60);
57204
+ stream = new net.Socket({
57205
+ fd: fd,
57206
+ readable: false,
57207
+ writable: true
57208
+ });
57209
+
57210
+ // FIXME Should probably have an option in net.Socket to create a
57211
+ // stream from an existing fd which is writable only. But for now
57212
+ // we'll just add this hack and set the `readable` member to false.
57213
+ // Test: ./node test/fixtures/echo.js < /etc/passwd
57214
+ stream.readable = false;
57215
+ stream.read = null;
57216
+ stream._type = 'pipe';
57217
+
57218
+ // FIXME Hack to have stream not keep the event loop alive.
57219
+ // See https://github.com/joyent/node/issues/1726
57220
+ if (stream._handle && stream._handle.unref) {
57221
+ stream._handle.unref();
57222
+ }
57223
+ break;
57224
+
57225
+ default:
57226
+ // Probably an error on in uv_guess_handle()
57227
+ throw new Error('Implement me. Unknown stream file type!');
57228
+ }
57229
+
57230
+ // For supporting legacy API we put the FD here.
57231
+ stream.fd = fd;
57232
+
57233
+ stream._isStdio = true;
57234
+
57235
+ return stream;
57236
+ }
57237
+
57238
+ /**
57239
+ * Init logic for `debug` instances.
57240
+ *
57241
+ * Create a new `inspectOpts` object in case `useColors` is set
57242
+ * differently for a particular `debug` instance.
57243
+ */
57244
+
57245
+ function init (debug) {
57246
+ debug.inspectOpts = {};
57247
+
57248
+ var keys = Object.keys(exports.inspectOpts);
57249
+ for (var i = 0; i < keys.length; i++) {
57250
+ debug.inspectOpts[keys[i]] = exports.inspectOpts[keys[i]];
57251
+ }
57252
+ }
57253
+
57254
+ /**
57255
+ * Enable namespaces listed in `process.env.DEBUG` initially.
57256
+ */
57257
+
57258
+ exports.enable(load());
57259
+
57260
+
57261
+ /***/ }),
57953
57262
  /* 876 */
57954
57263
  /***/ (function(module) {
57955
57264