pax_global_header00006660000000000000000000000064142276514350014523gustar00rootroot0000000000000052 comment=bd83f6e37d1f47eedf65a725daddd4f4f5891ad4 jake-10.8.5/000077500000000000000000000000001422765143500125305ustar00rootroot00000000000000jake-10.8.5/.eslintrc.js000066400000000000000000000014201422765143500147640ustar00rootroot00000000000000 module.exports = { env: { node: true, es6: true }, globals: { jake: 'readable', task: 'readable', namespace: 'readable', desc: 'readable', complete: 'readable', file: 'readable', directory: 'readable', fail: 'readable', test: 'readable', suite: 'readable', setup: 'readable', teardown: 'readable' }, parserOptions: { ecmaVersion: 2018, sourceType: 'module' }, extends: 'eslint:recommended', rules: { 'indent': ['error', 2], 'no-console': 'off', 'no-empty': 'off', 'no-unused-vars': ['error', { 'args': 'none' }], 'no-useless-escape': 'off', 'space-before-function-paren': ['error', { 'anonymous': 'always', 'named': 'never', 'asyncArrow': 'always' }] } } jake-10.8.5/.gitignore000066400000000000000000000001101422765143500145100ustar00rootroot00000000000000*.swp *.swo dist .idea/ tags nbproject/ node_modules tmtags *.DS_Store jake-10.8.5/.travis.yml000066400000000000000000000002461422765143500146430ustar00rootroot00000000000000language: node_js arch: - amd64 - ppc64le node_js: - "8" - "10" - "12" before_install: - npm update -g npm script: - npm run-script test:ci sudo: false jake-10.8.5/LICENSE000066400000000000000000000261361422765143500135450ustar00rootroot00000000000000 Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. jake-10.8.5/Makefile000066400000000000000000000024471422765143500141770ustar00rootroot00000000000000# # Jake JavaScript build tool # Copyright 2112 Matthew Eernisse (mde@fleegix.org) # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # .PHONY: all build install clean uninstall PREFIX=/usr/local DESTDIR= all: build build: @echo 'Jake built.' install: @mkdir -p $(DESTDIR)$(PREFIX)/bin && \ mkdir -p $(DESTDIR)$(PREFIX)/lib/node_modules/jake && \ mkdir -p ./node_modules && \ npm install utilities minimatch && \ cp -R ./* $(DESTDIR)$(PREFIX)/lib/node_modules/jake/ && \ ln -snf ../lib/node_modules/jake/bin/cli.js $(DESTDIR)$(PREFIX)/bin/jake && \ chmod 755 $(DESTDIR)$(PREFIX)/lib/node_modules/jake/bin/cli.js && \ echo 'Jake installed.' clean: @true uninstall: @rm -f $(DESTDIR)$(PREFIX)/bin/jake && \ rm -fr $(DESTDIR)$(PREFIX)/lib/node_modules/jake/ && \ echo 'Jake uninstalled.' jake-10.8.5/README.md000066400000000000000000000010541422765143500140070ustar00rootroot00000000000000### Jake -- the JavaScript build tool for Node.js [![Build Status](https://travis-ci.org/jakejs/jake.svg?branch=master)](https://travis-ci.org/jakejs/jake) Documentation site at [http://jakejs.com](http://jakejs.com/) ### Contributing 1. [Install node](http://nodejs.org/#download). 2. Clone this repository `$ git clone git@github.com:jakejs/jake.git`. 3. Install dependencies `$ npm install`. 4. Run tests with `$ npm test`. 5. Start Hacking! ### License Licensed under the Apache License, Version 2.0 () jake-10.8.5/bin/000077500000000000000000000000001422765143500133005ustar00rootroot00000000000000jake-10.8.5/bin/bash_completion.sh000077500000000000000000000025371422765143500170140ustar00rootroot00000000000000#!/bin/bash # http://stackoverflow.com/a/246128 SOURCE="${BASH_SOURCE[0]}" while [ -h "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )" SOURCE="$(readlink "$SOURCE")" [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE" # if $SOURCE was a relative symlink, we need to resolve it relative to the path where the symlink file was located done JAKE_BIN_DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )" # http://stackoverflow.com/a/12495480 # http://stackoverflow.com/a/28647824 _auto_jake() { local cur local -a COMPGEN=() _get_comp_words_by_ref -n : -c cur # run auto-completions in jake via our auto_complete.js wrapper local -a auto_complete_info=( $(export COMP_LINE="${COMP_LINE}" && ${JAKE_BIN_DIR}/auto_complete.js "$cur" "${3}") ) # check reply flag local reply_flag="${auto_complete_info[0]}" if [[ "${reply_flag}" == "no-complete" ]]; then return 1 fi local auto_completions=("${auto_complete_info[@]:1}") COMPGEN=( $(compgen -W "${auto_completions[*]}" -- "$cur") ) COMPREPLY=( "${COMPGEN[@]}" ) __ltrim_colon_completions "$cur" # do we need another space?? if [[ "${reply_flag}" == "yes-space" ]]; then COMPREPLY=( "${COMPGEN[@]}" " " ) fi return 0 } complete -o default -F _auto_jake jake jake-10.8.5/bin/cli.js000077500000000000000000000016131422765143500144110ustar00rootroot00000000000000#!/usr/bin/env node /* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ // Try to load a local jake try { require(`${ process.cwd() }/node_modules/jake`); } // If that fails, likely running globally catch(e) { require('../lib/jake'); } var args = process.argv.slice(2); jake.run.apply(jake, args); jake-10.8.5/changelog.md000066400000000000000000000057001422765143500150030ustar00rootroot00000000000000### v10 + Support for generic exported functions as tasks + Experimental `series` function for composing tasks + Added task timing, begin/end task output * Next-tick kickoff/completion of tasks * Support both sync and async tasks in experimental `series` * Polling to ensure 100% sequential execution * Begin updating to ESNext syntax ### v8 + Concurrent task execution + Allow prereqs for PackageTask + PublishTask + LiveScript support + Custom publish function, not just string command * Change to whole-number versioning * Change to ESLint for linting * Support newer Nodes, dropped support for older * Fixes for WatchTask * Numerous community fixes ### v0.7 + Updated API for include/exclude in PublishTask + beforeEach/afterEach for TaskTask + Custom publishing command for PublishTask + Tests for PublishTask + Throttling for WatchTask * FileList fixes for Windows * Fixed output for stdout/stderr when piped * Numerous fixes for TestTask * NpmPublish task renamed to simply PublishTask * Chalk for color output (compat with strict mode) ### v0.6 + Rule, for generating file-tasks on the fly + WatchTask, for running tasks on file/directory changes + Return values for tasks + Promise-based async task completion + Multiple Git branches for NpmPublishTask + Linting codebase with JSHint + Filled out top-level API methods for creating other task-types * Better API for including/excluding files from NpmPublishTask ### v0.5 + Interactive exec + Node v0.10 compatibility (fixed their broken PPI) + Docs for async management with manual invocation + More lifecycle events emitted * Better Windows support for FileList pathnames * Faster FileTask execution ### v0.4 + Embeddable Jake, non-CLI use ### v0.3 + TestTask, for minimal test-running + Chaining support for FileList API + Node v0.8 compatibility + Added -q / quiet flag for suppressing output * Migrated FileUtils into 'utilities' NPM library * Numerous PackageTask archiving fixes * `namespace` appends instead of overwriting ### v0.2 + NpmPublishTask, for automating NPM publishing + FileUtils, for sync filesystem manipulation + Evented tasks + Streamed output from jake.exec + Numerous Windows fixes for jake.exec + Shit-ton of new tests * Massive refactor of task/file-task/directory-task ### v0.1 + FileTask, DirectoryTask + PackageTask, for easy project packaging + FileList, for lazy-access of long lists of filenames, pattern-matching + zsh support + Multiple targets from CLI + 'async' Boolean to options object + Always-make flag + -T for listing tasks + Passed params from CLI + `invoke`, `execute`, `reenable` methods on tasks + Task emits on completion + Custom exit-status for fail + Recursive directory-search for Jakefile + Added proper license notice + Basic suite of integration tests + Added package.json + Coffeescript support + Basic Windows support * Switch from node-glob to minimatch for globbing ### v0.0 + Use Rake-style syntax instead of object-literal to define tasks + jake main module as basic task-runner jake-10.8.5/docs/000077500000000000000000000000001422765143500134605ustar00rootroot00000000000000jake-10.8.5/docs/overview.md000066400000000000000000001101561422765143500156540ustar00rootroot00000000000000## Overview Jake is the JavaScript build tool for NodeJS. Jake has been around since the very early days of Node, and is very full featured and well tested. ### Installing with NPM Install globally with: npm install -g jake Or you may also install it as a development dependency in a package.json file: // package.json "devDependencies": { "jake": "latest" } Then install it with `npm install` Note Jake is intended to be mostly a command-line tool, but lately there have been changes to it so it can be either embedded, or run from inside your project. ### Windows, installing from source For Windows users installing from source, there are some additional steps. *Assumed: current directory is the same directory where node.exe is present.* Get Jake: git clone git://github.com/mde/jake.git node_modules/jake Copy jake.bat and jake to the same directory as node.exe copy node_modules/jake/jake.bat jake.bat copy node_modules/jake/jake jake Add the directory of node.exe to the environment PATH variable. ### Basic usage jake [options ...] [env variables ...] target ### Description Jake is a simple JavaScript build program with capabilities similar to the regular make or rake command. Jake has the following features: * Jakefiles are in standard JavaScript syntax * Tasks with prerequisites * Namespaces for tasks * Async task execution ### Options -V/v --version Display the Jake version. -h --help Display help message. -f *FILE* --jakefile *FILE* Use FILE as the Jakefile. -C *DIRECTORY* --directory *DIRECTORY* Change to DIRECTORY before running tasks. -q --quiet Do not log messages to standard output. -J *JAKELIBDIR* --jakelibdir *JAKELIBDIR* Auto-import any .jake files in JAKELIBDIR. (default is 'jakelib') -B --always-make Unconditionally make all targets. -t --trace Enable full backtrace. -T/ls --tasks Display the tasks (matching optional PATTERN) with descriptions, then exit. ### Jakefile syntax A Jakefile is just executable JavaScript. You can include whatever JavaScript you want in it. ## Tasks Use `task` to define tasks. It has one required argument, the task-name, and three optional arguments: ```javascript task(name, [prerequisites], [action], [opts]); ``` The `name` argument is a String with the name of the task, and `prerequisites` is an optional Array arg of the list of prerequisite tasks to perform first. The `action` is a Function defining the action to take for the task. (Note that Object-literal syntax for name/prerequisites in a single argument a la Rake is also supported, but JavaScript's lack of support for dynamic keys in Object literals makes it not very useful.) The action is invoked with the Task object itself as the execution context (i.e, "this" inside the action references the Task object). The `opts` argument is the normal JavaScript-style 'options' object. When a task's operations are asynchronous, the `async` property should be set to `true`, and the task must call `complete()` to signal to Jake that the task is done, and execution can proceed. By default the `async` property is `false`. Tasks created with `task` are always executed when asked for (or are a prerequisite). Tasks created with `file` are only executed if no file with the given name exists or if any of its file-prerequisites are more recent than the file named by the task. Also, if any prerequisite is a regular task, the file task will always be executed. Use `desc` to add a string description of the task. Here's an example: ```javascript desc('This is the default task.'); task('default', function (params) { console.log('This is the default task.'); }); desc('This task has prerequisites.'); task('hasPrereqs', ['foo', 'bar', 'baz'], function (params) { console.log('Ran some prereqs first.'); }); ``` And here's an example of an asynchronous task: ```javascript desc('This is an asynchronous task.'); task('asyncTask', {async: true}, function () { setTimeout(complete, 1000); }); ``` A Task is also an EventEmitter which emits the 'start' event when it begins to run, and the 'complete' event when it is finished. This allows asynchronous tasks to be run from within other tasks via either `invoke` or `execute`, and ensures they will complete before the rest of the containing task executes. See the section "Running tasks from within other tasks," below. ### File-tasks Create a file-task by calling `file`. File-tasks create a file from one or more other files. With a file-task, Jake checks both that the file exists, and also that it is not older than the files specified by any prerequisite tasks. File-tasks are particularly useful for compiling something from a tree of source files. ```javascript desc('This builds a minified JS file for production.'); file('foo-minified.js', ['bar', 'foo-bar.js', 'foo-baz.js'], function () { // Code to concat and minify goes here }); ``` ### Directory-tasks Create a directory-task by calling `directory`. Directory-tasks create a directory for use with for file-tasks. Jake checks for the existence of the directory, and only creates it if needed. ```javascript desc('This creates the bar directory for use with the foo-minified.js file-task.'); directory('bar'); ``` This task will create the directory when used as a prerequisite for a file-task, or when run from the command-line. ### Namespaces Use `namespace` to create a namespace of tasks to perform. Call it with two arguments: ```javascript namespace(name, namespaceTasks); ``` Where is `name` is the name of the namespace, and `namespaceTasks` is a function with calls inside it to `task` or `desc` defining all the tasks for that namespace. Here's an example: ```javascript desc('This is the default task.'); task('default', function () { console.log('This is the default task.'); }); namespace('foo', function () { desc('This the foo:bar task'); task('bar', function () { console.log('doing foo:bar task'); }); desc('This the foo:baz task'); task('baz', ['default', 'foo:bar'], function () { console.log('doing foo:baz task'); }); }); ``` In this example, the foo:baz task depends on the default and foo:bar tasks. ### Rules When you add a filename as a prerequisite for a task, but there is not a file-task defined for it, Jake can create file-tasks on the fly from Rules. Here's an example: ```javascript rule('.o', '.c', {async: true}, function () { var cmd = 'cc ' + this.source + ' -c -o ' + this.name; jake.exec(cmd, function () { complete(); }); }); ``` This rule will take effect for any task-name that ends in '.o', but will require the existence of a prerequisite source file with the same name ending in '.c'. For example, with this rule, if you reference a task 'foobarbaz.o' as a prerequisite somewhere in one of your Jake tasks, rather than complaining about this file not existing, or the lack of a task with that name, Jake will automatically create a FileTask for 'foobarbaz.o' with the action specified in the rule you've defined. (The usual action would be to create 'foobarbaz.o' from 'foobarbaz.c'). If 'foobarbaz.c' does not exist, it will recursively attempt synthesize a viable rule for it as well. #### Regex patterns You can use regular expressions to match file extensions as well: ```javascript rule(/\.o$/, '.c', {async: true}, function () { var cmd = 'cc ' + this.source + ' -c -o ' + this.name; jake.exec(cmd, function () { complete(); }); }); ``` #### Source files from functions You can also use a function to calculate the name of the desired source-file to use, instead of assuming simple suffix-substitution: ```javascript // Match .less.css or .scss.css and run appropriate preprocessor var getSourceFilename = function (name) { // Strip off the extension for the filename return name.replace(/\.css$/, ''); }; rule(/\.\w{2,4}\.css$/, getSourceFilename, {async: true}, function () { // Get appropriate preprocessor for this.source, e.g., foo.less // Generate a file with filename of this.name, e.g., foo.less.css }); ``` ### Passing parameters to jake Parameters can be passed to Jake two ways: plain arguments, and environment variables. To pass positional arguments to the Jake tasks, enclose them in square braces, separated by commas, after the name of the task on the command-line. For example, with the following Jakefile: ```javascript desc('This is an awesome task.'); task('awesome', function (a, b, c) { console.log(a, b, c); }); ``` You could run `jake` like this: jake awesome[foo,bar,baz] And you'd get the following output: foo bar baz Note that you *cannot* uses spaces between the commas separating the parameters. Any parameters passed after the Jake task that contain an equals sign (=) will be added to process.env. With the following Jakefile: ```javascript desc('This is an awesome task.'); task('awesome', function (a, b, c) { console.log(a, b, c); console.log(process.env.qux, process.env.frang); }); ``` You could run `jake` like this: jake awesome[foo,bar,baz] qux=zoobie frang=asdf And you'd get the following output: foo bar baz zoobie asdf Running `jake` with no arguments runs the default task. __Note for zsh users__ : you will need to escape the brackets or wrap in single quotes like this to pass parameters : jake 'awesome[foo,bar,baz]' An other solution is to deactivate permanently file-globbing for the `jake` command. You can do this by adding this line to your `.zshrc` file : alias jake="noglob jake" ### Cleanup after all tasks run, jake 'complete' event The base 'jake' object is an EventEmitter, and fires a 'start' event before running, an 'error' event after an uncaught exception, and a 'complete' event after running all tasks. This is sometimes useful when a task starts a process which keeps the Node event-loop running (e.g., a database connection). If you know you want to stop the running Node process after all tasks have finished, you can set a listener for the 'complete' event, like so: ```javascript jake.addListener('complete', function () { process.exit(); }); ``` ### Running tasks from within other tasks Jake supports the ability to run a task from within another task via the `invoke` and `execute` methods. The `invoke` method will run the desired task, along with its prerequisites: ```javascript desc('Calls the foo:bar task and its prerequisites.'); task('invokeFooBar', function () { // Calls foo:bar and its prereqs jake.Task['foo:bar'].invoke(); }); ``` The `invoke` method will only run the task once, even if you call it repeatedly. ```javascript desc('Calls the foo:bar task and its prerequisites.'); task('invokeFooBar', function () { // Calls foo:bar and its prereqs jake.Task['foo:bar'].invoke(); // Does nothing jake.Task['foo:bar'].invoke(); }); ``` The `execute` method will run the desired task without its prerequisites: ```javascript desc('Calls the foo:bar task without its prerequisites.'); task('executeFooBar', function () { // Calls foo:bar without its prereqs jake.Task['foo:baz'].execute(); }); ``` Calling `execute` repeatedly will run the desired task repeatedly. ```javascript desc('Calls the foo:bar task without its prerequisites.'); task('executeFooBar', function () { // Calls foo:bar without its prereqs jake.Task['foo:baz'].execute(); // Can keep running this over and over jake.Task['foo:baz'].execute(); jake.Task['foo:baz'].execute(); }); ``` If you want to run the task and its prerequisites more than once, you can use `invoke` with the `reenable` method. ```javascript desc('Calls the foo:bar task and its prerequisites.'); task('invokeFooBar', function () { // Calls foo:bar and its prereqs jake.Task['foo:bar'].invoke(); // Does nothing jake.Task['foo:bar'].invoke(); // Only re-runs foo:bar, but not its prerequisites jake.Task['foo:bar'].reenable(); jake.Task['foo:bar'].invoke(); }); ``` The `reenable` method takes a single Boolean arg, a 'deep' flag, which reenables the task's prerequisites if set to true. ```javascript desc('Calls the foo:bar task and its prerequisites.'); task('invokeFooBar', function () { // Calls foo:bar and its prereqs jake.Task['foo:bar'].invoke(); // Does nothing jake.Task['foo:bar'].invoke(); // Re-runs foo:bar and all of its prerequisites jake.Task['foo:bar'].reenable(true); jake.Task['foo:bar'].invoke(); }); ``` It's easy to pass params on to a sub-task run via `invoke` or `execute`: ```javascript desc('Passes params on to other tasks.'); task('passParams', function () { var t = jake.Task['foo:bar']; // Calls foo:bar, passing along current args t.invoke.apply(t, arguments); }); ``` ### Getting values out of tasks Passing a value to the `complete` function for async tasks (or simply returning a value from sync tasks) will set a 'value' property on the completed task. This same value will also be passed as the task emits its 'complete' event. After a task is completed, this value will be also available in the '.value' property on the task. Calling `reenable` on the task will clear this value. ```javascript task('environment', {async: true}, function () { // Do some sort of I/O to figure out the environment value doSomeAsync(function (err, val) { if (err) { throw err } complete(val); }); }); task("someTaskWithEnvViaPrereq", ["environment"], function () { api = jake.Task["environment"].value; console.log(api); }); task("someTaskWithEnvViaInvoke", {async: true}, function () { var env = jake.Task["environment"]; env.addListener('complete', function (api) { console.log(api); complete(); }); env.invoke(); }); ``` ### Managing asynchrony without prereqs (e.g., when using `invoke`) You can mix sync and async without problems when using normal prereqs, because the Jake execution loop takes care of the difference for you. But when you call `invoke` or `execute`, you have to manage the asynchrony yourself. Here's a correct working example: ```javascript task('async1', ['async2'], {async: true}, function () { console.log('-- async1 start ----------------'); setTimeout(function () { console.log('-- async1 done ----------------'); complete(); }, 1000); }); task('async2', {async: true}, function () { console.log('-- async2 start ----------------'); setTimeout(function () { console.log('-- async2 done ----------------'); complete(); }, 500); }); task('init', ['async1', 'async2'], {async: true}, function () { console.log('-- init start ----------------'); setTimeout(function () { console.log('-- init done ----------------'); complete(); }, 100); }); task('default', {async: true}, function () { console.log('-- default start ----------------'); var init = jake.Task.init; init.addListener('complete', function () { console.log('-- default done ----------------'); complete(); }); init.invoke(); }); ``` You have to declare the "default" task as asynchronous as well, and call `complete` on it when "init" finishes. Here's the output: -- default start ---------------- -- async2 start ---------------- -- async2 done ---------------- -- async1 start ---------------- -- async1 done ---------------- -- init start ---------------- -- init done ---------------- -- default done ---------------- You get what you expect -- "default" starts, the rest runs, and finally "default" finishes. ### Evented tasks Tasks are EventEmitters. They can fire 'complete' and 'error' events. If a task called via `invoke` is asynchronous, you can set a listener on the 'complete' event to run any code that depends on it. ```javascript desc('Calls the async foo:baz task and its prerequisites.'); task('invokeFooBaz', {async: true}, function () { var t = jake.Task['foo:baz']; t.addListener('complete', function () { console.log('Finished executing foo:baz'); // Maybe run some other code // ... // Complete the containing task complete(); }); // Kick off foo:baz t.invoke(); }); ``` If you want to handle the errors in a task in some specific way, you can set a listener for the 'error' event, like so: ```javascript namespace('vronk', function () { task('groo', function () { var t = jake.Task['vronk:zong']; t.addListener('error', function (e) { console.log(e.message); }); t.invoke(); }); task('zong', function () { throw new Error('OMFGZONG'); }); }); ``` If no specific listener is set for the "error" event, errors are handled by Jake's generic error-handling. ### Aborting a task You can abort a task by calling the `fail` function, and Jake will abort the currently running task. You can pass a customized error message to `fail`: ```javascript desc('This task fails.'); task('failTask', function () { fail('Yikes. Something back happened.'); }); ``` You can also pass an optional exit status-code to the fail command, like so: ```javascript desc('This task fails with an exit-status of 42.'); task('failTaskQuestionCustomStatus', function () { fail('What is the answer?', 42); }); ``` The process will exit with a status of 42. Uncaught errors will also abort the currently running task. ### Running prerequisites in parallel Jake can run the prerequisites of a task in parallel. This only makes sense when the tasks are asynchronous and do not block NodeJS event loop like executing shell commands. You can enable and limit the number of simultaneous tasks with the ```parallelLimit``` task option. Because the order in which the tasks executed in parallel will finish is not known these tasks **cannot** call the global `complete` function. Instead they **must** finish the specific task either by calling ```task.complete()``` or ```complete(task)``` The folowing example uses ```setTimout``` to finish two tasks out of order. The entire task takes 550ms to complete : ```javascript task("A", {async: true}, function() { console.log("Started A"); var task = this; setTimeout(function() { console.log("Finished A"); task.complete(); }, 500); }); task("B", {async: true}, function() { console.log("Started B"); var task = this; setTimeout(function() { console.log("Finished B"); task.complete(); },250); }); task("parallel", ["A","B"], {async: true, parallelLimit: 2}, function() { var task = this; setTimeout(function() { task.complete(); },50); }); ``` ### Showing the list of tasks Passing `jake` the -T or --tasks flag will display the full list of tasks available in a Jakefile, along with their descriptions: $ jake -T jake default # This is the default task. jake asdf # This is the asdf task. jake concat.txt # File task, concatenating two files together jake failure # Failing task. jake lookup # Jake task lookup by name. jake foo:bar # This the foo:bar task jake foo:fonebone # This the foo:fonebone task Setting a value for -T/--tasks will filter the list by that value: $ jake -T foo jake foo:bar # This the foo:bar task jake foo:fonebone # This the foo:fonebone task The list displayed will be all tasks whose namespace/name contain the filter-string. Internally, passing this CLI flag calls `jake.showAllTaskDescriptions`, and passes it the filter -- so `jake -T foo` is equivalent to calling `jake.showAllTaskDescriptions('foo');`. ## Breaking things up into multiple files Jake will automatically look for files with a .jake extension in a 'jakelib' directory in your project, and load them (via `require`) after loading your Jakefile. (The directory name can be overridden using the -J/--jakelibdir command-line option.) This allows you to break your tasks up over multiple files -- a good way to do it is one namespace per file: e.g., a `zardoz` namespace full of tasks in 'jakelib/zardox.jake'. Note that these .jake files each run in their own module-context, so they don't have access to each others' data. However, the Jake API methods, and the task-hierarchy are globally available, so you can use tasks in any file as prerequisites for tasks in any other, just as if everything were in a single file. Environment-variables set on the command-line are likewise also naturally available to code in all files via process.env. ## File-utils Since shelling out in Node is an asynchronous operation, Jake comes with a few useful file-utilities with a synchronous API, that make scripting easier. The `jake.mkdirP` utility recursively creates a set of nested directories. It will not throw an error if any of the directories already exists. Here's an example: ```javascript jake.mkdirP('app/views/layouts'); ``` The `jake.cpR` utility does a recursive copy of a file or directory. It takes two arguments, the file/directory to copy, and the destination. Note that this command can only copy files and directories; it does not perform globbing (so arguments like '*.txt' are not possible). ```javascript jake.cpR(path.join(sourceDir, '/templates'), currentDir); ``` This would copy 'templates' (and all its contents) into `currentDir`. The `jake.readdirR` utility gives you a recursive directory listing, giving you output somewhat similar to the Unix `find` command. It only works with a directory name, and does not perform filtering or globbing. ```javascript jake.readdirR('pkg'); ``` This would return an array of filepaths for all files in the 'pkg' directory, and all its subdirectories. The `jake.rmRf` utility recursively removes a directory and all its contents. ```javascript jake.rmRf('pkg'); ``` This would remove the 'pkg' directory, and all its contents. ## Running shell-commands: `jake.exec` and `jake.createExec` Jake also provides a more general utility function for running a sequence of shell-commands. ### `jake.exec` The `jake.exec` command takes an array of shell-command strings, and an optional callback to run after completing them. Here's an example from Jake's Jakefile, that runs the tests: ```javascript desc('Runs the Jake tests.'); task('test', {async: true}, function () { var cmds = [ 'node ./tests/parseargs.js' , 'node ./tests/task_base.js' , 'node ./tests/file_task.js' ]; jake.exec(cmds, {printStdout: true}, function () { console.log('All tests passed.'); complete(); }); desc('Runs some apps in interactive mode.'); task('interactiveTask', {async: true}, function () { var cmds = [ 'node' // Node console , 'vim' // Open Vim ]; jake.exec(cmds, {interactive: true}, function () { complete(); }); }); ``` It also takes an optional options-object, with the following options: * `interactive` (tasks are interactive, trumps printStdout and printStderr below, default false) * `printStdout` (print to stdout, default false) * `printStderr` (print to stderr, default false) * `breakOnError` (stop execution on error, default true) This command doesn't pipe input between commands -- it's for simple execution. ### `jake.createExec` and the evented Exec object Jake also provides an evented interface for running shell commands. Calling `jake.createExec` returns an instance of `jake.Exec`, which is an `EventEmitter` that fires events as it executes commands. It emits the following events: * 'cmdStart': When a new command begins to run. Passes one arg, the command being run. * 'cmdEnd': When a command finishes. Passes one arg, the command being run. * 'stdout': When the stdout for the child-process receives data. This streams the stdout data. Passes one arg, the chunk of data. (When using the printStdout option, these events are not available as the stdout of the child process is inherited directly from the current process.) * 'stderr': When the stderr for the child-process receives data. This streams the stderr data. Passes one arg, the chunk of data. (When using the printStderr option, these events are not available as the stderr of the child process is inherited directly from the current process.) * 'error': When a shell-command exits with a non-zero status-code. Passes two args -- the error message, and the status code. If you do not set an error handler, and a command exits with an error-code, Jake will throw the unhandled error. If `breakOnError` is set to true, the Exec object will emit and 'error' event after the first error, and stop any further execution. To begin running the commands, you have to call the `run` method on it. It also has an `append` method for adding new commands to the list of commands to run. Here's an example: ```javascript var ex = jake.createExec(['do_thing.sh']); ex.addListener('error', function (msg, code) { if (code == 127) { console.log("Couldn't find do_thing script, trying do_other_thing"); ex.append('do_other_thing.sh'); } else { fail('Fatal error: ' + msg, code); } }); ex.run(); ``` Using the evented Exec object gives you a lot more flexibility in running shell commmands. But if you need something more sophisticated, Procstreams () might be a good option. ## Logging and output Using the -q/--quiet flag at the command-line will stop Jake from sending its normal output to standard output. Note that this only applies to built-in output from Jake; anything you output normally from your tasks will still be displayed. If you want to take advantage of the -q/--quiet flag in your own programs, you can use `jake.logger.log` and `jake.logger.error` for displaying output. These two commands will respect the flag, and suppress output correctly when the quiet-flag is on. You can check the current value of this flag in your own tasks by using `jake.program.opts.quiet`. If you want the output of a `jake.exec` shell-command to respect the quiet-flag, set your `printStdout` and `printStderr` options to false if the quiet-option is on: ```javascript task('echo', {async: true}, function () { jake.exec(['echo "hello"'], function () { jake.logger.log('Done.'); complete(); }, {printStdout: !jake.program.opts.quiet}); }); ``` ## FileList Jake's FileList takes a list of glob-patterns and file-names, and lazy-creates a list of files to include. Instead of immediately searching the filesystem to find the files, a FileList holds the pattern until it is actually used. When any of the normal JavaScript Array methods (or the `toArray` method) are called on the FileList, the pending patterns are resolved into an actual list of file-names. FileList uses the [minimatch](https://github.com/isaacs/minimatch) module. To build the list of files, use FileList's `include` and `exclude` methods: ```javascript var list = new jake.FileList(); list.include('foo/*.txt'); list.include(['bar/*.txt', 'README.md']); list.include('Makefile', 'package.json'); list.exclude('foo/zoobie.txt'); list.exclude(/foo\/src.*.txt/); console.log(list.toArray()); ``` The `include` method can be called either with an array of items, or multiple single parameters. Items can be either glob-patterns, or individual file-names. The `exclude` method will prevent files from being included in the list. These files must resolve to actual files on the filesystem. It can be called either with an array of items, or multiple single parameters. Items can be glob-patterns, individual file-names, string-representations of regular-expressions, or regular-expression literals. ## PackageTask When you create a PackageTask, it programmatically creates a set of tasks for packaging up your project for distribution. Here's an example: ```javascript packageTask('fonebone', 'v0.1.2112', function () { var fileList = [ 'Jakefile' , 'README.md' , 'package.json' , 'lib/*' , 'bin/*' , 'tests/*' ]; this.packageFiles.include(fileList); this.needTarGz = true; this.needTarBz2 = true; }); ``` This will automatically create a 'package' task that will assemble the specified files in 'pkg/fonebone-v0.1.2112,' and compress them according to the specified options. After running `jake package`, you'll have the following in pkg/: fonebone-v0.1.2112 fonebone-v0.1.2112.tar.bz2 fonebone-v0.1.2112.tar.gz PackageTask also creates a 'clobber' task that removes the pkg/ directory. ### PackageTask instance-property options - `name` {String} The name of the project - `version` {String} The project version-string - `prereqs` {Array} Tasks to run before packaging - `packageDir` {String='pkg'} The directory-name to use for packaging the software - `packageFiles` {jake.FileList} The list of files and directories to include in the package-archive - `needTar` {Boolean=false} If set to true, uses the `tar` utility to create a gzip .tgz archive of the package - `needTarGz` {Boolean=false} If set to true, uses the `tar` utility to create a gzip .tar.gz archive of the package - `needTarBz2` If set to true, uses the `tar` utility to create a bzip2 .bz2 archive of the package - `needJar` {Boolean=false} If set to true, uses the `jar` utility to create a .jar archive of the package - `needZip` {Boolean=false} If set to true, uses the `zip` utility to create a .zip archive of the package - `manifestFile` {String=null} Can be set to point the `jar` utility at a manifest file to use in a .jar archive. If unset, one will be automatically created by the `jar` utility. This path should be relative to the root of the package directory (this.packageDir above, likely 'pkg') - `tarCommand` {String='tar'} The shell-command to use for creating tar archives. - `jarCommand` {String='jar'} The shell-command to use for creating jar archives. - `zipCommand` {String='zip'} The shell-command to use for creating zip archives. - `archiveNoBaseDir` {Boolean=false} Simple option for performing the archive on the contents of the directory instead of the directory itself - `archiveChangeDir` {String=null} Equivalent to the '-C' command for the `tar` and `jar` commands. ("Change to this directory before adding files.") - `archiveContentDir` {String=null} Specifies the files and directories to include in the package-archive. If unset, this will default to the main package directory -- i.e., name + version. ### Windows-specific warning In a windows environment tar will fail unless you have manually added some form of tar compatible executable on your path, you can specify the `tarCommand` if needed to use a different executable on the path to achieve the same result. ## TestTask When you create a TestTask, it programmatically creates a simple task for running tests for your project. The first argument of the constructor is the project-name (used in the description of the task), the second (optional) argument is a list of prerequisite tasks to run before the tests, and the final argument is a function that defines the task. It allows you to specify what files to run as tests, and what to name the task that gets created (defaults to "test" if unset). ```javascript testTask('fonebone', ['asdf', 'qwer'], function () { var fileList = [ 'tests/*' , 'lib/adapters/**/test.js' ]; this.testFiles.include(fileList); this.testFiles.exclude('tests/helper.js'); this.testName = 'testMainAndAdapters'; }); ``` Tests in the specified file should be in the very simple format of test-functions hung off the export. These tests are converted into Jake tasks which Jake then runs normally. If a test needs to run asynchronously, simply define the test-function with a single argument, a callback. Jake will define this as an asynchronous task, and will wait until the callback is called in the test function to run the next test. If you name your test 'before', it will run before any of the other tests you export. You can use it for test-setup. If you name a test 'after', it will run after all the other tests have finished. You can use it for teardown. The 'before' and 'after' will only run once per test module -- *not* before and after each test. If you name your test 'beforeEach', it will run before each test. You can also name a test 'afterEach' for a test that runs after each test. Here's an example test-file: ```javascript var assert = require('assert') , tests; tests = { 'before': function () { // Do some setup here } , 'after': function () { // Do some teardown here } , 'beforeEach': function () { // Something to do before every test } , 'afterEach': function () { // Something to do after every test } , 'sync test': function () { // Assert something assert.ok(true); } , 'async test': function (next) { // Assert something else assert.ok(true); // Won't go next until this is called next(); } , 'another sync test': function () { // Assert something else assert.ok(true); } }; module.exports = tests; ``` Jake's tests are also a good example of use of a TestTask. ## WatchTask When you create a WatchTask, it will watch a directory of files for changes, and run a task or set of tasks anytime there's a change. ```javascript // Assumes there's an 'assets' task, creates a task called 'watch' watchTask('watch', ['assets'], function () { this.watchFiles.include([ './**/*.ejs' ]); }); ``` Run `jake ` to start up the WatchTask. By default, it will watch the current directory for these files: ```javascript [ './**/*.js' , './**/*.coffee' , './**/*.ls' , './**/*.css' , './**/*.less' , './**/*.scss' ] ``` By default, it will exclude these files: ```javascript [ 'node_modules/**' , '.git/**' ] ``` The list of watched files is in a FileList, with the normal `include`/`exclude` API. ## PublishTask The PublishTask builds on top of PackageTask to allow you to do a version bump of your project, package it, and publish it to NPM (or somewhere else). Define the task with your project's name, and call `include`/`exclude` on the `packageFiles` FileList to create the list of files you want packaged and published to NPM. You can also pass a list of prerequisite tasks to run before defining tasks for publishing. Here's an example from Jake's Jakefile: ```javascript publishTask('foo', ['bar', 'baz'], function () { this.packageFiles.include([ 'Makefile' , 'Jakefile' , 'README.md' , 'package.json' , 'lib/**' , 'bin/**' , 'test/**' ]); this.packageFiles.exclude([ 'test/tmp' ]); }); ``` The PublishTask will automatically create a `publish` task which performs the following steps: 1. Bump the version number in your package.json 2. Commit change in git, push it to GitHub 3. Create a git tag for the version 4. Push the tag to GitHub 5. Package the new version of your project 6. Publish it to NPM 7. Clean up the package If you want to publish to a private NPM repository, you can specify a custom publishing command: ```javascript npmPublishTask('zerb', function () { this.packageFiles.include([ , 'index.js' , 'package.json' ]); // Publishes using the gemfury cli // `%filename` will be replaced with the package filename this.publishCmd = 'fury push %filename'; }); ``` ## CoffeeScript Jakefiles Jake can also handle Jakefiles in CoffeeScript. Be sure to make it Jakefile.coffee so Jake knows it's in CoffeeScript. Here's an example: ```coffeescript util = require('util') desc 'This is the default task.' task 'default', (params) -> console.log 'Ths is the default task.' console.log(util.inspect(arguments)) jake.Task['new'].invoke [] task 'new', -> console.log 'ello from new' jake.Task['foo:next'].invoke ['param'] namespace 'foo', -> task 'next', (param) -> console.log 'ello from next with param: ' + param ``` ## LiveScript Jakefiles Jake can also handle Jakefiles in LiveScript. Be sure to make it Jakefile.ls so Jake knows it's in LiveScript. Here's an example: ```livescript require! \util desc 'This is the default task.' task \default, (params) !-> console.log 'This is the default task.' console.log (util.inspect arguments) jake.Task[\new].invoke [] task \new !-> console.log 'ello from new' jake.Task[\foo:next].invoke [\param] namespace \foo -> task \next (param) !-> console.log "ello from next with param: #param" ``` ## Related projects James Coglan's "Jake": Confusingly, this is a Ruby tool for building JavaScript packages from source code. 280 North's Jake: This is also a JavaScript port of Rake, which runs on the Narwhal platform. ## License Licensed under the Apache License, Version 2.0 () jake-10.8.5/jake000066400000000000000000000003051422765143500133630ustar00rootroot00000000000000#!/bin/sh if [ -x "`dirname "$0"`/node.exe" ]; then "`dirname "$0"`/node.exe" "`dirname "$0"`/node_modules/jake/bin/cli.js" "$@" else node "`dirname "$0"`/node_modules/jake/bin/cli.js" "$@" fi jake-10.8.5/jake.bat000066400000000000000000000001051422765143500141260ustar00rootroot00000000000000@ECHO OFF @"%~dp0node.exe" "%~dp0/node_modules/jake/bin/cli.js" %* jake-10.8.5/jakefile.js000066400000000000000000000044401422765143500146420ustar00rootroot00000000000000let fs = require('fs') let path = require('path'); let proc = require('child_process'); const PROJECT_DIR = process.cwd(); process.env.PROJECT_DIR = PROJECT_DIR; namespace('doc', function () { task('generate', ['doc:clobber'], function () { var cmd = '../node-jsdoc-toolkit/app/run.js -n -r=100 ' + '-t=../node-jsdoc-toolkit/templates/codeview -d=./doc/ ./lib'; jake.logger.log('Generating docs ...'); jake.exec([cmd], function () { jake.logger.log('Done.'); complete(); }); }, {async: true}); task('clobber', function () { var cmd = 'rm -fr ./doc/*'; jake.exec([cmd], function () { jake.logger.log('Clobbered old docs.'); complete(); }); }, {async: true}); }); desc('Generate docs for Jake'); task('doc', ['doc:generate']); npmPublishTask('jake', function () { this.packageFiles.include([ 'Makefile', 'jakefile.js', 'README.md', 'package.json', 'usage.txt', 'lib/**', 'bin/**', 'test/**' ]); this.packageFiles.exclude([ 'test/tmp' ]); }); jake.Task['publish:package'].directory = PROJECT_DIR; namespace('test', function () { let integrationTest = task('integration', async function () { let testArgs = []; if (process.env.filter) { testArgs.push(process.env.filter); } else { testArgs.push('*.js'); } let spawned = proc.spawn(`${PROJECT_DIR}/node_modules/.bin/mocha`, testArgs, { stdio: 'inherit' }); return new Promise((resolve, reject) => { spawned.on('exit', () => { resolve(); }); }); }); integrationTest.directory = `${PROJECT_DIR}/test/integration`; let integrationClobber = task('integrationClobber', function () { proc.execSync('rm -rf package.json pkg tmp_publish'); }); integrationClobber.directory = `${PROJECT_DIR}/test/integration`; let unitTest = task('unit', async function () { let testArgs = []; if (process.env.filter) { testArgs.push(process.env.filter); } else { testArgs.push('*.js'); } let spawned = proc.spawn(`${PROJECT_DIR}/node_modules/.bin/mocha`, testArgs, { stdio: 'inherit' }); }); unitTest.directory = `${PROJECT_DIR}/test/unit`; }); desc('Runs all tests'); task('test', ['test:unit', 'test:integration', 'test:integrationClobber']); jake-10.8.5/lib/000077500000000000000000000000001422765143500132765ustar00rootroot00000000000000jake-10.8.5/lib/api.js000066400000000000000000000276701422765143500144210ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let { uuid } = require('./utils'); let api = new (function () { /** @name task @static @function @description Creates a Jake Task ` @param {String} name The name of the Task @param {Array} [prereqs] Prerequisites to be run before this task @param {Function} [action] The action to perform for this task @param {Object} [opts] @param {Boolean} [opts.asyc=false] Perform this task asynchronously. If you flag a task with this option, you must call the global `complete` method inside the task's action, for execution to proceed to the next task. @example desc('This is the default task.'); task('default', function (params) { console.log('This is the default task.'); }); desc('This task has prerequisites.'); task('hasPrereqs', ['foo', 'bar', 'baz'], function (params) { console.log('Ran some prereqs first.'); }); desc('This is an asynchronous task.'); task('asyncTask', function () { setTimeout(complete, 1000); }, {async: true}); */ this.task = function (name, prereqs, action, opts) { let args = Array.prototype.slice.call(arguments); let createdTask; args.unshift('task'); createdTask = jake.createTask.apply(global, args); jake.currentTaskDescription = null; return createdTask; }; /** @name rule @static @function @description Creates a Jake Suffix Rule ` @param {String} pattern The suffix name of the objective @param {String} source The suffix name of the objective @param {Array} [prereqs] Prerequisites to be run before this task @param {Function} [action] The action to perform for this task @param {Object} [opts] @param {Boolean} [opts.asyc=false] Perform this task asynchronously. If you flag a task with this option, you must call the global `complete` method inside the task's action, for execution to proceed to the next task. @example desc('This is a rule, which does not support namespace or pattern.'); rule('.o', '.c', {async: true}, function () { let cmd = util.format('gcc -o %s %s', this.name, this.source); jake.exec([cmd], function () { complete(); }, {printStdout: true}); }); desc('This rule has prerequisites.'); rule('.o', '.c', ['util.h'], {async: true}, function () { let cmd = util.format('gcc -o %s %s', this.name, this.source); jake.exec([cmd], function () { complete(); }, {printStdout: true}); }); desc('This is a rule with patterns.'); rule('%.o', '%.c', {async: true}, function () { let cmd = util.format('gcc -o %s %s', this.name, this.source); jake.exec([cmd], function () { complete(); }, {printStdout: true}); }); desc('This is another rule with patterns.'); rule('obj/%.o', 'src/%.c', {async: true}, function () { let cmd = util.format('gcc -o %s %s', this.name, this.source); jake.exec([cmd], function () { complete(); }, {printStdout: true}); }); desc('This is an example with chain rules.'); rule('%.pdf', '%.dvi', {async: true}, function () { let cmd = util.format('dvipdfm %s',this.source); jake.exec([cmd], function () { complete(); }, {printStdout: true}); }); rule('%.dvi', '%.tex', {async: true}, function () { let cmd = util.format('latex %s',this.source); jake.exec([cmd], function () { complete(); }, {printStdout: true}); }); desc('This rule has a namespace.'); task('default', ['debug:obj/main.o]); namespace('debug', {async: true}, function() { rule('obj/%.o', 'src/%.c', function () { // ... }); } */ this.rule = function () { let args = Array.prototype.slice.call(arguments); let arg; let pattern = args.shift(); let source = args.shift(); let prereqs = []; let action = function () {}; let opts = {}; let key = pattern.toString(); // May be a RegExp while ((arg = args.shift())) { if (typeof arg == 'function') { action = arg; } else if (Array.isArray(arg)) { prereqs = arg; } else { opts = arg; } } jake.currentNamespace.rules[key] = new jake.Rule({ pattern: pattern, source: source, prereqs: prereqs, action: action, opts: opts, desc: jake.currentTaskDescription, ns: jake.currentNamespace }); jake.currentTaskDescription = null; }; /** @name directory @static @function @description Creates a Jake DirectoryTask. Can be used as a prerequisite for FileTasks, or for simply ensuring a directory exists for use with a Task's action. ` @param {String} name The name of the DiretoryTask @example // Creates the package directory for distribution directory('pkg'); */ this.directory = function (name) { let args = Array.prototype.slice.call(arguments); let createdTask; args.unshift('directory'); createdTask = jake.createTask.apply(global, args); jake.currentTaskDescription = null; return createdTask; }; /** @name file @static @function @description Creates a Jake FileTask. ` @param {String} name The name of the FileTask @param {Array} [prereqs] Prerequisites to be run before this task @param {Function} [action] The action to create this file, if it doesn't exist already. @param {Object} [opts] @param {Array} [opts.asyc=false] Perform this task asynchronously. If you flag a task with this option, you must call the global `complete` method inside the task's action, for execution to proceed to the next task. */ this.file = function (name, prereqs, action, opts) { let args = Array.prototype.slice.call(arguments); let createdTask; args.unshift('file'); createdTask = jake.createTask.apply(global, args); jake.currentTaskDescription = null; return createdTask; }; /** @name desc @static @function @description Creates a description for a Jake Task (or FileTask, DirectoryTask). When invoked, the description that iscreated will be associated with whatever Task is created next. ` @param {String} description The description for the Task */ this.desc = function (description) { jake.currentTaskDescription = description; }; /** @name namespace @static @function @description Creates a namespace which allows logical grouping of tasks, and prevents name-collisions with task-names. Namespaces can be nested inside of other namespaces. ` @param {String} name The name of the namespace @param {Function} scope The enclosing scope for the namespaced tasks @example namespace('doc', function () { task('generate', ['doc:clobber'], function () { // Generate some docs }); task('clobber', function () { // Clobber the doc directory first }); }); */ this.namespace = function (name, closure) { let curr = jake.currentNamespace; let ns = curr.childNamespaces[name] || new jake.Namespace(name, curr); let fn = closure || function () {}; curr.childNamespaces[name] = ns; jake.currentNamespace = ns; fn(); jake.currentNamespace = curr; jake.currentTaskDescription = null; return ns; }; /** @name complete @static @function @description Completes an asynchronous task, allowing Jake's execution to proceed to the next task. Calling complete globally or without arguments completes the last task on the invocationChain. If you use parallel execution of prereqs this will probably complete a wrong task. You should call this function with this task as the first argument, before the optional return value. Alternatively you can call task.complete() ` @example task('generate', ['doc:clobber'], function () { exec('./generate_docs.sh', function (err, stdout, stderr) { if (err || stderr) { fail(err || stderr); } else { console.log(stdout); complete(); } }); }, {async: true}); */ this.complete = function (task, val) { //this should detect if the first arg is a task, but I guess it should be more thorough if(task && task. _currentPrereqIndex >=0 ) { task.complete(val); } else { val = task; if(jake._invocationChain.length > 0) { jake._invocationChain[jake._invocationChain.length-1].complete(val); } } }; /** @name fail @static @function @description Causes Jake execution to abort with an error. Allows passing an optional error code, which will be used to set the exit-code of exiting process. ` @param {Error|String} err The error to thow when aborting execution. If this argument is an Error object, it will simply be thrown. If a String, it will be used as the error-message. (If it is a multi-line String, the first line will be used as the Error message, and the remaining lines will be used as the error-stack.) @example task('createTests, function () { if (!fs.existsSync('./tests')) { fail('Test directory does not exist.'); } else { // Do some testing stuff ... } }); */ this.fail = function (err, code) { let msg; let errObj; if (code) { jake.errorCode = code; } if (err) { if (typeof err == 'string') { // Use the initial or only line of the error as the error-message // If there was a multi-line error, use the rest as the stack msg = err.split('\n'); errObj = new Error(msg.shift()); if (msg.length) { errObj.stack = msg.join('\n'); } throw errObj; } else if (err instanceof Error) { throw err; } else { throw new Error(err.toString()); } } else { throw new Error(); } }; this.packageTask = function (name, version, prereqs, definition) { return new jake.PackageTask(name, version, prereqs, definition); }; this.publishTask = function (name, prereqs, opts, definition) { return new jake.PublishTask(name, prereqs, opts, definition); }; // Backward-compat this.npmPublishTask = function (name, prereqs, opts, definition) { return new jake.PublishTask(name, prereqs, opts, definition); }; this.testTask = function () { let ctor = function () {}; let t; ctor.prototype = jake.TestTask.prototype; t = new ctor(); jake.TestTask.apply(t, arguments); return t; }; this.setTaskTimeout = function (t) { this._taskTimeout = t; }; this.setSeriesAutoPrefix = function (prefix) { this._seriesAutoPrefix = prefix; }; this.series = function (...args) { let prereqs = args.map((arg) => { let name = (this._seriesAutoPrefix || '') + arg.name; jake.task(name, arg); return name; }); let seriesName = uuid(); let seriesTask = jake.task(seriesName, prereqs); seriesTask._internal = true; let res = function () { return new Promise((resolve) => { seriesTask.invoke(); seriesTask.on('complete', (val) => { resolve(val); }); }); }; Object.defineProperty(res, 'name', {value: uuid(), writable: false}); return res; }; })(); module.exports = api; jake-10.8.5/lib/jake.js000066400000000000000000000227411422765143500145540ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ if (!global.jake) { let EventEmitter = require('events').EventEmitter; // And so it begins global.jake = new EventEmitter(); let fs = require('fs'); let chalk = require('chalk'); let taskNs = require('./task'); let Task = taskNs.Task; let FileTask = taskNs.FileTask; let DirectoryTask = taskNs.DirectoryTask; let Rule = require('./rule').Rule; let Namespace = require('./namespace').Namespace; let RootNamespace = require('./namespace').RootNamespace; let api = require('./api'); let utils = require('./utils'); let Program = require('./program').Program; let loader = require('./loader')(); let pkg = JSON.parse(fs.readFileSync(__dirname + '/../package.json').toString()); const MAX_RULE_RECURSION_LEVEL = 16; // Globalize jake and top-level API methods (e.g., `task`, `desc`) Object.assign(global, api); // Copy utils onto base jake jake.logger = utils.logger; jake.exec = utils.exec; // File utils should be aliased directly on base jake as well Object.assign(jake, utils.file); // Also add top-level API methods to exported object for those who don't want to // use the globals (`file` here will overwrite the 'file' utils namespace) Object.assign(jake, api); Object.assign(jake, new (function () { this._invocationChain = []; this._taskTimeout = 30000; // Public properties // ================= this.version = pkg.version; // Used when Jake exits with a specific error-code this.errorCode = null; // Loads Jakefiles/jakelibdirs this.loader = loader; // The root of all ... namespaces this.rootNamespace = new RootNamespace(); // Non-namespaced tasks are placed into the default this.defaultNamespace = this.rootNamespace; // Start in the default this.currentNamespace = this.defaultNamespace; // Saves the description created by a 'desc' call that prefaces a // 'task' call that defines a task. this.currentTaskDescription = null; this.program = new Program(); this.FileList = require('filelist').FileList; this.PackageTask = require('./package_task').PackageTask; this.PublishTask = require('./publish_task').PublishTask; this.TestTask = require('./test_task').TestTask; this.Task = Task; this.FileTask = FileTask; this.DirectoryTask = DirectoryTask; this.Namespace = Namespace; this.Rule = Rule; this.parseAllTasks = function () { let _parseNs = function (ns) { let nsTasks = ns.tasks; let nsNamespaces = ns.childNamespaces; for (let q in nsTasks) { let nsTask = nsTasks[q]; jake.Task[nsTask.fullName] = nsTask; } for (let p in nsNamespaces) { let nsNamespace = nsNamespaces[p]; _parseNs(nsNamespace); } }; _parseNs(jake.defaultNamespace); }; /** * Displays the list of descriptions available for tasks defined in * a Jakefile */ this.showAllTaskDescriptions = function (f) { let p; let maxTaskNameLength = 0; let task; let padding; let name; let descr; let filter = typeof f == 'string' ? f : null; let taskParams; let len; for (p in jake.Task) { if (!Object.prototype.hasOwnProperty.call(jake.Task, p)) { continue; } if (filter && p.indexOf(filter) == -1) { continue; } task = jake.Task[p]; taskParams = task.params; // Record the length of the longest task name -- used for // pretty alignment of the task descriptions if (task.description) { len = p.length + taskParams.length; maxTaskNameLength = len > maxTaskNameLength ? len : maxTaskNameLength; } } // Print out each entry with descriptions neatly aligned for (p in jake.Task) { if (!Object.prototype.hasOwnProperty.call(jake.Task, p)) { continue; } if (filter && p.indexOf(filter) == -1) { continue; } task = jake.Task[p]; taskParams = ""; if (task.params != "") { taskParams = "[" + task.params + "]"; } //name = '\033[32m' + p + '\033[39m '; name = chalk.green(p); descr = task.description; if (descr) { descr = chalk.gray('# ' + descr); // Create padding-string with calculated length padding = (new Array(maxTaskNameLength - p.length - taskParams.length + 4)).join(' '); console.log('jake ' + name + taskParams + padding + descr); } } }; this.createTask = function () { let args = Array.prototype.slice.call(arguments); let arg; let obj; let task; let type; let name; let action; let opts = {}; let prereqs = []; type = args.shift(); // name, [deps], [action] // Name (string) + deps (array) format if (typeof args[0] == 'string') { name = args.shift(); if (Array.isArray(args[0])) { prereqs = args.shift(); } } // name:deps, [action] // Legacy object-literal syntax, e.g.: {'name': ['depA', 'depB']} else { obj = args.shift(); for (let p in obj) { prereqs = prereqs.concat(obj[p]); name = p; } } // Optional opts/callback or callback/opts while ((arg = args.shift())) { if (typeof arg == 'function') { action = arg; } else { opts = Object.assign(Object.create(null), arg); } } task = jake.currentNamespace.resolveTask(name); if (task && !action) { // Task already exists and no action, just update prereqs, and return it. task.prereqs = task.prereqs.concat(prereqs); return task; } switch (type) { case 'directory': action = function () { jake.mkdirP(name); }; task = new DirectoryTask(name, prereqs, action, opts); break; case 'file': task = new FileTask(name, prereqs, action, opts); break; default: task = new Task(name, prereqs, action, opts); } jake.currentNamespace.addTask(task); if (jake.currentTaskDescription) { task.description = jake.currentTaskDescription; jake.currentTaskDescription = null; } // FIXME: Should only need to add a new entry for the current // task-definition, not reparse the entire structure jake.parseAllTasks(); return task; }; this.attemptRule = function (name, ns, level) { let prereqRule; let prereq; if (level > MAX_RULE_RECURSION_LEVEL) { return null; } // Check Rule prereqRule = ns.matchRule(name); if (prereqRule) { prereq = prereqRule.createTask(name, level); } return prereq || null; }; this.createPlaceholderFileTask = function (name, namespace) { let parsed = name.split(':'); let filePath = parsed.pop(); // Strip any namespace let task; task = namespace.resolveTask(name); // If there's not already an existing dummy FileTask for it, // create one if (!task) { // Create a dummy FileTask only if file actually exists if (fs.existsSync(filePath)) { task = new jake.FileTask(filePath); task.dummy = true; let ns; if (parsed.length) { ns = namespace.resolveNamespace(parsed.join(':')); } else { ns = namespace; } if (!namespace) { throw new Error('Invalid namespace, cannot add FileTask'); } ns.addTask(task); // Put this dummy Task in the global Tasks list so // modTime will be eval'd correctly jake.Task[`${ns.path}:${filePath}`] = task; } } return task || null; }; this.run = function () { let args = Array.prototype.slice.call(arguments); let program = this.program; let loader = this.loader; let preempt; let opts; program.parseArgs(args); program.init(); preempt = program.firstPreemptiveOption(); if (preempt) { preempt(); } else { opts = program.opts; // jakefile flag set but no jakefile yet if (opts.autocomplete && opts.jakefile === true) { process.stdout.write('no-complete'); return; } // Load Jakefile and jakelibdir files let jakefileLoaded = loader.loadFile(opts.jakefile); let jakelibdirLoaded = loader.loadDirectory(opts.jakelibdir); if(!jakefileLoaded && !jakelibdirLoaded && !opts.autocomplete) { fail('No Jakefile. Specify a valid path with -f/--jakefile, ' + 'or place one in the current directory.'); } program.run(); } }; })()); } module.exports = jake; jake-10.8.5/lib/loader.js000066400000000000000000000104731422765143500151070ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let path = require('path'); let fs = require('fs'); let existsSync = fs.existsSync; let utils = require('./utils'); // Files like jakelib/foobar.jake.js const JAKELIB_FILE_PAT = /\.jake$|\.js$/; const SUPPORTED_EXTENSIONS = { 'js': null, 'coffee': function () { try { let cs = require('coffeescript'); if (typeof cs.register == 'function') { cs.register(); } } catch(e) { throw new Error('You have a CoffeeScript Jakefile, but have not installed CoffeeScript'); } }, 'ls': function () { try { require('livescript'); } catch (e) { throw new Error('You have a LiveScript Jakefile, but have not installed LiveScript'); } }, 'ts': function () { try { require('ts-node/register/transpile-only'); } catch (e) { throw new Error('You have a TypeScript Jakefile, but have not installed TypeScript and ts-node'); } } }; const IMPLICIT_JAKEFILE_NAMES = [ 'Jakefile', 'Gulpfile' ]; let Loader = function () { // Load a Jakefile, running the code inside -- this may result in // tasks getting defined using the original Jake API, e.g., // `task('foo' ['bar', 'baz']);`, or can also auto-create tasks // from any functions exported from the file function loadFile(filePath) { let exported = require(filePath); for (let [key, value] of Object.entries(exported)) { let t; if (typeof value == 'function') { t = jake.task(key, value); t.description = '(Exported function)'; } } } function fileExists(name) { let nameWithExt = null; // Support no file extension as well let exts = Object.keys(SUPPORTED_EXTENSIONS).concat(['']); exts.some((ext) => { let fname = ext ? `${name}.${ext}` : name; if (existsSync(fname)) { nameWithExt = fname; return true; } }); return nameWithExt; } // Recursive function findImplicitJakefile() { let cwd = process.cwd(); let names = IMPLICIT_JAKEFILE_NAMES; let found = null; names.some((name) => { let n; // Prefer all-lowercase n = name.toLowerCase(); if ((found = fileExists(n))) { return found; } // Check mixed-case as well n = name; if ((found = fileExists(n))) { return found; } }); if (found) { return found; } else { process.chdir(".."); // If we've walked all the way up the directory tree, // bail out with no result if (cwd === process.cwd()) { return null; } return findImplicitJakefile(); } } this.loadFile = function (fileSpecified) { let jakefile; let origCwd = process.cwd(); if (fileSpecified) { if (existsSync(fileSpecified)) { jakefile = fileSpecified; } } else { jakefile = findImplicitJakefile(); } if (jakefile) { let ext = jakefile.split('.')[1]; let loaderFunc = SUPPORTED_EXTENSIONS[ext]; loaderFunc && loaderFunc(); loadFile(utils.file.absolutize(jakefile)); return true; } else { if (!fileSpecified) { // Restore the working directory on failure process.chdir(origCwd); } return false; } }; this.loadDirectory = function (d) { let dirname = d || 'jakelib'; let dirlist; dirname = utils.file.absolutize(dirname); if (existsSync(dirname)) { dirlist = fs.readdirSync(dirname); dirlist.forEach(function (filePath) { if (JAKELIB_FILE_PAT.test(filePath)) { loadFile(path.join(dirname, filePath)); } }); return true; } return false; }; }; module.exports = function () { return new Loader(); }; jake-10.8.5/lib/namespace.js000066400000000000000000000046251422765143500155770ustar00rootroot00000000000000const ROOT_NAMESPACE_NAME = '__rootNamespace__'; class Namespace { constructor(name, parentNamespace) { this.name = name; this.parentNamespace = parentNamespace; this.childNamespaces = {}; this.tasks = {}; this.rules = {}; this.path = this.getPath(); } get fullName() { return this._getFullName(); } addTask(task) { this.tasks[task.name] = task; task.namespace = this; } resolveTask(name) { if (!name) { return; } let taskPath = name.split(':'); let taskName = taskPath.pop(); let task; let ns; // Namespaced, return either relative to current, or from root if (taskPath.length) { taskPath = taskPath.join(':'); ns = this.resolveNamespace(taskPath) || Namespace.ROOT_NAMESPACE.resolveNamespace(taskPath); task = (ns && ns.resolveTask(taskName)); } // Bare task, return either local, or top-level else { task = this.tasks[name] || Namespace.ROOT_NAMESPACE.tasks[name]; } return task || null; } resolveNamespace(relativeName) { if (!relativeName) { return this; } let parts = relativeName.split(':'); let ns = this; for (let i = 0, ii = parts.length; (ns && i < ii); i++) { ns = ns.childNamespaces[parts[i]]; } return ns || null; } matchRule(relativeName) { let parts = relativeName.split(':'); parts.pop(); let ns = this.resolveNamespace(parts.join(':')); let rules = ns ? ns.rules : []; let r; let match; for (let p in rules) { r = rules[p]; if (r.match(relativeName)) { match = r; } } return (ns && match) || (this.parentNamespace && this.parentNamespace.matchRule(relativeName)); } getPath() { let parts = []; let next = this.parentNamespace; while (next) { parts.push(next.name); next = next.parentNamespace; } parts.pop(); // Remove '__rootNamespace__' return parts.reverse().join(':'); } _getFullName() { let path = this.path; path = (path && path.split(':')) || []; path.push(this.name); return path.join(':'); } isRootNamespace() { return !this.parentNamespace; } } class RootNamespace extends Namespace { constructor() { super(ROOT_NAMESPACE_NAME, null); Namespace.ROOT_NAMESPACE = this; } } module.exports.Namespace = Namespace; module.exports.RootNamespace = RootNamespace; jake-10.8.5/lib/package_task.js000066400000000000000000000253741422765143500162640ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let path = require('path'); let fs = require('fs'); let exec = require('child_process').exec; let FileList = require('filelist').FileList; /** @name jake @namespace jake */ /** @name jake.PackageTask @constructor @description Instantiating a PackageTask creates a number of Jake Tasks that make packaging and distributing your software easy. @param {String} name The name of the project @param {String} version The current project version (will be appended to the project-name in the package-archive @param {Function} definition Defines the contents of the package, and format of the package-archive. Will be executed on the instantiated PackageTask (i.e., 'this', will be the PackageTask instance), to set the various instance-propertiess. @example let t = new jake.PackageTask('rous', 'v' + version, function () { let files = [ 'Capfile' , 'Jakefile' , 'README.md' , 'package.json' , 'app/*' , 'bin/*' , 'config/*' , 'lib/*' , 'node_modules/*' ]; this.packageFiles.include(files); this.packageFiles.exclude('node_modules/foobar'); this.needTarGz = true; }); */ let PackageTask = function () { let args = Array.prototype.slice.call(arguments); let name = args.shift(); let version = args.shift(); let definition = args.pop(); let prereqs = args.pop() || []; // Optional prereqs = [].concat(prereqs); // Accept string or list /** @name jake.PackageTask#name @public @type {String} @description The name of the project */ this.name = name; /** @name jake.PackageTask#version @public @type {String} @description The project version-string */ this.version = version; /** @name jake.PackageTask#prereqs @public @type {Array} @description Tasks to run before packaging */ this.prereqs = prereqs; /** @name jake.PackageTask#packageDir @public @type {String='pkg'} @description The directory-name to use for packaging the software */ this.packageDir = 'pkg'; /** @name jake.PackageTask#packageFiles @public @type {jake.FileList} @description The list of files and directories to include in the package-archive */ this.packageFiles = new FileList(); /** @name jake.PackageTask#needTar @public @type {Boolean=false} @description If set to true, uses the `tar` utility to create a gzip .tgz archive of the package */ this.needTar = false; /** @name jake.PackageTask#needTarGz @public @type {Boolean=false} @description If set to true, uses the `tar` utility to create a gzip .tar.gz archive of the package */ this.needTarGz = false; /** @name jake.PackageTask#needTarBz2 @public @type {Boolean=false} @description If set to true, uses the `tar` utility to create a bzip2 .bz2 archive of the package */ this.needTarBz2 = false; /** @name jake.PackageTask#needJar @public @type {Boolean=false} @description If set to true, uses the `jar` utility to create a .jar archive of the package */ this.needJar = false; /** @name jake.PackageTask#needZip @public @type {Boolean=false} @description If set to true, uses the `zip` utility to create a .zip archive of the package */ this.needZip = false; /** @name jake.PackageTask#manifestFile @public @type {String=null} @description Can be set to point the `jar` utility at a manifest file to use in a .jar archive. If unset, one will be automatically created by the `jar` utility. This path should be relative to the root of the package directory (this.packageDir above, likely 'pkg') */ this.manifestFile = null; /** @name jake.PackageTask#tarCommand @public @type {String='tar'} @description The shell-command to use for creating tar archives. */ this.tarCommand = 'tar'; /** @name jake.PackageTask#jarCommand @public @type {String='jar'} @description The shell-command to use for creating jar archives. */ this.jarCommand = 'jar'; /** @name jake.PackageTask#zipCommand @public @type {String='zip'} @description The shell-command to use for creating zip archives. */ this.zipCommand = 'zip'; /** @name jake.PackageTask#archiveNoBaseDir @public @type {Boolean=false} @description Simple option for performing the archive on the contents of the directory instead of the directory itself */ this.archiveNoBaseDir = false; /** @name jake.PackageTask#archiveChangeDir @public @type {String=null} @description Equivalent to the '-C' command for the `tar` and `jar` commands. ("Change to this directory before adding files.") */ this.archiveChangeDir = null; /** @name jake.PackageTask#archiveContentDir @public @type {String=null} @description Specifies the files and directories to include in the package-archive. If unset, this will default to the main package directory -- i.e., name + version. */ this.archiveContentDir = null; if (typeof definition == 'function') { definition.call(this); } this.define(); }; PackageTask.prototype = new (function () { let _compressOpts = { Tar: { ext: '.tgz', flags: 'czf', cmd: 'tar' }, TarGz: { ext: '.tar.gz', flags: 'czf', cmd: 'tar' }, TarBz2: { ext: '.tar.bz2', flags: 'cjf', cmd: 'tar' }, Jar: { ext: '.jar', flags: 'cf', cmd: 'jar' }, Zip: { ext: '.zip', flags: 'qr', cmd: 'zip' } }; this.define = function () { let self = this; let packageDirPath = this.packageDirPath(); let compressTaskArr = []; desc('Build the package for distribution'); task('package', self.prereqs.concat(['clobberPackage', 'buildPackage'])); // Backward-compat alias task('repackage', ['package']); task('clobberPackage', function () { jake.rmRf(self.packageDir, {silent: true}); }); desc('Remove the package'); task('clobber', ['clobberPackage']); let doCommand = function (p) { let filename = path.resolve(self.packageDir + '/' + self.packageName() + _compressOpts[p].ext); if (process.platform == 'win32') { // Windows full path may have drive letter, which is going to cause // namespace problems, so strip it. if (filename.length > 2 && filename[1] == ':') { filename = filename.substr(2); } } compressTaskArr.push(filename); file(filename, [packageDirPath], function () { let cmd; let opts = _compressOpts[p]; // Directory to move to when doing the compression-task // Changes in the case of zip for emulating -C option let chdir = self.packageDir; // Save the current dir so it's possible to pop back up // after compressing let currDir = process.cwd(); let archiveChangeDir; let archiveContentDir; if (self.archiveNoBaseDir) { archiveChangeDir = self.packageName(); archiveContentDir = '.'; } else { archiveChangeDir = self.archiveChangeDir; archiveContentDir = self.archiveContentDir; } cmd = self[opts.cmd + 'Command']; cmd += ' -' + opts.flags; if (opts.cmd == 'jar' && self.manifestFile) { cmd += 'm'; } // The name of the archive to create -- use full path // so compression can be performed from a different dir // if needed cmd += ' ' + filename; if (opts.cmd == 'jar' && self.manifestFile) { cmd += ' ' + self.manifestFile; } // Where to perform the compression -- -C option isn't // supported in zip, so actually do process.chdir for this if (archiveChangeDir) { if (opts.cmd == 'zip') { chdir = path.join(chdir, archiveChangeDir); } else { cmd += ' -C ' + archiveChangeDir; } } // Where to get the archive content if (archiveContentDir) { cmd += ' ' + archiveContentDir; } else { cmd += ' ' + self.packageName(); } // Move into the desired dir (usually packageDir) to compress // Return back up to the current dir after the exec process.chdir(chdir); exec(cmd, function (err, stdout, stderr) { if (err) { throw err; } // Return back up to the starting directory (see above, // before exec) process.chdir(currDir); complete(); }); }, {async: true}); }; for (let p in _compressOpts) { if (this['need' + p]) { doCommand(p); } } task('buildPackage', compressTaskArr, function () {}); directory(this.packageDir); file(packageDirPath, this.packageFiles, function () { jake.mkdirP(packageDirPath); let fileList = []; self.packageFiles.forEach(function (name) { let f = path.join(self.packageDirPath(), name); let fDir = path.dirname(f); jake.mkdirP(fDir, {silent: true}); // Add both files and directories fileList.push({ from: name, to: f }); }); let _copyFile = function () { let file = fileList.pop(); let stat; if (file) { stat = fs.statSync(file.from); // Target is a directory, just create it if (stat.isDirectory()) { jake.mkdirP(file.to, {silent: true}); _copyFile(); } // Otherwise copy the file else { jake.cpR(file.from, file.to, {silent: true}); _copyFile(); } } else { complete(); } }; _copyFile(); }, {async: true}); }; this.packageName = function () { if (this.version) { return this.name + '-' + this.version; } else { return this.name; } }; this.packageDirPath = function () { return this.packageDir + '/' + this.packageName(); }; })(); jake.PackageTask = PackageTask; exports.PackageTask = PackageTask; jake-10.8.5/lib/parseargs.js000066400000000000000000000072511422765143500156300ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let parseargs = {}; let isOpt = function (arg) { return arg.indexOf('-') === 0 }; let removeOptPrefix = function (opt) { return opt.replace(/^--/, '').replace(/^-/, '') }; /** * @constructor * Parses a list of command-line args into a key/value object of * options and an array of positional commands. * @ param {Array} opts A list of options in the following format: * [{full: 'foo', abbr: 'f'}, {full: 'bar', abbr: 'b'}]] */ parseargs.Parser = function (opts) { // A key/value object of matching options parsed out of the args this.opts = {}; this.taskNames = null; this.envVars = null; // Data structures used for parsing this.reg = opts; this.shortOpts = {}; this.longOpts = {}; let self = this; [].forEach.call(opts, function (item) { self.shortOpts[item.abbr] = item; self.longOpts[item.full] = item; }); }; parseargs.Parser.prototype = new function () { let _trueOrNextVal = function (argParts, args) { if (argParts[1]) { return argParts[1]; } else { return (!args[0] || isOpt(args[0])) ? true : args.shift(); } }; /** * Parses an array of arguments into options and positional commands * @param {Array} args The command-line args to parse */ this.parse = function (args) { let cmds = []; let cmd; let envVars = {}; let opts = {}; let arg; let argItem; let argParts; let cmdItems; let taskNames = []; let preempt; while (args.length) { arg = args.shift(); if (isOpt(arg)) { arg = removeOptPrefix(arg); argParts = arg.split('='); argItem = this.longOpts[argParts[0]] || this.shortOpts[argParts[0]]; if (argItem) { // First-encountered preemptive opt takes precedence -- no further opts // or possibility of ambiguity, so just look for a value, or set to // true and then bail if (argItem.preempts) { opts[argItem.full] = _trueOrNextVal(argParts, args); preempt = true; break; } // If the opt requires a value, see if we can get a value from the // next arg, or infer true from no-arg -- if it's followed by another // opt, throw an error if (argItem.expectValue || argItem.allowValue) { opts[argItem.full] = _trueOrNextVal(argParts, args); if (argItem.expectValue && !opts[argItem.full]) { throw new Error(argItem.full + ' option expects a value.'); } } else { opts[argItem.full] = true; } } } else { cmds.unshift(arg); } } if (!preempt) { // Parse out any env-vars and task-name while ((cmd = cmds.pop())) { cmdItems = cmd.split('='); if (cmdItems.length > 1) { envVars[cmdItems[0]] = cmdItems[1]; } else { taskNames.push(cmd); } } } return { opts: opts, envVars: envVars, taskNames: taskNames }; }; }; module.exports = parseargs; jake-10.8.5/lib/program.js000066400000000000000000000146201422765143500153060ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let fs = require('fs'); let parseargs = require('./parseargs'); let utils = require('./utils'); let Program; let usage = require('fs').readFileSync(`${__dirname}/../usage.txt`).toString(); let { Task } = require('./task/task'); function die(msg) { console.log(msg); process.stdout.write('', function () { process.stderr.write('', function () { process.exit(); }); }); } let preempts = { version: function () { die(jake.version); }, help: function () { die(usage); } }; let AVAILABLE_OPTS = [ { full: 'jakefile', abbr: 'f', expectValue: true }, { full: 'quiet', abbr: 'q', expectValue: false }, { full: 'directory', abbr: 'C', expectValue: true }, { full: 'always-make', abbr: 'B', expectValue: false }, { full: 'tasks', abbr: 'T', expectValue: false, allowValue: true }, // Alias t { full: 'tasks', abbr: 't', expectValue: false, allowValue: true }, // Alias ls { full: 'tasks', abbr: 'ls', expectValue: false, allowValue: true }, { full: 'help', abbr: 'h', }, { full: 'version', abbr: 'V', }, // Alias lowercase v { full: 'version', abbr: 'v', }, { full: 'jakelibdir', abbr: 'J', expectValue: true }, { full: 'allow-rejection', abbr: 'ar', expectValue: false } ]; Program = function () { this.availableOpts = AVAILABLE_OPTS; this.opts = {}; this.taskNames = null; this.taskArgs = null; this.envVars = null; this.die = die; }; Program.prototype = new (function () { this.handleErr = function (err) { if (jake.listeners('error').length !== 0) { jake.emit('error', err); return; } if (jake.listeners('error').length) { jake.emit('error', err); return; } utils.logger.error('jake aborted.'); if (err.stack) { utils.logger.error(err.stack); } else { utils.logger.error(err.message); } process.stdout.write('', function () { process.stderr.write('', function () { jake.errorCode = jake.errorCode || 1; process.exit(jake.errorCode); }); }); }; this.parseArgs = function (args) { let result = (new parseargs.Parser(this.availableOpts)).parse(args); this.setOpts(result.opts); this.setTaskNames(result.taskNames); this.setEnvVars(result.envVars); }; this.setOpts = function (options) { let opts = options || {}; Object.assign(this.opts, opts); }; this.internalOpts = function (options) { this.availableOpts = this.availableOpts.concat(options); }; this.autocompletions = function (cur) { let p; let i; let task; let commonPrefix = ''; let matches = []; for (p in jake.Task) { task = jake.Task[p]; if ( 'fullName' in task && ( // if empty string, program converts to true cur === true || task.fullName.indexOf(cur) === 0 ) ) { if (matches.length === 0) { commonPrefix = task.fullName; } else { for (i = commonPrefix.length; i > -1; --i) { commonPrefix = commonPrefix.substr(0, i); if (task.fullName.indexOf(commonPrefix) === 0) { break; } } } matches.push(task.fullName); } } if (matches.length > 1 && commonPrefix === cur) { matches.unshift('yes-space'); } else { matches.unshift('no-space'); } process.stdout.write(matches.join(' ')); }; this.setTaskNames = function (names) { if (names && !Array.isArray(names)) { throw new Error('Task names must be an array'); } this.taskNames = (names && names.length) ? names : ['default']; }; this.setEnvVars = function (vars) { this.envVars = vars || null; }; this.firstPreemptiveOption = function () { let opts = this.opts; for (let p in opts) { if (preempts[p]) { return preempts[p]; } } return false; }; this.init = function (configuration) { let self = this; let config = configuration || {}; if (config.options) { this.setOpts(config.options); } if (config.taskNames) { this.setTaskNames(config.taskNames); } if (config.envVars) { this.setEnvVars(config.envVars); } process.addListener('uncaughtException', function (err) { self.handleErr(err); }); if (!this.opts['allow-rejection']) { process.addListener('unhandledRejection', (reason, promise) => { utils.logger.error('Unhandled rejection at:', promise, 'reason:', reason); self.handleErr(reason); }); } if (this.envVars) { Object.assign(process.env, this.envVars); } }; this.run = function () { let rootTask; let taskNames; let dirname; let opts = this.opts; if (opts.autocomplete) { return this.autocompletions(opts['autocomplete-cur'], opts['autocomplete-prev']); } // Run with `jake -T`, just show descriptions if (opts.tasks) { return jake.showAllTaskDescriptions(opts.tasks); } taskNames = this.taskNames; if (!(Array.isArray(taskNames) && taskNames.length)) { throw new Error('Please pass jake.runTasks an array of task-names'); } // Set working dir dirname = opts.directory; if (dirname) { if (fs.existsSync(dirname) && fs.statSync(dirname).isDirectory()) { process.chdir(dirname); } else { throw new Error(dirname + ' is not a valid directory path'); } } rootTask = task(Task.ROOT_TASK_NAME, taskNames, function () {}); rootTask._internal = true; rootTask.once('complete', function () { jake.emit('complete'); }); jake.emit('start'); rootTask.invoke(); }; })(); module.exports.Program = Program; jake-10.8.5/lib/publish_task.js000066400000000000000000000215671422765143500163370ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let fs = require('fs'); let path = require('path'); let exec = require('child_process').execSync; let FileList = require('filelist').FileList; let PublishTask = function () { let args = Array.prototype.slice.call(arguments).filter(function (item) { return typeof item != 'undefined'; }); let arg; let opts = {}; let definition; let prereqs = []; let createDef = function (arg) { return function () { this.packageFiles.include(arg); }; }; this.name = args.shift(); // Old API, just name + list of files if (args.length == 1 && (Array.isArray(args[0]) || typeof args[0] == 'string')) { definition = createDef(args.pop()); } // Current API, name + [prereqs] + [opts] + definition else { while ((arg = args.pop())) { // Definition func if (typeof arg == 'function') { definition = arg; } // Prereqs else if (Array.isArray(arg) || typeof arg == 'string') { prereqs = arg; } // Opts else { opts = arg; } } } this.prereqs = prereqs; this.packageFiles = new FileList(); this.publishCmd = opts.publishCmd || 'npm publish %filename'; this.publishMessage = opts.publishMessage || 'BOOM! Published.'; this.gitCmd = opts.gitCmd || 'git'; this.versionFiles = opts.versionFiles || ['package.json']; this.scheduleDelay = 5000; // Override utility funcs for testing this._ensureRepoClean = function (stdout) { if (stdout.length) { fail(new Error('Git repository is not clean.')); } }; this._getCurrentBranch = function (stdout) { return String(stdout).trim(); }; if (typeof definition == 'function') { definition.call(this); } this.define(); }; PublishTask.prototype = new (function () { let _currentBranch = null; let getPackage = function () { let pkg = JSON.parse(fs.readFileSync(path.join(process.cwd(), '/package.json')).toString()); return pkg; }; let getPackageVersionNumber = function () { return getPackage().version; }; this.define = function () { let self = this; namespace('publish', function () { task('fetchTags', function () { // Make sure local tags are up to date exec(self.gitCmd + ' fetch --tags'); console.log('Fetched remote tags.'); }); task('getCurrentBranch', function () { // Figure out what branch to push to let stdout = exec(self.gitCmd + ' symbolic-ref --short HEAD').toString(); if (!stdout) { throw new Error('No current Git branch found'); } _currentBranch = self._getCurrentBranch(stdout); console.log('On branch ' + _currentBranch); }); task('ensureClean', function () { // Only bump, push, and tag if the Git repo is clean let stdout = exec(self.gitCmd + ' status --porcelain --untracked-files=no').toString(); // Throw if there's output self._ensureRepoClean(stdout); }); task('updateVersionFiles', function () { let pkg; let version; let arr; let patch; // Grab the current version-string pkg = getPackage(); version = pkg.version; // Increment the patch-number for the version arr = version.split('.'); patch = parseInt(arr.pop(), 10) + 1; arr.push(patch); version = arr.join('.'); // Update package.json or other files with the new version-info self.versionFiles.forEach(function (file) { let p = path.join(process.cwd(), file); let data = JSON.parse(fs.readFileSync(p).toString()); data.version = version; fs.writeFileSync(p, JSON.stringify(data, true, 2) + '\n'); }); // Return the version string so that listeners for the 'complete' event // for this task can use it (e.g., to update other files before pushing // to Git) return version; }); task('pushVersion', ['ensureClean', 'updateVersionFiles'], function () { let version = getPackageVersionNumber(); let message = 'Version ' + version; let cmds = [ self.gitCmd + ' commit -a -m "' + message + '"', self.gitCmd + ' push origin ' + _currentBranch, self.gitCmd + ' tag -a v' + version + ' -m "' + message + '"', self.gitCmd + ' push --tags' ]; cmds.forEach((cmd) => { exec(cmd); }); version = getPackageVersionNumber(); console.log('Bumped version number to v' + version + '.'); }); let defineTask = task('definePackage', function () { let version = getPackageVersionNumber(); new jake.PackageTask(self.name, 'v' + version, self.prereqs, function () { // Replace the PackageTask's FileList with the PublishTask's FileList this.packageFiles = self.packageFiles; this.needTarGz = true; // Default to tar.gz // If any of the need or archive opts are set // proxy them to the PackageTask for (let p in this) { if (p.indexOf('need') === 0 || p.indexOf('archive') === 0) { if (typeof self[p] != 'undefined') { this[p] = self[p]; } } } }); }); defineTask._internal = true; task('package', function () { let definePack = jake.Task['publish:definePackage']; let pack = jake.Task['package']; let version = getPackageVersionNumber(); // May have already been run if (definePack.taskStatus == jake.Task.runStatuses.DONE) { definePack.reenable(true); } definePack.execute(); definePack.on('complete', function () { pack.invoke(); console.log('Created package for ' + self.name + ' v' + version); }); }); task('publish', function () { return new Promise((resolve) => { let version = getPackageVersionNumber(); let filename; let cmd; console.log('Publishing ' + self.name + ' v' + version); if (typeof self.createPublishCommand == 'function') { cmd = self.createPublishCommand(version); } else { filename = './pkg/' + self.name + '-v' + version + '.tar.gz'; cmd = self.publishCmd.replace(/%filename/gi, filename); } if (typeof cmd == 'function') { cmd(function (err) { if (err) { throw err; } console.log(self.publishMessage); resolve(); }); } else { // Hackity hack -- NPM publish sometimes returns errror like: // Error sending version data\nnpm ERR! // Error: forbidden 0.2.4 is modified, should match modified time setTimeout(function () { let stdout = exec(cmd).toString() || ''; stdout = stdout.trim(); if (stdout) { console.log(stdout); } console.log(self.publishMessage); resolve(); }, self.scheduleDelay); } }); }); task('cleanup', function () { return new Promise((resolve) => { let clobber = jake.Task.clobber; clobber.reenable(true); clobber.on('complete', function () { console.log('Cleaned up package'); resolve(); }); clobber.invoke(); }); }); }); let prefixNs = function (item) { return 'publish:' + item; }; // Create aliases in the default namespace desc('Create a new version and release.'); task('publish', self.prereqs.concat(['version', 'release'] .map(prefixNs))); desc('Release the existing version.'); task('publishExisting', self.prereqs.concat(['release'] .map(prefixNs))); task('version', ['fetchTags', 'getCurrentBranch', 'pushVersion'] .map(prefixNs)); task('release', ['package', 'publish', 'cleanup'] .map(prefixNs)); // Invoke proactively so there will be a callable 'package' task // which can be used apart from 'publish' jake.Task['publish:definePackage'].invoke(); }; })(); jake.PublishTask = PublishTask; exports.PublishTask = PublishTask; jake-10.8.5/lib/rule.js000066400000000000000000000173011422765143500146050ustar00rootroot00000000000000let path = require('path'); let fs = require('fs'); let Task = require('./task/task').Task; // Split a task to two parts, name space and task name. // For example, given 'foo:bin/a%.c', return an object with // - 'ns' : foo // - 'name' : bin/a%.c function splitNs(task) { let parts = task.split(':'); let name = parts.pop(); let ns = resolveNs(parts); return { 'name' : name, 'ns' : ns }; } // Return the namespace based on an array of names. // For example, given ['foo', 'baz' ], return the namespace // // default -> foo -> baz // // where default is the global root namespace // and -> means child namespace. function resolveNs(parts) { let ns = jake.defaultNamespace; for(let i = 0, l = parts.length; ns && i < l; i++) { ns = ns.childNamespaces[parts[i]]; } return ns; } // Given a pattern p, say 'foo:bin/a%.c' // Return an object with // - 'ns' : foo // - 'dir' : bin // - 'prefix' : a // - 'suffix' : .c function resolve(p) { let task = splitNs(p); let name = task.name; let ns = task.ns; let split = path.basename(name).split('%'); return { ns: ns, dir: path.dirname(name), prefix: split[0], suffix: split[1] }; } // Test whether string a is a suffix of string b function stringEndWith(a, b) { let l; return (l = b.lastIndexOf(a)) == -1 ? false : l + a.length == b.length; } // Replace the suffix a of the string s with b. // Note that, it is assumed a is a suffix of s. function stringReplaceSuffix(s, a, b) { return s.slice(0, s.lastIndexOf(a)) + b; } class Rule { constructor(opts) { this.pattern = opts.pattern; this.source = opts.source; this.prereqs = opts.prereqs; this.action = opts.action; this.opts = opts.opts; this.desc = opts.desc; this.ns = opts.ns; } // Create a file task based on this rule for the specified // task-name // ====== // FIXME: Right now this just throws away any passed-in args // for the synthsized task (taskArgs param) // ====== createTask(fullName, level) { let self = this; let pattern; let source; let action; let opts; let prereqs; let valid; let src; let tNs; let createdTask; let name = Task.getBaseTaskName(fullName); let nsPath = Task.getBaseNamespacePath(fullName); let ns = this.ns.resolveNamespace(nsPath); pattern = this.pattern; source = this.source; if (typeof source == 'string') { src = Rule.getSource(name, pattern, source); } else { src = source(name); } // TODO: Write a utility function that appends a // taskname to a namespace path src = nsPath.split(':').filter(function (item) { return !!item; }).concat(src).join(':'); // Generate the prerequisite for the matching task. // It is the original prerequisites plus the prerequisite // representing source file, i.e., // // rule( '%.o', '%.c', ['some.h'] ... // // If the objective is main.o, then new task should be // // file( 'main.o', ['main.c', 'some.h' ] ... prereqs = this.prereqs.slice(); // Get a copy to work with prereqs.unshift(src); // Prereq should be: // 1. an existing task // 2. an existing file on disk // 3. a valid rule (i.e., not at too deep a level) valid = prereqs.some(function (p) { let ns = self.ns; return ns.resolveTask(p) || fs.existsSync(Task.getBaseTaskName(p)) || jake.attemptRule(p, ns, level + 1); }); // If any of the prereqs aren't valid, the rule isn't valid if (!valid) { return null; } // Otherwise, hunky-dory, finish creating the task for the rule else { // Create the action for the task action = function () { let task = this; self.action.apply(task); }; opts = this.opts; // Insert the file task into Jake // // Since createTask function stores the task as a child task // of currentNamespace. Here we temporariliy switch the namespace. // FIXME: Should allow optional ns passed in instead of this hack tNs = jake.currentNamespace; jake.currentNamespace = ns; createdTask = jake.createTask('file', name, prereqs, action, opts); createdTask.source = src.split(':').pop(); jake.currentNamespace = tNs; return createdTask; } } match(name) { return Rule.match(this.pattern, name); } // Test wether the a prerequisite matchs the pattern. // The arg 'pattern' does not have namespace as prefix. // For example, the following tests are true // // pattern | name // bin/%.o | bin/main.o // bin/%.o | foo:bin/main.o // // The following tests are false (trivally) // // pattern | name // bin/%.o | foobin/main.o // bin/%.o | bin/main.oo static match(pattern, name) { let p; let task; let obj; let filename; if (pattern instanceof RegExp) { return pattern.test(name); } else if (pattern.indexOf('%') == -1) { // No Pattern. No Folder. No Namespace. // A Simple Suffix Rule. Just test suffix return stringEndWith(pattern, name); } else { // Resolve the dir, prefix and suffix of pattern p = resolve(pattern); // Resolve the namespace and task-name task = splitNs(name); name = task.name; // Set the objective as the task-name obj = name; // Namespace is already matched. // Check dir if (path.dirname(obj) != p.dir) { return false; } filename = path.basename(obj); // Check file name length if ((p.prefix.length + p.suffix.length + 1) > filename.length) { // Length does not match. return false; } // Check prefix if (filename.indexOf(p.prefix) !== 0) { return false; } // Check suffix if (!stringEndWith(p.suffix, filename)) { return false; } // OK. Find a match. return true; } } // Generate the source based on // - name name for the synthesized task // - pattern pattern for the objective // - source pattern for the source // // Return the source with properties // - dep the prerequisite of source // (with the namespace) // // - file the file name of source // (without the namespace) // // For example, given // // - name foo:bin/main.o // - pattern bin/%.o // - source src/%.c // // return 'foo:src/main.c', // static getSource(name, pattern, source) { let dep; let pat; let match; let file; let src; // Regex pattern -- use to look up the extension if (pattern instanceof RegExp) { match = pattern.exec(name); if (match) { if (typeof source == 'function') { src = source(name); } else { src = stringReplaceSuffix(name, match[0], source); } } } // Assume string else { // Simple string suffix replacement if (pattern.indexOf('%') == -1) { if (typeof source == 'function') { src = source(name); } else { src = stringReplaceSuffix(name, pattern, source); } } // Percent-based substitution else { pat = pattern.replace('%', '(.*?)'); pat = new RegExp(pat); match = pat.exec(name); if (match) { if (typeof source == 'function') { src = source(name); } else { file = match[1]; file = source.replace('%', file); dep = match[0]; src = name.replace(dep, file); } } } } return src; } } exports.Rule = Rule; jake-10.8.5/lib/task/000077500000000000000000000000001422765143500142405ustar00rootroot00000000000000jake-10.8.5/lib/task/directory_task.js000066400000000000000000000010771422765143500176310ustar00rootroot00000000000000let fs = require('fs'); let FileTask = require('./file_task').FileTask; /** @name jake @namespace jake */ /** @name jake.DirectoryTask @constructor @augments EventEmitter @augments jake.Task @augments jake.FileTask @description A Jake DirectoryTask @param {String} name The name of the directory to create. */ class DirectoryTask extends FileTask { constructor(...args) { super(...args); if (fs.existsSync(this.name)) { this.updateModTime(); } else { this.modTime = null; } } } exports.DirectoryTask = DirectoryTask; jake-10.8.5/lib/task/file_task.js000066400000000000000000000063521422765143500165450ustar00rootroot00000000000000let fs = require('fs'); let Task = require('./task').Task; function isFileOrDirectory(t) { return (t instanceof FileTask || t instanceof DirectoryTask); } function isFile(t) { return (t instanceof FileTask && !(t instanceof DirectoryTask)); } /** @name jake @namespace jake */ /** @name jake.FileTask @class` @extentds Task @description A Jake FileTask @param {String} name The name of the Task @param {Array} [prereqs] Prerequisites to be run before this task @param {Function} [action] The action to perform to create this file @param {Object} [opts] @param {Array} [opts.asyc=false] Perform this task asynchronously. If you flag a task with this option, you must call the global `complete` method inside the task's action, for execution to proceed to the next task. */ class FileTask extends Task { constructor(...args) { super(...args); this.dummy = false; if (fs.existsSync(this.name)) { this.updateModTime(); } else { this.modTime = null; } } isNeeded() { let prereqs = this.prereqs; let prereqName; let prereqTask; // No repeatsies if (this.taskStatus == Task.runStatuses.DONE) { return false; } // The always-make override else if (jake.program.opts['always-make']) { return true; } // Default case else { // We need either an existing file, or an action to create one. // First try grabbing the actual mod-time of the file try { this.updateModTime(); } // Then fall back to looking for an action catch(e) { if (typeof this.action == 'function') { return true; } else { throw new Error('File-task ' + this.fullName + ' has no ' + 'existing file, and no action to create one.'); } } // Compare mod-time of all the prereqs with its mod-time // If any prereqs are newer, need to run the action to update if (prereqs && prereqs.length) { for (let i = 0, ii = prereqs.length; i < ii; i++) { prereqName = prereqs[i]; prereqTask = this.namespace.resolveTask(prereqName) || jake.createPlaceholderFileTask(prereqName, this.namespace); // Run the action if: // 1. The prereq is a normal task (not file/dir) // 2. The prereq is a file-task with a mod-date more recent than // the one for this file/dir if (prereqTask) { if (!isFileOrDirectory(prereqTask) || (isFile(prereqTask) && prereqTask.modTime > this.modTime)) { return true; } } } } // File/dir has no prereqs, and exists -- no need to run else { // Effectively done this.taskStatus = Task.runStatuses.DONE; return false; } } } updateModTime() { let stats = fs.statSync(this.name); this.modTime = stats.mtime; } complete() { if (!this.dummy) { this.updateModTime(); } // Hackity hack Task.prototype.complete.apply(this, arguments); } } exports.FileTask = FileTask; // DirectoryTask is a subclass of FileTask, depends on it // being defined let DirectoryTask = require('./directory_task').DirectoryTask; jake-10.8.5/lib/task/index.js000066400000000000000000000003561422765143500157110ustar00rootroot00000000000000 let Task = require('./task').Task; let FileTask = require('./file_task').FileTask; let DirectoryTask = require('./directory_task').DirectoryTask; exports.Task = Task; exports.FileTask = FileTask; exports.DirectoryTask = DirectoryTask; jake-10.8.5/lib/task/task.js000066400000000000000000000277431422765143500155550ustar00rootroot00000000000000let EventEmitter = require('events').EventEmitter; let async = require('async'); let chalk = require('chalk'); // 'rule' module is required at the bottom because circular deps // Used for task value, so better not to use // null, since value should be unset/uninitialized let UNDEFINED_VALUE; const ROOT_TASK_NAME = '__rootTask__'; const POLLING_INTERVAL = 100; // Parse any positional args attached to the task-name function parsePrereqName(name) { let taskArr = name.split('['); let taskName = taskArr[0]; let taskArgs = []; if (taskArr[1]) { taskArgs = taskArr[1].replace(/\]$/, ''); taskArgs = taskArgs.split(','); } return { name: taskName, args: taskArgs }; } /** @name jake.Task @class @extends EventEmitter @description A Jake Task @param {String} name The name of the Task @param {Array} [prereqs] Prerequisites to be run before this task @param {Function} [action] The action to perform for this task @param {Object} [opts] @param {Array} [opts.asyc=false] Perform this task asynchronously. If you flag a task with this option, you must call the global `complete` method inside the task's action, for execution to proceed to the next task. */ class Task extends EventEmitter { constructor(name, prereqs, action, options) { // EventEmitter ctor takes no args super(); if (name.indexOf(':') > -1) { throw new Error('Task name cannot include a colon. It is used internally as namespace delimiter.'); } let opts = options || {}; this._currentPrereqIndex = 0; this._internal = false; this._skipped = false; this.name = name; this.prereqs = prereqs; this.action = action; this.async = false; this.taskStatus = Task.runStatuses.UNSTARTED; this.description = null; this.args = []; this.value = UNDEFINED_VALUE; this.concurrency = 1; this.startTime = null; this.endTime = null; this.directory = null; this.namespace = null; // Support legacy async-flag -- if not explicitly passed or falsy, will // be set to empty-object if (typeof opts == 'boolean' && opts === true) { this.async = true; } else { if (opts.async) { this.async = true; } if (opts.concurrency) { this.concurrency = opts.concurrency; } } //Do a test on self dependencies for this task if(Array.isArray(this.prereqs) && this.prereqs.indexOf(this.name) !== -1) { throw new Error("Cannot use prereq " + this.name + " as a dependency of itself"); } } get fullName() { return this._getFullName(); } get params() { return this._getParams(); } _initInvocationChain() { // Legacy global invocation chain jake._invocationChain.push(this); // New root chain if (!this._invocationChain) { this._invocationChainRoot = true; this._invocationChain = []; if (jake.currentRunningTask) { jake.currentRunningTask._waitForChains = jake.currentRunningTask._waitForChains || []; jake.currentRunningTask._waitForChains.push(this._invocationChain); } } } /** @name jake.Task#invoke @function @description Runs prerequisites, then this task. If the task has already been run, will not run the task again. */ invoke() { this._initInvocationChain(); this.args = Array.prototype.slice.call(arguments); this.reenabled = false this.runPrereqs(); } /** @name jake.Task#execute @function @description Run only this task, without prereqs. If the task has already been run, *will* run the task again. */ execute() { this._initInvocationChain(); this.args = Array.prototype.slice.call(arguments); this.reenable(); this.reenabled = true this.run(); } runPrereqs() { if (this.prereqs && this.prereqs.length) { if (this.concurrency > 1) { async.eachLimit(this.prereqs, this.concurrency, (name, cb) => { let parsed = parsePrereqName(name); let prereq = this.namespace.resolveTask(parsed.name) || jake.attemptRule(name, this.namespace, 0) || jake.createPlaceholderFileTask(name, this.namespace); if (!prereq) { throw new Error('Unknown task "' + name + '"'); } //Test for circular invocation if(prereq === this) { setImmediate(function () { cb(new Error("Cannot use prereq " + prereq.name + " as a dependency of itself")); }); } if (prereq.taskStatus == Task.runStatuses.DONE) { //prereq already done, return setImmediate(cb); } else { //wait for complete before calling cb prereq.once('_done', () => { prereq.removeAllListeners('_done'); setImmediate(cb); }); // Start the prereq if we are the first to encounter it if (prereq.taskStatus === Task.runStatuses.UNSTARTED) { prereq.taskStatus = Task.runStatuses.STARTED; prereq.invoke.apply(prereq, parsed.args); } } }, (err) => { //async callback is called after all prereqs have run. if (err) { throw err; } else { setImmediate(this.run.bind(this)); } } ); } else { setImmediate(this.nextPrereq.bind(this)); } } else { setImmediate(this.run.bind(this)); } } nextPrereq() { let self = this; let index = this._currentPrereqIndex; let name = this.prereqs[index]; let prereq; let parsed; if (name) { parsed = parsePrereqName(name); prereq = this.namespace.resolveTask(parsed.name) || jake.attemptRule(name, this.namespace, 0) || jake.createPlaceholderFileTask(name, this.namespace); if (!prereq) { throw new Error('Unknown task "' + name + '"'); } // Do when done if (prereq.taskStatus == Task.runStatuses.DONE) { self.handlePrereqDone(prereq); } else { prereq.once('_done', () => { this.handlePrereqDone(prereq); prereq.removeAllListeners('_done'); }); if (prereq.taskStatus == Task.runStatuses.UNSTARTED) { prereq.taskStatus = Task.runStatuses.STARTED; prereq._invocationChain = this._invocationChain; prereq.invoke.apply(prereq, parsed.args); } } } } /** @name jake.Task#reenable @function @description Reenables a task so that it can be run again. */ reenable(deep) { let prereqs; let prereq; this._skipped = false; this.taskStatus = Task.runStatuses.UNSTARTED; this.value = UNDEFINED_VALUE; if (deep && this.prereqs) { prereqs = this.prereqs; for (let i = 0, ii = prereqs.length; i < ii; i++) { prereq = jake.Task[prereqs[i]]; if (prereq) { prereq.reenable(deep); } } } } handlePrereqDone(prereq) { this._currentPrereqIndex++; if (this._currentPrereqIndex < this.prereqs.length) { setImmediate(this.nextPrereq.bind(this)); } else { setImmediate(this.run.bind(this)); } } isNeeded() { let needed = true; if (this.taskStatus == Task.runStatuses.DONE) { needed = false; } return needed; } run() { let val, previous; let hasAction = typeof this.action == 'function'; if (!this.isNeeded()) { this.emit('skip'); this.emit('_done'); } else { if (this._invocationChain.length) { previous = this._invocationChain[this._invocationChain.length - 1]; // If this task is repeating and its previous is equal to this, don't check its status because it was set to UNSTARTED by the reenable() method if (!(this.reenabled && previous == this)) { if (previous.taskStatus != Task.runStatuses.DONE) { let now = (new Date()).getTime(); if (now - this.startTime > jake._taskTimeout) { return jake.fail(`Timed out waiting for task: ${previous.name} with status of ${previous.taskStatus}`); } setTimeout(this.run.bind(this), POLLING_INTERVAL); return; } } } if (!(this.reenabled && previous == this)) { this._invocationChain.push(this); } if (!(this._internal || jake.program.opts.quiet)) { console.log("Starting '" + chalk.green(this.fullName) + "'..."); } this.startTime = (new Date()).getTime(); this.emit('start'); jake.currentRunningTask = this; if (hasAction) { try { if (this.directory) { process.chdir(this.directory); } val = this.action.apply(this, this.args); if (typeof val == 'object' && typeof val.then == 'function') { this.async = true; val.then( (result) => { setImmediate(() => { this.complete(result); }); }, (err) => { setImmediate(() => { this.errorOut(err); }); }); } } catch (err) { this.errorOut(err); return; // Bail out, not complete } } if (!(hasAction && this.async)) { setImmediate(() => { this.complete(val); }); } } } errorOut(err) { this.taskStatus = Task.runStatuses.ERROR; this._invocationChain.chainStatus = Task.runStatuses.ERROR; this.emit('error', err); } complete(val) { if (Array.isArray(this._waitForChains)) { let stillWaiting = this._waitForChains.some((chain) => { return !(chain.chainStatus == Task.runStatuses.DONE || chain.chainStatus == Task.runStatuses.ERROR); }); if (stillWaiting) { let now = (new Date()).getTime(); let elapsed = now - this.startTime; if (elapsed > jake._taskTimeout) { return jake.fail(`Timed out waiting for task: ${this.name} with status of ${this.taskStatus}. Elapsed: ${elapsed}`); } setTimeout(() => { this.complete(val); }, POLLING_INTERVAL); return; } } jake._invocationChain.splice(jake._invocationChain.indexOf(this), 1); if (this._invocationChainRoot) { this._invocationChain.chainStatus = Task.runStatuses.DONE; } this._currentPrereqIndex = 0; // If 'complete' getting called because task has been // run already, value will not be passed -- leave in place if (!this._skipped) { this.taskStatus = Task.runStatuses.DONE; this.value = val; this.emit('complete', this.value); this.emit('_done'); this.endTime = (new Date()).getTime(); let taskTime = this.endTime - this.startTime; if (!(this._internal || jake.program.opts.quiet)) { console.log("Finished '" + chalk.green(this.fullName) + "' after " + chalk.magenta(taskTime + ' ms')); } } } _getFullName() { let ns = this.namespace; let path = (ns && ns.path) || ''; path = (path && path.split(':')) || []; if (this.namespace !== jake.defaultNamespace) { path.push(this.namespace.name); } path.push(this.name); return path.join(':'); } _getParams() { if (!this.action) return ""; let params = new RegExp('(?:'+this.action.name+'\\s*|^)\\s*\\((.*?)\\)').exec(this.action.toString().replace(/\n/g, ''))[1].replace(/\/\*.*?\*\//g, '').replace(/ /g, ''); return params; } static getBaseNamespacePath(fullName) { return fullName.split(':').slice(0, -1).join(':'); } static getBaseTaskName(fullName) { return fullName.split(':').pop(); } } Task.runStatuses = { UNSTARTED: 'unstarted', DONE: 'done', STARTED: 'started', ERROR: 'error' }; Task.ROOT_TASK_NAME = ROOT_TASK_NAME; exports.Task = Task; // Required here because circular deps require('../rule'); jake-10.8.5/lib/test_task.js000066400000000000000000000204421422765143500156370ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let path = require('path'); let currDir = process.cwd(); /** @name jake @namespace jake */ /** @name jake.TestTask @constructor @description Instantiating a TestTask creates a number of Jake Tasks that make running tests for your software easy. @param {String} name The name of the project @param {Function} definition Defines the list of files containing the tests, and the name of the namespace/task for running them. Will be executed on the instantiated TestTask (i.e., 'this', will be the TestTask instance), to set the various instance-propertiess. @example let t = new jake.TestTask('bij-js', function () { this.testName = 'testSpecial'; this.testFiles.include('test/**'); }); */ let TestTask = function () { let self = this; let args = Array.prototype.slice.call(arguments); let name = args.shift(); let definition = args.pop(); let prereqs = args.pop() || []; /** @name jake.TestTask#testNam @public @type {String} @description The name of the namespace to place the tests in, and the top-level task for running tests. Defaults to "test" */ this.testName = 'test'; /** @name jake.TestTask#testFiles @public @type {jake.FileList} @description The list of files containing tests to load */ this.testFiles = new jake.FileList(); /** @name jake.TestTask#showDescription @public @type {Boolean} @description Show the created task when doing Jake -T */ this.showDescription = true; /* @name jake.TestTask#totalTests @public @type {Number} @description The total number of tests to run */ this.totalTests = 0; /* @name jake.TestTask#executedTests @public @type {Number} @description The number of tests successfully run */ this.executedTests = 0; if (typeof definition == 'function') { definition.call(this); } if (this.showDescription) { desc('Run the tests for ' + name); } task(this.testName, prereqs, {async: true}, function () { let t = jake.Task[this.fullName + ':run']; t.on('complete', function () { complete(); }); // Pass args to the namespaced test t.invoke.apply(t, arguments); }); namespace(self.testName, function () { let runTask = task('run', {async: true}, function (pat) { let re; let testFiles; // Don't nest; make a top-level namespace. Don't want // re-calling from inside to nest infinitely jake.currentNamespace = jake.defaultNamespace; re = new RegExp(pat); // Get test files that match the passed-in pattern testFiles = self.testFiles.toArray() .filter(function (f) { return (re).test(f); }) // Don't load the same file multiple times -- should this be in FileList? .reduce(function (p, c) { if (p.indexOf(c) < 0) { p.push(c); } return p; }, []); // Create a namespace for all the testing tasks to live in namespace(self.testName + 'Exec', function () { // Each test will be a prereq for the dummy top-level task let prereqs = []; // Continuation to pass to the async tests, wrapping `continune` let next = function () { complete(); }; // Create the task for this test-function let createTask = function (name, action) { // If the test-function is defined with a continuation // param, flag the task as async let t; let isAsync = !!action.length; // Define the actual namespaced task with the name, the // wrapped action, and the correc async-flag t = task(name, createAction(name, action), { async: isAsync }); t.once('complete', function () { self.executedTests++; }); t._internal = true; return t; }; // Used as the action for the defined task for each test. let createAction = function (n, a) { // A wrapped function that passes in the `next` function // for any tasks that run asynchronously return function () { let cb; if (a.length) { cb = next; } if (!(n == 'before' || n == 'after' || /_beforeEach$/.test(n) || /_afterEach$/.test(n))) { jake.logger.log(n); } // 'this' will be the task when action is run return a.call(this, cb); }; }; // Dummy top-level task for everything to be prereqs for let topLevel; // Pull in each test-file, and iterate over any exported // test-functions. Register each test-function as a prereq task testFiles.forEach(function (file) { let exp = require(path.join(currDir, file)); // Create a namespace for each filename, so test-name collisions // won't be a problem namespace(file, function () { let testPrefix = self.testName + 'Exec:' + file + ':'; let testName; // Dummy task for displaying file banner testName = '*** Running ' + file + ' ***'; prereqs.push(testPrefix + testName); createTask(testName, function () {}); // 'before' setup if (typeof exp.before == 'function') { prereqs.push(testPrefix + 'before'); // Create the task createTask('before', exp.before); } // Walk each exported function, and create a task for each for (let p in exp) { if (p == 'before' || p == 'after' || p == 'beforeEach' || p == 'afterEach') { continue; } if (typeof exp.beforeEach == 'function') { prereqs.push(testPrefix + p + '_beforeEach'); // Create the task createTask(p + '_beforeEach', exp.beforeEach); } // Add the namespace:name of this test to the list of prereqs // for the dummy top-level task prereqs.push(testPrefix + p); // Create the task createTask(p, exp[p]); if (typeof exp.afterEach == 'function') { prereqs.push(testPrefix + p + '_afterEach'); // Create the task createTask(p + '_afterEach', exp.afterEach); } } // 'after' teardown if (typeof exp.after == 'function') { prereqs.push(testPrefix + 'after'); // Create the task let afterTask = createTask('after', exp.after); afterTask._internal = true; } }); }); self.totalTests = prereqs.length; process.on('exit', function () { // Throw in the case where the process exits without // finishing tests, but no error was thrown if (!jake.errorCode && (self.totalTests > self.executedTests)) { throw new Error('Process exited without all tests completing.'); } }); // Create the dummy top-level task. When calling a task internally // with `invoke` that is async (or has async prereqs), have to listen // for the 'complete' event to know when it's done topLevel = task('__top__', prereqs); topLevel._internal = true; topLevel.addListener('complete', function () { jake.logger.log('All tests ran successfully'); complete(); }); topLevel.invoke(); // Do the thing! }); }); runTask._internal = true; }); }; jake.TestTask = TestTask; exports.TestTask = TestTask; jake-10.8.5/lib/utils/000077500000000000000000000000001422765143500144365ustar00rootroot00000000000000jake-10.8.5/lib/utils/file.js000066400000000000000000000167541422765143500157300ustar00rootroot00000000000000/* * Utilities: A classic collection of JavaScript utilities * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let fs = require('fs'); let path = require('path'); /** @name file @namespace file */ let fileUtils = new (function () { // Recursively copy files and directories let _copyFile = function (fromPath, toPath, opts) { let from = path.normalize(fromPath) let to = path.normalize(toPath) let options = opts || {} let fromStat; let toStat; let destExists; let destDoesNotExistErr; let content; let filename; let dirContents; let targetDir; fromStat = fs.statSync(from); try { //console.dir(to + ' destExists'); toStat = fs.statSync(to); destExists = true; } catch(e) { //console.dir(to + ' does not exist'); destDoesNotExistErr = e; destExists = false; } // Destination dir or file exists, copy into (directory) // or overwrite (file) if (destExists) { // If there's a rename-via-copy file/dir name passed, use it. // Otherwise use the actual file/dir name filename = options.rename || path.basename(from); // Copying a directory if (fromStat.isDirectory()) { dirContents = fs.readdirSync(from); targetDir = path.join(to, filename); // We don't care if the target dir already exists try { fs.mkdirSync(targetDir, {mode: fromStat.mode & 0o777}); } catch(e) { if (e.code !== 'EEXIST') { throw e; } } for (let i = 0, ii = dirContents.length; i < ii; i++) { _copyFile(path.join(from, dirContents[i]), targetDir, {preserveMode: options.preserveMode}); } } // Copying a file else { content = fs.readFileSync(from); let mode = fromStat.mode & 0o777; let targetFile = to; if (toStat.isDirectory()) { targetFile = path.join(to, filename); } let fileExists = fs.existsSync(targetFile); fs.writeFileSync(targetFile, content); // If the file didn't already exist, use the original file mode. // Otherwise, only update the mode if preserverMode is true. if(!fileExists || options.preserveMode) { fs.chmodSync(targetFile, mode); } } } // Dest doesn't exist, can't create it else { throw destDoesNotExistErr; } }; // Remove the given directory let _rmDir = function (dirPath) { let dir = path.normalize(dirPath); let paths = []; paths = fs.readdirSync(dir); paths.forEach(function (p) { let curr = path.join(dir, p); let stat = fs.lstatSync(curr); if (stat.isDirectory()) { _rmDir(curr); } else { try { fs.unlinkSync(curr); } catch(e) { if (e.code === 'EPERM') { fs.chmodSync(curr, parseInt(666, 8)); fs.unlinkSync(curr); } else { throw e; } } } }); fs.rmdirSync(dir); }; /** @name file#cpR @public @function @description Copies a directory/file to a destination @param {String} fromPath The source path to copy from @param {String} toPath The destination path to copy to @param {Object} opts Options to use @param {Boolean} [opts.preserveMode] If target file already exists, this determines whether the original file's mode is copied over. The default of false mimics the behavior of the `cp` command line tool. (Default: false) */ this.cpR = function (fromPath, toPath, options) { let from = path.normalize(fromPath); let to = path.normalize(toPath); let toStat; let doesNotExistErr; let filename; let opts = options || {}; if (from == to) { throw new Error('Cannot copy ' + from + ' to itself.'); } // Handle rename-via-copy try { toStat = fs.statSync(to); } catch(e) { doesNotExistErr = e; // Get abs path so it's possible to check parent dir if (!this.isAbsolute(to)) { to = path.join(process.cwd(), to); } // Save the file/dir name filename = path.basename(to); // See if a parent dir exists, so there's a place to put the /// renamed file/dir (resets the destination for the copy) to = path.dirname(to); try { toStat = fs.statSync(to); } catch(e) {} if (toStat && toStat.isDirectory()) { // Set the rename opt to pass to the copy func, will be used // as the new file/dir name opts.rename = filename; //console.log('filename ' + filename); } else { throw doesNotExistErr; } } _copyFile(from, to, opts); }; /** @name file#mkdirP @public @function @description Create the given directory(ies) using the given mode permissions @param {String} dir The directory to create @param {Number} mode The mode to give the created directory(ies)(Default: 0755) */ this.mkdirP = function (dir, mode) { let dirPath = path.normalize(dir); let paths = dirPath.split(/\/|\\/); let currPath = ''; let next; if (paths[0] == '' || /^[A-Za-z]+:/.test(paths[0])) { currPath = paths.shift() || '/'; currPath = path.join(currPath, paths.shift()); //console.log('basedir'); } while ((next = paths.shift())) { if (next == '..') { currPath = path.join(currPath, next); continue; } currPath = path.join(currPath, next); try { //console.log('making ' + currPath); fs.mkdirSync(currPath, mode || parseInt(755, 8)); } catch(e) { if (e.code != 'EEXIST') { throw e; } } } }; /** @name file#rmRf @public @function @description Deletes the given directory/file @param {String} p The path to delete, can be a directory or file */ this.rmRf = function (p, options) { let stat; try { stat = fs.lstatSync(p); if (stat.isDirectory()) { _rmDir(p); } else { fs.unlinkSync(p); } } catch (e) {} }; /** @name file#isAbsolute @public @function @return {Boolean/String} If it's absolute the first character is returned otherwise false @description Checks if a given path is absolute or relative @param {String} p Path to check */ this.isAbsolute = function (p) { let match = /^[A-Za-z]+:\\|^\//.exec(p); if (match && match.length) { return match[0]; } return false; }; /** @name file#absolutize @public @function @return {String} Returns the absolute path for the given path @description Returns the absolute path for the given path @param {String} p The path to get the absolute path for */ this.absolutize = function (p) { if (this.isAbsolute(p)) { return p; } else { return path.join(process.cwd(), p); } }; })(); module.exports = fileUtils; jake-10.8.5/lib/utils/index.js000066400000000000000000000161521422765143500161100ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ let util = require('util'); // Native Node util module let spawn = require('child_process').spawn; let EventEmitter = require('events').EventEmitter; let logger = require('./logger'); let file = require('./file'); let Exec; const _UUID_CHARS = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz'.split(''); let parseArgs = function (argumentsObj) { let args; let arg; let cmds; let callback; let opts = { interactive: false, printStdout: false, printStderr: false, breakOnError: true }; args = Array.prototype.slice.call(argumentsObj); cmds = args.shift(); // Arrayize if passed a single string command if (typeof cmds == 'string') { cmds = [cmds]; } // Make a copy if it's an actual list else { cmds = cmds.slice(); } // Get optional callback or opts while((arg = args.shift())) { if (typeof arg == 'function') { callback = arg; } else if (typeof arg == 'object') { opts = Object.assign(opts, arg); } } // Backward-compat shim if (typeof opts.stdout != 'undefined') { opts.printStdout = opts.stdout; delete opts.stdout; } if (typeof opts.stderr != 'undefined') { opts.printStderr = opts.stderr; delete opts.stderr; } return { cmds: cmds, opts: opts, callback: callback }; }; /** @name jake @namespace jake */ let utils = new (function () { /** @name jake.exec @static @function @description Executes shell-commands asynchronously with an optional final callback. ` @param {String[]} cmds The list of shell-commands to execute @param {Object} [opts] @param {Boolean} [opts.printStdout=false] Print stdout from each command @param {Boolean} [opts.printStderr=false] Print stderr from each command @param {Boolean} [opts.breakOnError=true] Stop further execution on the first error. @param {Boolean} [opts.windowsVerbatimArguments=false] Don't translate arguments on Windows. @param {Function} [callback] Callback to run after executing the commands @example let cmds = [ 'echo "showing directories"' , 'ls -al | grep ^d' , 'echo "moving up a directory"' , 'cd ../' ] , callback = function () { console.log('Finished running commands.'); } jake.exec(cmds, {stdout: true}, callback); */ this.exec = function (a, b, c) { let parsed = parseArgs(arguments); let cmds = parsed.cmds; let opts = parsed.opts; let callback = parsed.callback; let ex = new Exec(cmds, opts, callback); ex.addListener('error', function (msg, code) { if (opts.breakOnError) { fail(msg, code); } }); ex.run(); return ex; }; this.createExec = function (a, b, c) { return new Exec(a, b, c); }; // From Math.uuid.js, https://github.com/broofa/node-uuid // Robert Kieffer (robert@broofa.com), MIT license this.uuid = function (length, radix) { var chars = _UUID_CHARS , uuid = [] , r , i; radix = radix || chars.length; if (length) { // Compact form i = -1; while (++i < length) { uuid[i] = chars[0 | Math.random()*radix]; } } else { // rfc4122, version 4 form // rfc4122 requires these characters uuid[8] = uuid[13] = uuid[18] = uuid[23] = '-'; uuid[14] = '4'; // Fill in random data. At i==19 set the high bits of clock sequence as // per rfc4122, sec. 4.1.5 i = -1; while (++i < 36) { if (!uuid[i]) { r = 0 | Math.random()*16; uuid[i] = chars[(i == 19) ? (r & 0x3) | 0x8 : r]; } } } return uuid.join(''); }; })(); Exec = function () { let parsed = parseArgs(arguments); let cmds = parsed.cmds; let opts = parsed.opts; let callback = parsed.callback; this._cmds = cmds; this._callback = callback; this._config = opts; }; util.inherits(Exec, EventEmitter); Object.assign(Exec.prototype, new (function () { let _run = function () { let self = this; let sh; let cmd; let args; let next = this._cmds.shift(); let config = this._config; let errData = ''; let shStdio; let handleStdoutData = function (data) { self.emit('stdout', data); }; let handleStderrData = function (data) { let d = data.toString(); self.emit('stderr', data); // Accumulate the error-data so we can use it as the // stack if the process exits with an error errData += d; }; // Keep running as long as there are commands in the array if (next) { let spawnOpts = {}; this.emit('cmdStart', next); // Ganking part of Node's child_process.exec to get cmdline args parsed if (process.platform == 'win32') { cmd = 'cmd'; args = ['/c', next]; if (config.windowsVerbatimArguments) { spawnOpts.windowsVerbatimArguments = true; } } else { cmd = '/bin/sh'; args = ['-c', next]; } if (config.interactive) { spawnOpts.stdio = 'inherit'; sh = spawn(cmd, args, spawnOpts); } else { shStdio = [ process.stdin ]; if (config.printStdout) { shStdio.push(process.stdout); } else { shStdio.push('pipe'); } if (config.printStderr) { shStdio.push(process.stderr); } else { shStdio.push('pipe'); } spawnOpts.stdio = shStdio; sh = spawn(cmd, args, spawnOpts); if (!config.printStdout) { sh.stdout.addListener('data', handleStdoutData); } if (!config.printStderr) { sh.stderr.addListener('data', handleStderrData); } } // Exit, handle err or run next sh.on('exit', function (code) { let msg; if (code !== 0) { msg = errData || 'Process exited with error.'; msg = msg.trim(); self.emit('error', msg, code); } if (code === 0 || !config.breakOnError) { self.emit('cmdEnd', next); setTimeout(function () { _run.call(self); }, 0); } }); } else { self.emit('end'); if (typeof self._callback == 'function') { self._callback(); } } }; this.append = function (cmd) { this._cmds.push(cmd); }; this.run = function () { _run.call(this); }; })()); utils.Exec = Exec; utils.file = file; utils.logger = logger; module.exports = utils; jake-10.8.5/lib/utils/logger.js000066400000000000000000000007711422765143500162600ustar00rootroot00000000000000let util = require('util'); let logger = new (function () { let _output = function (type, out) { let quiet = typeof jake != 'undefined' && jake.program && jake.program.opts && jake.program.opts.quiet; let msg; if (!quiet) { msg = typeof out == 'string' ? out : util.inspect(out); console[type](msg); } }; this.log = function (out) { _output('log', out); }; this.error = function (out) { _output('error', out); }; })(); module.exports = logger; jake-10.8.5/package-lock.json000066400000000000000000004733251422765143500157620ustar00rootroot00000000000000{ "name": "jake", "version": "10.8.4", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "jake", "version": "10.8.4", "license": "Apache-2.0", "dependencies": { "async": "^3.2.3", "chalk": "^4.0.2", "filelist": "^1.0.1", "minimatch": "^3.0.4" }, "bin": { "jake": "bin/cli.js" }, "devDependencies": { "eslint": "^6.8.0", "mocha": "^7.1.1", "q": "^1.5.1" }, "engines": { "node": ">=10" } }, "node_modules/@babel/code-frame": { "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.8.3.tgz", "integrity": "sha512-a9gxpmdXtZEInkCSHUJDLHZVBgb1QS0jhss4cPP93EW7s+uC5bikET2twEF3KV+7rDblJcmNvTR7VJejqd2C2g==", "dev": true, "dependencies": { "@babel/highlight": "^7.8.3" } }, "node_modules/@babel/helper-validator-identifier": { "version": "7.9.5", "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.9.5.tgz", "integrity": "sha512-/8arLKUFq882w4tWGj9JYzRpAlZgiWUJ+dtteNTDqrRBz9Iguck9Rn3ykuBDoUwh2TO4tSAJlrxDUOXWklJe4g==", "dev": true }, "node_modules/@babel/highlight": { "version": "7.9.0", "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.9.0.tgz", "integrity": "sha512-lJZPilxX7Op3Nv/2cvFdnlepPXDxi29wxteT57Q965oc5R9v86ztx0jfxVrTcBk8C2kcPkkDa2Z4T3ZsPPVWsQ==", "dev": true, "dependencies": { "@babel/helper-validator-identifier": "^7.9.0", "chalk": "^2.0.0", "js-tokens": "^4.0.0" } }, "node_modules/@babel/highlight/node_modules/chalk": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "dependencies": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", "supports-color": "^5.3.0" }, "engines": { "node": ">=4" } }, "node_modules/@babel/highlight/node_modules/supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "dependencies": { "has-flag": "^3.0.0" }, "engines": { "node": ">=4" } }, "node_modules/@types/color-name": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", "dev": true }, "node_modules/acorn": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.1.1.tgz", "integrity": "sha512-add7dgA5ppRPxCFJoAGfMDi7PIBXq1RtGo7BhbLaxwrXPOmw8gq48Y9ozT01hUKy9byMjlR20EJhu5zlkErEkg==", "dev": true, "bin": { "acorn": "bin/acorn" }, "engines": { "node": ">=0.4.0" } }, "node_modules/acorn-jsx": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.2.0.tgz", "integrity": "sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ==", "dev": true, "peerDependencies": { "acorn": "^6.0.0 || ^7.0.0" } }, "node_modules/ajv": { "version": "6.12.6", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", "dev": true, "dependencies": { "fast-deep-equal": "^3.1.1", "fast-json-stable-stringify": "^2.0.0", "json-schema-traverse": "^0.4.1", "uri-js": "^4.2.2" }, "funding": { "type": "github", "url": "https://github.com/sponsors/epoberezkin" } }, "node_modules/ansi-colors": { "version": "3.2.3", "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-3.2.3.tgz", "integrity": "sha512-LEHHyuhlPY3TmuUYMh2oz89lTShfvgbmzaBcxve9t/9Wuy7Dwf4yoAKcND7KFT1HAQfqZ12qtc+DUrBMeKF9nw==", "dev": true, "engines": { "node": ">=6" } }, "node_modules/ansi-escapes": { "version": "4.3.1", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.1.tgz", "integrity": "sha512-JWF7ocqNrp8u9oqpgV+wH5ftbt+cfvv+PTjOvKLT3AdYly/LmORARfEVT1iyjwN+4MqE5UmVKoAdIBqeoCHgLA==", "dev": true, "dependencies": { "type-fest": "^0.11.0" }, "engines": { "node": ">=8" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/ansi-escapes/node_modules/type-fest": { "version": "0.11.0", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.11.0.tgz", "integrity": "sha512-OdjXJxnCN1AvyLSzeKIgXTXxV+99ZuXl3Hpo9XpJAv9MBcHrrJOQ5kV7ypXOuQie+AmWG25hLbiKdwYTifzcfQ==", "dev": true, "engines": { "node": ">=8" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/ansi-regex": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", "dev": true, "engines": { "node": ">=8" } }, "node_modules/ansi-styles": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "dependencies": { "color-convert": "^1.9.0" }, "engines": { "node": ">=4" } }, "node_modules/anymatch": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", "dev": true, "dependencies": { "normalize-path": "^3.0.0", "picomatch": "^2.0.4" }, "engines": { "node": ">= 8" } }, "node_modules/argparse": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", "dev": true, "dependencies": { "sprintf-js": "~1.0.2" } }, "node_modules/astral-regex": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz", "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==", "dev": true, "engines": { "node": ">=4" } }, "node_modules/async": { "version": "3.2.3", "resolved": "https://registry.npmjs.org/async/-/async-3.2.3.tgz", "integrity": "sha512-spZRyzKL5l5BZQrr/6m/SqFdBN0q3OCI0f9rjfBzCMBIP4p75P620rR3gTmaksNOhmzgdxcaxdNfMy6anrbM0g==" }, "node_modules/balanced-match": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" }, "node_modules/binary-extensions": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.0.0.tgz", "integrity": "sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow==", "dev": true, "engines": { "node": ">=8" } }, "node_modules/brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" } }, "node_modules/braces": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", "dev": true, "dependencies": { "fill-range": "^7.0.1" }, "engines": { "node": ">=8" } }, "node_modules/browser-stdout": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", "dev": true }, "node_modules/callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", "dev": true, "engines": { "node": ">=6" } }, "node_modules/camelcase": { "version": "5.3.1", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", "dev": true, "engines": { "node": ">=6" } }, "node_modules/chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" }, "engines": { "node": ">=10" }, "funding": { "url": "https://github.com/chalk/chalk?sponsor=1" } }, "node_modules/chalk/node_modules/ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dependencies": { "color-convert": "^2.0.1" }, "engines": { "node": ">=8" }, "funding": { "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, "node_modules/chalk/node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dependencies": { "color-name": "~1.1.4" }, "engines": { "node": ">=7.0.0" } }, "node_modules/chalk/node_modules/color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" }, "node_modules/chardet": { "version": "0.7.0", "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", "dev": true }, "node_modules/chokidar": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.0.tgz", "integrity": "sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A==", "dev": true, "dependencies": { "anymatch": "~3.1.1", "braces": "~3.0.2", "glob-parent": "~5.1.0", "is-binary-path": "~2.1.0", "is-glob": "~4.0.1", "normalize-path": "~3.0.0", "readdirp": "~3.2.0" }, "engines": { "node": ">= 8.10.0" }, "optionalDependencies": { "fsevents": "~2.1.1" } }, "node_modules/cli-cursor": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", "dev": true, "dependencies": { "restore-cursor": "^3.1.0" }, "engines": { "node": ">=8" } }, "node_modules/cli-width": { "version": "2.2.1", "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-2.2.1.tgz", "integrity": "sha512-GRMWDxpOB6Dgk2E5Uo+3eEBvtOOlimMmpbFiKuLFnQzYDavtLFY3K5ona41jgN/WdRZtG7utuVSVTL4HbZHGkw==", "dev": true }, "node_modules/cliui": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", "dev": true, "dependencies": { "string-width": "^3.1.0", "strip-ansi": "^5.2.0", "wrap-ansi": "^5.1.0" } }, "node_modules/cliui/node_modules/emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, "node_modules/cliui/node_modules/is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/cliui/node_modules/string-width": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "dependencies": { "emoji-regex": "^7.0.1", "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^5.1.0" }, "engines": { "node": ">=6" } }, "node_modules/color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", "dev": true, "dependencies": { "color-name": "1.1.3" } }, "node_modules/color-name": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", "dev": true }, "node_modules/concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" }, "node_modules/cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", "dev": true, "dependencies": { "nice-try": "^1.0.4", "path-key": "^2.0.1", "semver": "^5.5.0", "shebang-command": "^1.2.0", "which": "^1.2.9" }, "engines": { "node": ">=4.8" } }, "node_modules/cross-spawn/node_modules/semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", "dev": true, "bin": { "semver": "bin/semver" } }, "node_modules/debug": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", "deprecated": "Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)", "dev": true, "dependencies": { "ms": "^2.1.1" } }, "node_modules/decamelize": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/deep-is": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=", "dev": true }, "node_modules/define-properties": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", "dev": true, "dependencies": { "object-keys": "^1.0.12" }, "engines": { "node": ">= 0.4" } }, "node_modules/diff": { "version": "3.5.0", "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz", "integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==", "dev": true, "engines": { "node": ">=0.3.1" } }, "node_modules/doctrine": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", "dev": true, "dependencies": { "esutils": "^2.0.2" }, "engines": { "node": ">=6.0.0" } }, "node_modules/emoji-regex": { "version": "8.0.0", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, "node_modules/es-abstract": { "version": "1.17.5", "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.5.tgz", "integrity": "sha512-BR9auzDbySxOcfog0tLECW8l28eRGpDpU3Dm3Hp4q/N+VtLTmyj4EUN088XZWQDW/hzj6sYRDXeOFsaAODKvpg==", "dev": true, "dependencies": { "es-to-primitive": "^1.2.1", "function-bind": "^1.1.1", "has": "^1.0.3", "has-symbols": "^1.0.1", "is-callable": "^1.1.5", "is-regex": "^1.0.5", "object-inspect": "^1.7.0", "object-keys": "^1.1.1", "object.assign": "^4.1.0", "string.prototype.trimleft": "^2.1.1", "string.prototype.trimright": "^2.1.1" }, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/es-to-primitive": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", "dev": true, "dependencies": { "is-callable": "^1.1.4", "is-date-object": "^1.0.1", "is-symbol": "^1.0.2" }, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/escape-string-regexp": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", "dev": true, "engines": { "node": ">=0.8.0" } }, "node_modules/eslint": { "version": "6.8.0", "resolved": "https://registry.npmjs.org/eslint/-/eslint-6.8.0.tgz", "integrity": "sha512-K+Iayyo2LtyYhDSYwz5D5QdWw0hCacNzyq1Y821Xna2xSJj7cijoLLYmLxTQgcgZ9mC61nryMy9S7GRbYpI5Ig==", "dev": true, "dependencies": { "@babel/code-frame": "^7.0.0", "ajv": "^6.10.0", "chalk": "^2.1.0", "cross-spawn": "^6.0.5", "debug": "^4.0.1", "doctrine": "^3.0.0", "eslint-scope": "^5.0.0", "eslint-utils": "^1.4.3", "eslint-visitor-keys": "^1.1.0", "espree": "^6.1.2", "esquery": "^1.0.1", "esutils": "^2.0.2", "file-entry-cache": "^5.0.1", "functional-red-black-tree": "^1.0.1", "glob-parent": "^5.0.0", "globals": "^12.1.0", "ignore": "^4.0.6", "import-fresh": "^3.0.0", "imurmurhash": "^0.1.4", "inquirer": "^7.0.0", "is-glob": "^4.0.0", "js-yaml": "^3.13.1", "json-stable-stringify-without-jsonify": "^1.0.1", "levn": "^0.3.0", "lodash": "^4.17.14", "minimatch": "^3.0.4", "mkdirp": "^0.5.1", "natural-compare": "^1.4.0", "optionator": "^0.8.3", "progress": "^2.0.0", "regexpp": "^2.0.1", "semver": "^6.1.2", "strip-ansi": "^5.2.0", "strip-json-comments": "^3.0.1", "table": "^5.2.3", "text-table": "^0.2.0", "v8-compile-cache": "^2.0.3" }, "bin": { "eslint": "bin/eslint.js" }, "engines": { "node": "^8.10.0 || ^10.13.0 || >=11.10.1" }, "funding": { "url": "https://opencollective.com/eslint" } }, "node_modules/eslint-scope": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.0.0.tgz", "integrity": "sha512-oYrhJW7S0bxAFDvWqzvMPRm6pcgcnWc4QnofCAqRTRfQC0JcwenzGglTtsLyIuuWFfkqDG9vz67cnttSd53djw==", "dev": true, "dependencies": { "esrecurse": "^4.1.0", "estraverse": "^4.1.1" }, "engines": { "node": ">=8.0.0" } }, "node_modules/eslint-utils": { "version": "1.4.3", "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-1.4.3.tgz", "integrity": "sha512-fbBN5W2xdY45KulGXmLHZ3c3FHfVYmKg0IrAKGOkT/464PQsx2UeIzfz1RmEci+KLm1bBaAzZAh8+/E+XAeZ8Q==", "dev": true, "dependencies": { "eslint-visitor-keys": "^1.1.0" }, "engines": { "node": ">=6" } }, "node_modules/eslint-visitor-keys": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.1.0.tgz", "integrity": "sha512-8y9YjtM1JBJU/A9Kc+SbaOV4y29sSWckBwMHa+FGtVj5gN/sbnKDf6xJUl+8g7FAij9LVaP8C24DUiH/f/2Z9A==", "dev": true, "engines": { "node": ">=4" } }, "node_modules/eslint/node_modules/chalk": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "dependencies": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", "supports-color": "^5.3.0" }, "engines": { "node": ">=4" } }, "node_modules/eslint/node_modules/supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "dependencies": { "has-flag": "^3.0.0" }, "engines": { "node": ">=4" } }, "node_modules/espree": { "version": "6.2.1", "resolved": "https://registry.npmjs.org/espree/-/espree-6.2.1.tgz", "integrity": "sha512-ysCxRQY3WaXJz9tdbWOwuWr5Y/XrPTGX9Kiz3yoUXwW0VZ4w30HTkQLaGx/+ttFjF8i+ACbArnB4ce68a9m5hw==", "dev": true, "dependencies": { "acorn": "^7.1.1", "acorn-jsx": "^5.2.0", "eslint-visitor-keys": "^1.1.0" }, "engines": { "node": ">=6.0.0" } }, "node_modules/esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", "dev": true, "bin": { "esparse": "bin/esparse.js", "esvalidate": "bin/esvalidate.js" }, "engines": { "node": ">=4" } }, "node_modules/esquery": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.3.1.tgz", "integrity": "sha512-olpvt9QG0vniUBZspVRN6lwB7hOZoTRtT+jzR+tS4ffYx2mzbw+z0XCOk44aaLYKApNX5nMm+E+P6o25ip/DHQ==", "dev": true, "dependencies": { "estraverse": "^5.1.0" }, "engines": { "node": ">=0.10" } }, "node_modules/esquery/node_modules/estraverse": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.1.0.tgz", "integrity": "sha512-FyohXK+R0vE+y1nHLoBM7ZTyqRpqAlhdZHCWIWEviFLiGB8b04H6bQs8G+XTthacvT8VuwvteiP7RJSxMs8UEw==", "dev": true, "engines": { "node": ">=4.0" } }, "node_modules/esrecurse": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.2.1.tgz", "integrity": "sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ==", "dev": true, "dependencies": { "estraverse": "^4.1.0" }, "engines": { "node": ">=4.0" } }, "node_modules/estraverse": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", "dev": true, "engines": { "node": ">=4.0" } }, "node_modules/esutils": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/external-editor": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==", "dev": true, "dependencies": { "chardet": "^0.7.0", "iconv-lite": "^0.4.24", "tmp": "^0.0.33" }, "engines": { "node": ">=4" } }, "node_modules/fast-deep-equal": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz", "integrity": "sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA==", "dev": true }, "node_modules/fast-json-stable-stringify": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", "dev": true }, "node_modules/fast-levenshtein": { "version": "2.0.6", "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", "dev": true }, "node_modules/figures": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", "dev": true, "dependencies": { "escape-string-regexp": "^1.0.5" }, "engines": { "node": ">=8" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/file-entry-cache": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-5.0.1.tgz", "integrity": "sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g==", "dev": true, "dependencies": { "flat-cache": "^2.0.1" }, "engines": { "node": ">=4" } }, "node_modules/filelist": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/filelist/-/filelist-1.0.1.tgz", "integrity": "sha512-8zSK6Nu0DQIC08mUC46sWGXi+q3GGpKydAG36k+JDba6VRpkevvOWUW5a/PhShij4+vHT9M+ghgG7eM+a9JDUQ==", "dependencies": { "minimatch": "^3.0.4" } }, "node_modules/fill-range": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", "dev": true, "dependencies": { "to-regex-range": "^5.0.1" }, "engines": { "node": ">=8" } }, "node_modules/find-up": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", "dev": true, "dependencies": { "locate-path": "^3.0.0" }, "engines": { "node": ">=6" } }, "node_modules/flat": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", "deprecated": "Fixed a prototype pollution security issue in 4.1.0, please upgrade to ^4.1.1 or ^5.0.1.", "dev": true, "dependencies": { "is-buffer": "~2.0.3" }, "bin": { "flat": "cli.js" } }, "node_modules/flat-cache": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-2.0.1.tgz", "integrity": "sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA==", "dev": true, "dependencies": { "flatted": "^2.0.0", "rimraf": "2.6.3", "write": "1.0.3" }, "engines": { "node": ">=4" } }, "node_modules/flatted": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/flatted/-/flatted-2.0.2.tgz", "integrity": "sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA==", "dev": true }, "node_modules/fs.realpath": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", "dev": true }, "node_modules/fsevents": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", "deprecated": "\"Please update to latest v2.3 or v2.2\"", "dev": true, "hasInstallScript": true, "optional": true, "os": [ "darwin" ], "engines": { "node": "^8.16.0 || ^10.6.0 || >=11.0.0" } }, "node_modules/function-bind": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", "dev": true }, "node_modules/functional-red-black-tree": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz", "integrity": "sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc=", "dev": true }, "node_modules/get-caller-file": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", "dev": true, "engines": { "node": "6.* || 8.* || >= 10.*" } }, "node_modules/glob": { "version": "7.1.6", "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", "dev": true, "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", "inherits": "2", "minimatch": "^3.0.4", "once": "^1.3.0", "path-is-absolute": "^1.0.0" }, "engines": { "node": "*" }, "funding": { "url": "https://github.com/sponsors/isaacs" } }, "node_modules/glob-parent": { "version": "5.1.2", "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", "dev": true, "dependencies": { "is-glob": "^4.0.1" }, "engines": { "node": ">= 6" } }, "node_modules/globals": { "version": "12.4.0", "resolved": "https://registry.npmjs.org/globals/-/globals-12.4.0.tgz", "integrity": "sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg==", "dev": true, "dependencies": { "type-fest": "^0.8.1" }, "engines": { "node": ">=8" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/growl": { "version": "1.10.5", "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", "dev": true, "engines": { "node": ">=4.x" } }, "node_modules/has": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", "dev": true, "dependencies": { "function-bind": "^1.1.1" }, "engines": { "node": ">= 0.4.0" } }, "node_modules/has-flag": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/has-symbols": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", "dev": true, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/he": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", "dev": true, "bin": { "he": "bin/he" } }, "node_modules/iconv-lite": { "version": "0.4.24", "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", "dev": true, "dependencies": { "safer-buffer": ">= 2.1.2 < 3" }, "engines": { "node": ">=0.10.0" } }, "node_modules/ignore": { "version": "4.0.6", "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==", "dev": true, "engines": { "node": ">= 4" } }, "node_modules/import-fresh": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz", "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==", "dev": true, "dependencies": { "parent-module": "^1.0.0", "resolve-from": "^4.0.0" }, "engines": { "node": ">=6" } }, "node_modules/imurmurhash": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", "dev": true, "engines": { "node": ">=0.8.19" } }, "node_modules/inflight": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "dev": true, "dependencies": { "once": "^1.3.0", "wrappy": "1" } }, "node_modules/inherits": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", "dev": true }, "node_modules/inquirer": { "version": "7.1.0", "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-7.1.0.tgz", "integrity": "sha512-5fJMWEmikSYu0nv/flMc475MhGbB7TSPd/2IpFV4I4rMklboCH2rQjYY5kKiYGHqUF9gvaambupcJFFG9dvReg==", "dev": true, "dependencies": { "ansi-escapes": "^4.2.1", "chalk": "^3.0.0", "cli-cursor": "^3.1.0", "cli-width": "^2.0.0", "external-editor": "^3.0.3", "figures": "^3.0.0", "lodash": "^4.17.15", "mute-stream": "0.0.8", "run-async": "^2.4.0", "rxjs": "^6.5.3", "string-width": "^4.1.0", "strip-ansi": "^6.0.0", "through": "^2.3.6" }, "engines": { "node": ">=6.0.0" } }, "node_modules/inquirer/node_modules/ansi-styles": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", "dev": true, "dependencies": { "@types/color-name": "^1.1.1", "color-convert": "^2.0.1" }, "engines": { "node": ">=8" }, "funding": { "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, "node_modules/inquirer/node_modules/chalk": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", "dev": true, "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" }, "engines": { "node": ">=8" } }, "node_modules/inquirer/node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, "dependencies": { "color-name": "~1.1.4" }, "engines": { "node": ">=7.0.0" } }, "node_modules/inquirer/node_modules/color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, "node_modules/inquirer/node_modules/strip-ansi": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", "dev": true, "dependencies": { "ansi-regex": "^5.0.0" }, "engines": { "node": ">=8" } }, "node_modules/is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", "dev": true, "dependencies": { "binary-extensions": "^2.0.0" }, "engines": { "node": ">=8" } }, "node_modules/is-buffer": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==", "dev": true, "engines": { "node": ">=4" } }, "node_modules/is-callable": { "version": "1.1.5", "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.1.5.tgz", "integrity": "sha512-ESKv5sMCJB2jnHTWZ3O5itG+O128Hsus4K4Qh1h2/cgn2vbgnLSVqfV46AeJA9D5EeeLa9w81KUXMtn34zhX+Q==", "dev": true, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/is-date-object": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", "dev": true, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/is-fullwidth-code-point": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", "dev": true, "engines": { "node": ">=8" } }, "node_modules/is-glob": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", "dev": true, "dependencies": { "is-extglob": "^2.1.1" }, "engines": { "node": ">=0.10.0" } }, "node_modules/is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true, "engines": { "node": ">=0.12.0" } }, "node_modules/is-promise": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.1.0.tgz", "integrity": "sha1-eaKp7OfwlugPNtKy87wWwf9L8/o=", "dev": true }, "node_modules/is-regex": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.0.5.tgz", "integrity": "sha512-vlKW17SNq44owv5AQR3Cq0bQPEb8+kF3UKZ2fiZNOWtztYE5i0CzCZxFDwO58qAOWtxdBRVO/V5Qin1wjCqFYQ==", "dev": true, "dependencies": { "has": "^1.0.3" }, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/is-symbol": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", "dev": true, "dependencies": { "has-symbols": "^1.0.1" }, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", "dev": true }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", "dev": true }, "node_modules/js-yaml": { "version": "3.13.1", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", "dev": true, "dependencies": { "argparse": "^1.0.7", "esprima": "^4.0.0" }, "bin": { "js-yaml": "bin/js-yaml.js" } }, "node_modules/json-schema-traverse": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", "dev": true }, "node_modules/json-stable-stringify-without-jsonify": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=", "dev": true }, "node_modules/levn": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", "dev": true, "dependencies": { "prelude-ls": "~1.1.2", "type-check": "~0.3.2" }, "engines": { "node": ">= 0.8.0" } }, "node_modules/locate-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", "dev": true, "dependencies": { "p-locate": "^3.0.0", "path-exists": "^3.0.0" }, "engines": { "node": ">=6" } }, "node_modules/lodash": { "version": "4.17.21", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", "dev": true }, "node_modules/log-symbols": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-3.0.0.tgz", "integrity": "sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==", "dev": true, "dependencies": { "chalk": "^2.4.2" }, "engines": { "node": ">=8" } }, "node_modules/log-symbols/node_modules/chalk": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "dependencies": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", "supports-color": "^5.3.0" }, "engines": { "node": ">=4" } }, "node_modules/log-symbols/node_modules/supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "dependencies": { "has-flag": "^3.0.0" }, "engines": { "node": ">=4" } }, "node_modules/mimic-fn": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", "dev": true, "engines": { "node": ">=6" } }, "node_modules/minimatch": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "dependencies": { "brace-expansion": "^1.1.7" }, "engines": { "node": "*" } }, "node_modules/minimist": { "version": "1.2.6", "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==", "dev": true }, "node_modules/mkdirp": { "version": "0.5.5", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", "dev": true, "dependencies": { "minimist": "^1.2.5" }, "bin": { "mkdirp": "bin/cmd.js" } }, "node_modules/mocha": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/mocha/-/mocha-7.1.1.tgz", "integrity": "sha512-3qQsu3ijNS3GkWcccT5Zw0hf/rWvu1fTN9sPvEd81hlwsr30GX2GcDSSoBxo24IR8FelmrAydGC6/1J5QQP4WA==", "dev": true, "dependencies": { "ansi-colors": "3.2.3", "browser-stdout": "1.3.1", "chokidar": "3.3.0", "debug": "3.2.6", "diff": "3.5.0", "escape-string-regexp": "1.0.5", "find-up": "3.0.0", "glob": "7.1.3", "growl": "1.10.5", "he": "1.2.0", "js-yaml": "3.13.1", "log-symbols": "3.0.0", "minimatch": "3.0.4", "mkdirp": "0.5.3", "ms": "2.1.1", "node-environment-flags": "1.0.6", "object.assign": "4.1.0", "strip-json-comments": "2.0.1", "supports-color": "6.0.0", "which": "1.3.1", "wide-align": "1.1.3", "yargs": "13.3.2", "yargs-parser": "13.1.2", "yargs-unparser": "1.6.0" }, "bin": { "_mocha": "bin/_mocha", "mocha": "bin/mocha" }, "engines": { "node": ">= 8.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/mochajs" } }, "node_modules/mocha/node_modules/debug": { "version": "3.2.6", "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", "deprecated": "Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)", "dev": true, "dependencies": { "ms": "^2.1.1" } }, "node_modules/mocha/node_modules/glob": { "version": "7.1.3", "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz", "integrity": "sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==", "dev": true, "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", "inherits": "2", "minimatch": "^3.0.4", "once": "^1.3.0", "path-is-absolute": "^1.0.0" }, "engines": { "node": "*" } }, "node_modules/mocha/node_modules/mkdirp": { "version": "0.5.3", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.3.tgz", "integrity": "sha512-P+2gwrFqx8lhew375MQHHeTlY8AuOJSrGf0R5ddkEndUkmwpgUob/vQuBD1V22/Cw1/lJr4x+EjllSezBThzBg==", "deprecated": "Legacy versions of mkdirp are no longer supported. Please update to mkdirp 1.x. (Note that the API surface has changed to use Promises in 1.x.)", "dev": true, "dependencies": { "minimist": "^1.2.5" }, "bin": { "mkdirp": "bin/cmd.js" } }, "node_modules/mocha/node_modules/ms": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==", "dev": true }, "node_modules/mocha/node_modules/strip-json-comments": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/mocha/node_modules/supports-color": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.0.0.tgz", "integrity": "sha512-on9Kwidc1IUQo+bQdhi8+Tijpo0e1SS6RoGo2guUwn5vdaxw8RXOF9Vb2ws+ihWOmh4JnCJOvaziZWP1VABaLg==", "dev": true, "dependencies": { "has-flag": "^3.0.0" }, "engines": { "node": ">=6" } }, "node_modules/ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", "dev": true }, "node_modules/mute-stream": { "version": "0.0.8", "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz", "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==", "dev": true }, "node_modules/natural-compare": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=", "dev": true }, "node_modules/nice-try": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", "dev": true }, "node_modules/node-environment-flags": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/node-environment-flags/-/node-environment-flags-1.0.6.tgz", "integrity": "sha512-5Evy2epuL+6TM0lCQGpFIj6KwiEsGh1SrHUhTbNX+sLbBtjidPZFAnVK9y5yU1+h//RitLbRHTIMyxQPtxMdHw==", "dev": true, "dependencies": { "object.getownpropertydescriptors": "^2.0.3", "semver": "^5.7.0" } }, "node_modules/node-environment-flags/node_modules/semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", "dev": true, "bin": { "semver": "bin/semver" } }, "node_modules/normalize-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/object-inspect": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.7.0.tgz", "integrity": "sha512-a7pEHdh1xKIAgTySUGgLMx/xwDZskN1Ud6egYYN3EdRW4ZMPNEDUTF+hwy2LUC+Bl+SyLXANnwz/jyh/qutKUw==", "dev": true, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/object-keys": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", "dev": true, "engines": { "node": ">= 0.4" } }, "node_modules/object.assign": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", "dev": true, "dependencies": { "define-properties": "^1.1.2", "function-bind": "^1.1.1", "has-symbols": "^1.0.0", "object-keys": "^1.0.11" }, "engines": { "node": ">= 0.4" } }, "node_modules/object.getownpropertydescriptors": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.0.tgz", "integrity": "sha512-Z53Oah9A3TdLoblT7VKJaTDdXdT+lQO+cNpKVnya5JDe9uLvzu1YyY1yFDFrcxrlRgWrEFH0jJtD/IbuwjcEVg==", "dev": true, "dependencies": { "define-properties": "^1.1.3", "es-abstract": "^1.17.0-next.1" }, "engines": { "node": ">= 0.8" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "dev": true, "dependencies": { "wrappy": "1" } }, "node_modules/onetime": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.0.tgz", "integrity": "sha512-5NcSkPHhwTVFIQN+TUqXoS5+dlElHXdpAWu9I0HP20YOtIi+aZ0Ct82jdlILDxjLEAWwvm+qj1m6aEtsDVmm6Q==", "dev": true, "dependencies": { "mimic-fn": "^2.1.0" }, "engines": { "node": ">=6" } }, "node_modules/optionator": { "version": "0.8.3", "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", "dev": true, "dependencies": { "deep-is": "~0.1.3", "fast-levenshtein": "~2.0.6", "levn": "~0.3.0", "prelude-ls": "~1.1.2", "type-check": "~0.3.2", "word-wrap": "~1.2.3" }, "engines": { "node": ">= 0.8.0" } }, "node_modules/os-tmpdir": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/p-limit": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, "dependencies": { "p-try": "^2.0.0" }, "engines": { "node": ">=6" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/p-locate": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", "dev": true, "dependencies": { "p-limit": "^2.0.0" }, "engines": { "node": ">=6" } }, "node_modules/p-try": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", "dev": true, "engines": { "node": ">=6" } }, "node_modules/parent-module": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", "dev": true, "dependencies": { "callsites": "^3.0.0" }, "engines": { "node": ">=6" } }, "node_modules/path-exists": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/path-is-absolute": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/path-key": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/picomatch": { "version": "2.2.2", "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", "dev": true, "engines": { "node": ">=8.6" }, "funding": { "url": "https://github.com/sponsors/jonschlinkert" } }, "node_modules/prelude-ls": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=", "dev": true, "engines": { "node": ">= 0.8.0" } }, "node_modules/progress": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", "dev": true, "engines": { "node": ">=0.4.0" } }, "node_modules/punycode": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", "dev": true, "engines": { "node": ">=6" } }, "node_modules/q": { "version": "1.5.1", "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", "integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=", "dev": true, "engines": { "node": ">=0.6.0", "teleport": ">=0.2.0" } }, "node_modules/readdirp": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.2.0.tgz", "integrity": "sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ==", "dev": true, "dependencies": { "picomatch": "^2.0.4" }, "engines": { "node": ">= 8" } }, "node_modules/regexpp": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-2.0.1.tgz", "integrity": "sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw==", "dev": true, "engines": { "node": ">=6.5.0" } }, "node_modules/require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/require-main-filename": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", "dev": true }, "node_modules/resolve-from": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", "dev": true, "engines": { "node": ">=4" } }, "node_modules/restore-cursor": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz", "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==", "dev": true, "dependencies": { "onetime": "^5.1.0", "signal-exit": "^3.0.2" }, "engines": { "node": ">=8" } }, "node_modules/rimraf": { "version": "2.6.3", "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", "dev": true, "dependencies": { "glob": "^7.1.3" }, "bin": { "rimraf": "bin.js" } }, "node_modules/run-async": { "version": "2.4.0", "resolved": "https://registry.npmjs.org/run-async/-/run-async-2.4.0.tgz", "integrity": "sha512-xJTbh/d7Lm7SBhc1tNvTpeCHaEzoyxPrqNlvSdMfBTYwaY++UJFyXUOxAtsRUXjlqOfj8luNaR9vjCh4KeV+pg==", "dev": true, "dependencies": { "is-promise": "^2.1.0" }, "engines": { "node": ">=0.12.0" } }, "node_modules/rxjs": { "version": "6.5.5", "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.5.5.tgz", "integrity": "sha512-WfQI+1gohdf0Dai/Bbmk5L5ItH5tYqm3ki2c5GdWhKjalzjg93N3avFjVStyZZz+A2Em+ZxKH5bNghw9UeylGQ==", "dev": true, "dependencies": { "tslib": "^1.9.0" }, "engines": { "npm": ">=2.0.0" } }, "node_modules/safer-buffer": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", "dev": true }, "node_modules/semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", "dev": true, "bin": { "semver": "bin/semver.js" } }, "node_modules/set-blocking": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true }, "node_modules/shebang-command": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", "dev": true, "dependencies": { "shebang-regex": "^1.0.0" }, "engines": { "node": ">=0.10.0" } }, "node_modules/shebang-regex": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/signal-exit": { "version": "3.0.3", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz", "integrity": "sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA==", "dev": true }, "node_modules/slice-ansi": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.1.0.tgz", "integrity": "sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==", "dev": true, "dependencies": { "ansi-styles": "^3.2.0", "astral-regex": "^1.0.0", "is-fullwidth-code-point": "^2.0.0" }, "engines": { "node": ">=6" } }, "node_modules/slice-ansi/node_modules/is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", "dev": true }, "node_modules/string-width": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.0.tgz", "integrity": "sha512-zUz5JD+tgqtuDjMhwIg5uFVV3dtqZ9yQJlZVfq4I01/K5Paj5UHj7VyrQOJvzawSVlKpObApbfD0Ed6yJc+1eg==", "dev": true, "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", "strip-ansi": "^6.0.0" }, "engines": { "node": ">=8" } }, "node_modules/string-width/node_modules/strip-ansi": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", "dev": true, "dependencies": { "ansi-regex": "^5.0.0" }, "engines": { "node": ">=8" } }, "node_modules/string.prototype.trimend": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", "dev": true, "dependencies": { "define-properties": "^1.1.3", "es-abstract": "^1.17.5" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/string.prototype.trimleft": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/string.prototype.trimleft/-/string.prototype.trimleft-2.1.2.tgz", "integrity": "sha512-gCA0tza1JBvqr3bfAIFJGqfdRTyPae82+KTnm3coDXkZN9wnuW3HjGgN386D7hfv5CHQYCI022/rJPVlqXyHSw==", "dev": true, "dependencies": { "define-properties": "^1.1.3", "es-abstract": "^1.17.5", "string.prototype.trimstart": "^1.0.0" }, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/string.prototype.trimright": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/string.prototype.trimright/-/string.prototype.trimright-2.1.2.tgz", "integrity": "sha512-ZNRQ7sY3KroTaYjRS6EbNiiHrOkjihL9aQE/8gfQ4DtAC/aEBRHFJa44OmoWxGGqXuJlfKkZW4WcXErGr+9ZFg==", "dev": true, "dependencies": { "define-properties": "^1.1.3", "es-abstract": "^1.17.5", "string.prototype.trimend": "^1.0.0" }, "engines": { "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/string.prototype.trimstart": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", "dev": true, "dependencies": { "define-properties": "^1.1.3", "es-abstract": "^1.17.5" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/strip-ansi": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", "dev": true, "dependencies": { "ansi-regex": "^4.1.0" }, "engines": { "node": ">=6" } }, "node_modules/strip-ansi/node_modules/ansi-regex": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==", "dev": true, "engines": { "node": ">=6" } }, "node_modules/strip-json-comments": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.0.tgz", "integrity": "sha512-e6/d0eBu7gHtdCqFt0xJr642LdToM5/cN4Qb9DbHjVx1CP5RyeM+zH7pbecEmDv/lBqb0QH+6Uqq75rxFPkM0w==", "dev": true, "engines": { "node": ">=8" } }, "node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dependencies": { "has-flag": "^4.0.0" }, "engines": { "node": ">=8" } }, "node_modules/supports-color/node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "engines": { "node": ">=8" } }, "node_modules/table": { "version": "5.4.6", "resolved": "https://registry.npmjs.org/table/-/table-5.4.6.tgz", "integrity": "sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug==", "dev": true, "dependencies": { "ajv": "^6.10.2", "lodash": "^4.17.14", "slice-ansi": "^2.1.0", "string-width": "^3.0.0" }, "engines": { "node": ">=6.0.0" } }, "node_modules/table/node_modules/emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, "node_modules/table/node_modules/is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/table/node_modules/string-width": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "dependencies": { "emoji-regex": "^7.0.1", "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^5.1.0" }, "engines": { "node": ">=6" } }, "node_modules/text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", "integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=", "dev": true }, "node_modules/through": { "version": "2.3.8", "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", "dev": true }, "node_modules/tmp": { "version": "0.0.33", "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", "dev": true, "dependencies": { "os-tmpdir": "~1.0.2" }, "engines": { "node": ">=0.6.0" } }, "node_modules/to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", "dev": true, "dependencies": { "is-number": "^7.0.0" }, "engines": { "node": ">=8.0" } }, "node_modules/tslib": { "version": "1.11.1", "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.11.1.tgz", "integrity": "sha512-aZW88SY8kQbU7gpV19lN24LtXh/yD4ZZg6qieAJDDg+YBsJcSmLGK9QpnUjAKVG/xefmvJGd1WUmfpT/g6AJGA==", "dev": true }, "node_modules/type-check": { "version": "0.3.2", "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", "dev": true, "dependencies": { "prelude-ls": "~1.1.2" }, "engines": { "node": ">= 0.8.0" } }, "node_modules/type-fest": { "version": "0.8.1", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", "dev": true, "engines": { "node": ">=8" } }, "node_modules/uri-js": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", "dev": true, "dependencies": { "punycode": "^2.1.0" } }, "node_modules/v8-compile-cache": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.1.0.tgz", "integrity": "sha512-usZBT3PW+LOjM25wbqIlZwPeJV+3OSz3M1k1Ws8snlW39dZyYL9lOGC5FgPVHfk0jKmjiDV8Z0mIbVQPiwFs7g==", "dev": true }, "node_modules/which": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", "dev": true, "dependencies": { "isexe": "^2.0.0" }, "bin": { "which": "bin/which" } }, "node_modules/which-module": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", "dev": true }, "node_modules/wide-align": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", "dev": true, "dependencies": { "string-width": "^1.0.2 || 2" } }, "node_modules/wide-align/node_modules/ansi-regex": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz", "integrity": "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==", "dev": true, "engines": { "node": ">=4" } }, "node_modules/wide-align/node_modules/is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/wide-align/node_modules/string-width": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", "dev": true, "dependencies": { "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^4.0.0" }, "engines": { "node": ">=4" } }, "node_modules/wide-align/node_modules/strip-ansi": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", "dev": true, "dependencies": { "ansi-regex": "^3.0.0" }, "engines": { "node": ">=4" } }, "node_modules/word-wrap": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/wrap-ansi": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", "dev": true, "dependencies": { "ansi-styles": "^3.2.0", "string-width": "^3.0.0", "strip-ansi": "^5.0.0" }, "engines": { "node": ">=6" } }, "node_modules/wrap-ansi/node_modules/emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, "node_modules/wrap-ansi/node_modules/is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/wrap-ansi/node_modules/string-width": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "dependencies": { "emoji-regex": "^7.0.1", "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^5.1.0" }, "engines": { "node": ">=6" } }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true }, "node_modules/write": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/write/-/write-1.0.3.tgz", "integrity": "sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig==", "dev": true, "dependencies": { "mkdirp": "^0.5.1" }, "engines": { "node": ">=4" } }, "node_modules/y18n": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.1.tgz", "integrity": "sha512-wNcy4NvjMYL8gogWWYAO7ZFWFfHcbdbE57tZO8e4cbpj8tfUcwrwqSl3ad8HxpYWCdXcJUCeKKZS62Av1affwQ==", "dev": true }, "node_modules/yargs": { "version": "13.3.2", "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", "dev": true, "dependencies": { "cliui": "^5.0.0", "find-up": "^3.0.0", "get-caller-file": "^2.0.1", "require-directory": "^2.1.1", "require-main-filename": "^2.0.0", "set-blocking": "^2.0.0", "string-width": "^3.0.0", "which-module": "^2.0.0", "y18n": "^4.0.0", "yargs-parser": "^13.1.2" } }, "node_modules/yargs-parser": { "version": "13.1.2", "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", "dev": true, "dependencies": { "camelcase": "^5.0.0", "decamelize": "^1.2.0" } }, "node_modules/yargs-unparser": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.0.tgz", "integrity": "sha512-W9tKgmSn0DpSatfri0nx52Joq5hVXgeLiqR/5G0sZNDoLZFOr/xjBUDcShCOGNsBnEMNo1KAMBkTej1Hm62HTw==", "dev": true, "dependencies": { "flat": "^4.1.0", "lodash": "^4.17.15", "yargs": "^13.3.0" }, "engines": { "node": ">=6" } }, "node_modules/yargs/node_modules/emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, "node_modules/yargs/node_modules/is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true, "engines": { "node": ">=4" } }, "node_modules/yargs/node_modules/string-width": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "dependencies": { "emoji-regex": "^7.0.1", "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^5.1.0" }, "engines": { "node": ">=6" } } }, "dependencies": { "@babel/code-frame": { "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.8.3.tgz", "integrity": "sha512-a9gxpmdXtZEInkCSHUJDLHZVBgb1QS0jhss4cPP93EW7s+uC5bikET2twEF3KV+7rDblJcmNvTR7VJejqd2C2g==", "dev": true, "requires": { "@babel/highlight": "^7.8.3" } }, "@babel/helper-validator-identifier": { "version": "7.9.5", "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.9.5.tgz", "integrity": "sha512-/8arLKUFq882w4tWGj9JYzRpAlZgiWUJ+dtteNTDqrRBz9Iguck9Rn3ykuBDoUwh2TO4tSAJlrxDUOXWklJe4g==", "dev": true }, "@babel/highlight": { "version": "7.9.0", "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.9.0.tgz", "integrity": "sha512-lJZPilxX7Op3Nv/2cvFdnlepPXDxi29wxteT57Q965oc5R9v86ztx0jfxVrTcBk8C2kcPkkDa2Z4T3ZsPPVWsQ==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.9.0", "chalk": "^2.0.0", "js-tokens": "^4.0.0" }, "dependencies": { "chalk": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", "supports-color": "^5.3.0" } }, "supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { "has-flag": "^3.0.0" } } } }, "@types/color-name": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", "dev": true }, "acorn": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.1.1.tgz", "integrity": "sha512-add7dgA5ppRPxCFJoAGfMDi7PIBXq1RtGo7BhbLaxwrXPOmw8gq48Y9ozT01hUKy9byMjlR20EJhu5zlkErEkg==", "dev": true }, "acorn-jsx": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.2.0.tgz", "integrity": "sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ==", "dev": true, "requires": {} }, "ajv": { "version": "6.12.6", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", "dev": true, "requires": { "fast-deep-equal": "^3.1.1", "fast-json-stable-stringify": "^2.0.0", "json-schema-traverse": "^0.4.1", "uri-js": "^4.2.2" } }, "ansi-colors": { "version": "3.2.3", "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-3.2.3.tgz", "integrity": "sha512-LEHHyuhlPY3TmuUYMh2oz89lTShfvgbmzaBcxve9t/9Wuy7Dwf4yoAKcND7KFT1HAQfqZ12qtc+DUrBMeKF9nw==", "dev": true }, "ansi-escapes": { "version": "4.3.1", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.1.tgz", "integrity": "sha512-JWF7ocqNrp8u9oqpgV+wH5ftbt+cfvv+PTjOvKLT3AdYly/LmORARfEVT1iyjwN+4MqE5UmVKoAdIBqeoCHgLA==", "dev": true, "requires": { "type-fest": "^0.11.0" }, "dependencies": { "type-fest": { "version": "0.11.0", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.11.0.tgz", "integrity": "sha512-OdjXJxnCN1AvyLSzeKIgXTXxV+99ZuXl3Hpo9XpJAv9MBcHrrJOQ5kV7ypXOuQie+AmWG25hLbiKdwYTifzcfQ==", "dev": true } } }, "ansi-regex": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", "dev": true }, "ansi-styles": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { "color-convert": "^1.9.0" } }, "anymatch": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", "dev": true, "requires": { "normalize-path": "^3.0.0", "picomatch": "^2.0.4" } }, "argparse": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", "dev": true, "requires": { "sprintf-js": "~1.0.2" } }, "astral-regex": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz", "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==", "dev": true }, "async": { "version": "3.2.3", "resolved": "https://registry.npmjs.org/async/-/async-3.2.3.tgz", "integrity": "sha512-spZRyzKL5l5BZQrr/6m/SqFdBN0q3OCI0f9rjfBzCMBIP4p75P620rR3gTmaksNOhmzgdxcaxdNfMy6anrbM0g==" }, "balanced-match": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" }, "binary-extensions": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.0.0.tgz", "integrity": "sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow==", "dev": true }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "requires": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" } }, "braces": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", "dev": true, "requires": { "fill-range": "^7.0.1" } }, "browser-stdout": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", "dev": true }, "callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", "dev": true }, "camelcase": { "version": "5.3.1", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", "dev": true }, "chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "requires": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" }, "dependencies": { "ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "requires": { "color-convert": "^2.0.1" } }, "color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "requires": { "color-name": "~1.1.4" } }, "color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" } } }, "chardet": { "version": "0.7.0", "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", "dev": true }, "chokidar": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.0.tgz", "integrity": "sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A==", "dev": true, "requires": { "anymatch": "~3.1.1", "braces": "~3.0.2", "fsevents": "~2.1.1", "glob-parent": "~5.1.0", "is-binary-path": "~2.1.0", "is-glob": "~4.0.1", "normalize-path": "~3.0.0", "readdirp": "~3.2.0" } }, "cli-cursor": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", "dev": true, "requires": { "restore-cursor": "^3.1.0" } }, "cli-width": { "version": "2.2.1", "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-2.2.1.tgz", "integrity": "sha512-GRMWDxpOB6Dgk2E5Uo+3eEBvtOOlimMmpbFiKuLFnQzYDavtLFY3K5ona41jgN/WdRZtG7utuVSVTL4HbZHGkw==", "dev": true }, "cliui": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", "dev": true, "requires": { "string-width": "^3.1.0", "strip-ansi": "^5.2.0", "wrap-ansi": "^5.1.0" }, "dependencies": { "emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, "is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true }, "string-width": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "requires": { "emoji-regex": "^7.0.1", "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^5.1.0" } } } }, "color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", "dev": true, "requires": { "color-name": "1.1.3" } }, "color-name": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", "dev": true }, "concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" }, "cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", "dev": true, "requires": { "nice-try": "^1.0.4", "path-key": "^2.0.1", "semver": "^5.5.0", "shebang-command": "^1.2.0", "which": "^1.2.9" }, "dependencies": { "semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", "dev": true } } }, "debug": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", "dev": true, "requires": { "ms": "^2.1.1" } }, "decamelize": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", "dev": true }, "deep-is": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=", "dev": true }, "define-properties": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", "dev": true, "requires": { "object-keys": "^1.0.12" } }, "diff": { "version": "3.5.0", "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz", "integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==", "dev": true }, "doctrine": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", "dev": true, "requires": { "esutils": "^2.0.2" } }, "emoji-regex": { "version": "8.0.0", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, "es-abstract": { "version": "1.17.5", "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.5.tgz", "integrity": "sha512-BR9auzDbySxOcfog0tLECW8l28eRGpDpU3Dm3Hp4q/N+VtLTmyj4EUN088XZWQDW/hzj6sYRDXeOFsaAODKvpg==", "dev": true, "requires": { "es-to-primitive": "^1.2.1", "function-bind": "^1.1.1", "has": "^1.0.3", "has-symbols": "^1.0.1", "is-callable": "^1.1.5", "is-regex": "^1.0.5", "object-inspect": "^1.7.0", "object-keys": "^1.1.1", "object.assign": "^4.1.0", "string.prototype.trimleft": "^2.1.1", "string.prototype.trimright": "^2.1.1" } }, "es-to-primitive": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", "dev": true, "requires": { "is-callable": "^1.1.4", "is-date-object": "^1.0.1", "is-symbol": "^1.0.2" } }, "escape-string-regexp": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", "dev": true }, "eslint": { "version": "6.8.0", "resolved": "https://registry.npmjs.org/eslint/-/eslint-6.8.0.tgz", "integrity": "sha512-K+Iayyo2LtyYhDSYwz5D5QdWw0hCacNzyq1Y821Xna2xSJj7cijoLLYmLxTQgcgZ9mC61nryMy9S7GRbYpI5Ig==", "dev": true, "requires": { "@babel/code-frame": "^7.0.0", "ajv": "^6.10.0", "chalk": "^2.1.0", "cross-spawn": "^6.0.5", "debug": "^4.0.1", "doctrine": "^3.0.0", "eslint-scope": "^5.0.0", "eslint-utils": "^1.4.3", "eslint-visitor-keys": "^1.1.0", "espree": "^6.1.2", "esquery": "^1.0.1", "esutils": "^2.0.2", "file-entry-cache": "^5.0.1", "functional-red-black-tree": "^1.0.1", "glob-parent": "^5.0.0", "globals": "^12.1.0", "ignore": "^4.0.6", "import-fresh": "^3.0.0", "imurmurhash": "^0.1.4", "inquirer": "^7.0.0", "is-glob": "^4.0.0", "js-yaml": "^3.13.1", "json-stable-stringify-without-jsonify": "^1.0.1", "levn": "^0.3.0", "lodash": "^4.17.14", "minimatch": "^3.0.4", "mkdirp": "^0.5.1", "natural-compare": "^1.4.0", "optionator": "^0.8.3", "progress": "^2.0.0", "regexpp": "^2.0.1", "semver": "^6.1.2", "strip-ansi": "^5.2.0", "strip-json-comments": "^3.0.1", "table": "^5.2.3", "text-table": "^0.2.0", "v8-compile-cache": "^2.0.3" }, "dependencies": { "chalk": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", "supports-color": "^5.3.0" } }, "supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { "has-flag": "^3.0.0" } } } }, "eslint-scope": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.0.0.tgz", "integrity": "sha512-oYrhJW7S0bxAFDvWqzvMPRm6pcgcnWc4QnofCAqRTRfQC0JcwenzGglTtsLyIuuWFfkqDG9vz67cnttSd53djw==", "dev": true, "requires": { "esrecurse": "^4.1.0", "estraverse": "^4.1.1" } }, "eslint-utils": { "version": "1.4.3", "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-1.4.3.tgz", "integrity": "sha512-fbBN5W2xdY45KulGXmLHZ3c3FHfVYmKg0IrAKGOkT/464PQsx2UeIzfz1RmEci+KLm1bBaAzZAh8+/E+XAeZ8Q==", "dev": true, "requires": { "eslint-visitor-keys": "^1.1.0" } }, "eslint-visitor-keys": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.1.0.tgz", "integrity": "sha512-8y9YjtM1JBJU/A9Kc+SbaOV4y29sSWckBwMHa+FGtVj5gN/sbnKDf6xJUl+8g7FAij9LVaP8C24DUiH/f/2Z9A==", "dev": true }, "espree": { "version": "6.2.1", "resolved": "https://registry.npmjs.org/espree/-/espree-6.2.1.tgz", "integrity": "sha512-ysCxRQY3WaXJz9tdbWOwuWr5Y/XrPTGX9Kiz3yoUXwW0VZ4w30HTkQLaGx/+ttFjF8i+ACbArnB4ce68a9m5hw==", "dev": true, "requires": { "acorn": "^7.1.1", "acorn-jsx": "^5.2.0", "eslint-visitor-keys": "^1.1.0" } }, "esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", "dev": true }, "esquery": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.3.1.tgz", "integrity": "sha512-olpvt9QG0vniUBZspVRN6lwB7hOZoTRtT+jzR+tS4ffYx2mzbw+z0XCOk44aaLYKApNX5nMm+E+P6o25ip/DHQ==", "dev": true, "requires": { "estraverse": "^5.1.0" }, "dependencies": { "estraverse": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.1.0.tgz", "integrity": "sha512-FyohXK+R0vE+y1nHLoBM7ZTyqRpqAlhdZHCWIWEviFLiGB8b04H6bQs8G+XTthacvT8VuwvteiP7RJSxMs8UEw==", "dev": true } } }, "esrecurse": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.2.1.tgz", "integrity": "sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ==", "dev": true, "requires": { "estraverse": "^4.1.0" } }, "estraverse": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", "dev": true }, "esutils": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", "dev": true }, "external-editor": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==", "dev": true, "requires": { "chardet": "^0.7.0", "iconv-lite": "^0.4.24", "tmp": "^0.0.33" } }, "fast-deep-equal": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz", "integrity": "sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA==", "dev": true }, "fast-json-stable-stringify": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", "dev": true }, "fast-levenshtein": { "version": "2.0.6", "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", "dev": true }, "figures": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", "dev": true, "requires": { "escape-string-regexp": "^1.0.5" } }, "file-entry-cache": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-5.0.1.tgz", "integrity": "sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g==", "dev": true, "requires": { "flat-cache": "^2.0.1" } }, "filelist": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/filelist/-/filelist-1.0.1.tgz", "integrity": "sha512-8zSK6Nu0DQIC08mUC46sWGXi+q3GGpKydAG36k+JDba6VRpkevvOWUW5a/PhShij4+vHT9M+ghgG7eM+a9JDUQ==", "requires": { "minimatch": "^3.0.4" } }, "fill-range": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", "dev": true, "requires": { "to-regex-range": "^5.0.1" } }, "find-up": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", "dev": true, "requires": { "locate-path": "^3.0.0" } }, "flat": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", "dev": true, "requires": { "is-buffer": "~2.0.3" } }, "flat-cache": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-2.0.1.tgz", "integrity": "sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA==", "dev": true, "requires": { "flatted": "^2.0.0", "rimraf": "2.6.3", "write": "1.0.3" } }, "flatted": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/flatted/-/flatted-2.0.2.tgz", "integrity": "sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA==", "dev": true }, "fs.realpath": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", "dev": true }, "fsevents": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", "dev": true, "optional": true }, "function-bind": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", "dev": true }, "functional-red-black-tree": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz", "integrity": "sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc=", "dev": true }, "get-caller-file": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", "dev": true }, "glob": { "version": "7.1.6", "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", "dev": true, "requires": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", "inherits": "2", "minimatch": "^3.0.4", "once": "^1.3.0", "path-is-absolute": "^1.0.0" } }, "glob-parent": { "version": "5.1.2", "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", "dev": true, "requires": { "is-glob": "^4.0.1" } }, "globals": { "version": "12.4.0", "resolved": "https://registry.npmjs.org/globals/-/globals-12.4.0.tgz", "integrity": "sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg==", "dev": true, "requires": { "type-fest": "^0.8.1" } }, "growl": { "version": "1.10.5", "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", "dev": true }, "has": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", "dev": true, "requires": { "function-bind": "^1.1.1" } }, "has-flag": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", "dev": true }, "has-symbols": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", "dev": true }, "he": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", "dev": true }, "iconv-lite": { "version": "0.4.24", "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", "dev": true, "requires": { "safer-buffer": ">= 2.1.2 < 3" } }, "ignore": { "version": "4.0.6", "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==", "dev": true }, "import-fresh": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz", "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==", "dev": true, "requires": { "parent-module": "^1.0.0", "resolve-from": "^4.0.0" } }, "imurmurhash": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", "dev": true }, "inflight": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "dev": true, "requires": { "once": "^1.3.0", "wrappy": "1" } }, "inherits": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", "dev": true }, "inquirer": { "version": "7.1.0", "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-7.1.0.tgz", "integrity": "sha512-5fJMWEmikSYu0nv/flMc475MhGbB7TSPd/2IpFV4I4rMklboCH2rQjYY5kKiYGHqUF9gvaambupcJFFG9dvReg==", "dev": true, "requires": { "ansi-escapes": "^4.2.1", "chalk": "^3.0.0", "cli-cursor": "^3.1.0", "cli-width": "^2.0.0", "external-editor": "^3.0.3", "figures": "^3.0.0", "lodash": "^4.17.15", "mute-stream": "0.0.8", "run-async": "^2.4.0", "rxjs": "^6.5.3", "string-width": "^4.1.0", "strip-ansi": "^6.0.0", "through": "^2.3.6" }, "dependencies": { "ansi-styles": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", "dev": true, "requires": { "@types/color-name": "^1.1.1", "color-convert": "^2.0.1" } }, "chalk": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", "dev": true, "requires": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" } }, "color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, "requires": { "color-name": "~1.1.4" } }, "color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, "strip-ansi": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", "dev": true, "requires": { "ansi-regex": "^5.0.0" } } } }, "is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", "dev": true, "requires": { "binary-extensions": "^2.0.0" } }, "is-buffer": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==", "dev": true }, "is-callable": { "version": "1.1.5", "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.1.5.tgz", "integrity": "sha512-ESKv5sMCJB2jnHTWZ3O5itG+O128Hsus4K4Qh1h2/cgn2vbgnLSVqfV46AeJA9D5EeeLa9w81KUXMtn34zhX+Q==", "dev": true }, "is-date-object": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", "dev": true }, "is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", "dev": true }, "is-fullwidth-code-point": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", "dev": true }, "is-glob": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", "dev": true, "requires": { "is-extglob": "^2.1.1" } }, "is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true }, "is-promise": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.1.0.tgz", "integrity": "sha1-eaKp7OfwlugPNtKy87wWwf9L8/o=", "dev": true }, "is-regex": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.0.5.tgz", "integrity": "sha512-vlKW17SNq44owv5AQR3Cq0bQPEb8+kF3UKZ2fiZNOWtztYE5i0CzCZxFDwO58qAOWtxdBRVO/V5Qin1wjCqFYQ==", "dev": true, "requires": { "has": "^1.0.3" } }, "is-symbol": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", "dev": true, "requires": { "has-symbols": "^1.0.1" } }, "isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", "dev": true }, "js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", "dev": true }, "js-yaml": { "version": "3.13.1", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", "dev": true, "requires": { "argparse": "^1.0.7", "esprima": "^4.0.0" } }, "json-schema-traverse": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", "dev": true }, "json-stable-stringify-without-jsonify": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=", "dev": true }, "levn": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", "dev": true, "requires": { "prelude-ls": "~1.1.2", "type-check": "~0.3.2" } }, "locate-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", "dev": true, "requires": { "p-locate": "^3.0.0", "path-exists": "^3.0.0" } }, "lodash": { "version": "4.17.21", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", "dev": true }, "log-symbols": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-3.0.0.tgz", "integrity": "sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==", "dev": true, "requires": { "chalk": "^2.4.2" }, "dependencies": { "chalk": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", "supports-color": "^5.3.0" } }, "supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { "has-flag": "^3.0.0" } } } }, "mimic-fn": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", "dev": true }, "minimatch": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "requires": { "brace-expansion": "^1.1.7" } }, "minimist": { "version": "1.2.6", "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==", "dev": true }, "mkdirp": { "version": "0.5.5", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", "dev": true, "requires": { "minimist": "^1.2.5" } }, "mocha": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/mocha/-/mocha-7.1.1.tgz", "integrity": "sha512-3qQsu3ijNS3GkWcccT5Zw0hf/rWvu1fTN9sPvEd81hlwsr30GX2GcDSSoBxo24IR8FelmrAydGC6/1J5QQP4WA==", "dev": true, "requires": { "ansi-colors": "3.2.3", "browser-stdout": "1.3.1", "chokidar": "3.3.0", "debug": "3.2.6", "diff": "3.5.0", "escape-string-regexp": "1.0.5", "find-up": "3.0.0", "glob": "7.1.3", "growl": "1.10.5", "he": "1.2.0", "js-yaml": "3.13.1", "log-symbols": "3.0.0", "minimatch": "3.0.4", "mkdirp": "0.5.3", "ms": "2.1.1", "node-environment-flags": "1.0.6", "object.assign": "4.1.0", "strip-json-comments": "2.0.1", "supports-color": "6.0.0", "which": "1.3.1", "wide-align": "1.1.3", "yargs": "13.3.2", "yargs-parser": "13.1.2", "yargs-unparser": "1.6.0" }, "dependencies": { "debug": { "version": "3.2.6", "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", "dev": true, "requires": { "ms": "^2.1.1" } }, "glob": { "version": "7.1.3", "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz", "integrity": "sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==", "dev": true, "requires": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", "inherits": "2", "minimatch": "^3.0.4", "once": "^1.3.0", "path-is-absolute": "^1.0.0" } }, "mkdirp": { "version": "0.5.3", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.3.tgz", "integrity": "sha512-P+2gwrFqx8lhew375MQHHeTlY8AuOJSrGf0R5ddkEndUkmwpgUob/vQuBD1V22/Cw1/lJr4x+EjllSezBThzBg==", "dev": true, "requires": { "minimist": "^1.2.5" } }, "ms": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==", "dev": true }, "strip-json-comments": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", "dev": true }, "supports-color": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.0.0.tgz", "integrity": "sha512-on9Kwidc1IUQo+bQdhi8+Tijpo0e1SS6RoGo2guUwn5vdaxw8RXOF9Vb2ws+ihWOmh4JnCJOvaziZWP1VABaLg==", "dev": true, "requires": { "has-flag": "^3.0.0" } } } }, "ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", "dev": true }, "mute-stream": { "version": "0.0.8", "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz", "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==", "dev": true }, "natural-compare": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=", "dev": true }, "nice-try": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", "dev": true }, "node-environment-flags": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/node-environment-flags/-/node-environment-flags-1.0.6.tgz", "integrity": "sha512-5Evy2epuL+6TM0lCQGpFIj6KwiEsGh1SrHUhTbNX+sLbBtjidPZFAnVK9y5yU1+h//RitLbRHTIMyxQPtxMdHw==", "dev": true, "requires": { "object.getownpropertydescriptors": "^2.0.3", "semver": "^5.7.0" }, "dependencies": { "semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", "dev": true } } }, "normalize-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", "dev": true }, "object-inspect": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.7.0.tgz", "integrity": "sha512-a7pEHdh1xKIAgTySUGgLMx/xwDZskN1Ud6egYYN3EdRW4ZMPNEDUTF+hwy2LUC+Bl+SyLXANnwz/jyh/qutKUw==", "dev": true }, "object-keys": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", "dev": true }, "object.assign": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", "dev": true, "requires": { "define-properties": "^1.1.2", "function-bind": "^1.1.1", "has-symbols": "^1.0.0", "object-keys": "^1.0.11" } }, "object.getownpropertydescriptors": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.0.tgz", "integrity": "sha512-Z53Oah9A3TdLoblT7VKJaTDdXdT+lQO+cNpKVnya5JDe9uLvzu1YyY1yFDFrcxrlRgWrEFH0jJtD/IbuwjcEVg==", "dev": true, "requires": { "define-properties": "^1.1.3", "es-abstract": "^1.17.0-next.1" } }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "dev": true, "requires": { "wrappy": "1" } }, "onetime": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.0.tgz", "integrity": "sha512-5NcSkPHhwTVFIQN+TUqXoS5+dlElHXdpAWu9I0HP20YOtIi+aZ0Ct82jdlILDxjLEAWwvm+qj1m6aEtsDVmm6Q==", "dev": true, "requires": { "mimic-fn": "^2.1.0" } }, "optionator": { "version": "0.8.3", "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", "dev": true, "requires": { "deep-is": "~0.1.3", "fast-levenshtein": "~2.0.6", "levn": "~0.3.0", "prelude-ls": "~1.1.2", "type-check": "~0.3.2", "word-wrap": "~1.2.3" } }, "os-tmpdir": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true }, "p-limit": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "dev": true, "requires": { "p-try": "^2.0.0" } }, "p-locate": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", "dev": true, "requires": { "p-limit": "^2.0.0" } }, "p-try": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", "dev": true }, "parent-module": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", "dev": true, "requires": { "callsites": "^3.0.0" } }, "path-exists": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", "dev": true }, "path-is-absolute": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true }, "path-key": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", "dev": true }, "picomatch": { "version": "2.2.2", "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", "dev": true }, "prelude-ls": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=", "dev": true }, "progress": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", "dev": true }, "punycode": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", "dev": true }, "q": { "version": "1.5.1", "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", "integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=", "dev": true }, "readdirp": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.2.0.tgz", "integrity": "sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ==", "dev": true, "requires": { "picomatch": "^2.0.4" } }, "regexpp": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-2.0.1.tgz", "integrity": "sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw==", "dev": true }, "require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", "dev": true }, "require-main-filename": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", "dev": true }, "resolve-from": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", "dev": true }, "restore-cursor": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz", "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==", "dev": true, "requires": { "onetime": "^5.1.0", "signal-exit": "^3.0.2" } }, "rimraf": { "version": "2.6.3", "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", "dev": true, "requires": { "glob": "^7.1.3" } }, "run-async": { "version": "2.4.0", "resolved": "https://registry.npmjs.org/run-async/-/run-async-2.4.0.tgz", "integrity": "sha512-xJTbh/d7Lm7SBhc1tNvTpeCHaEzoyxPrqNlvSdMfBTYwaY++UJFyXUOxAtsRUXjlqOfj8luNaR9vjCh4KeV+pg==", "dev": true, "requires": { "is-promise": "^2.1.0" } }, "rxjs": { "version": "6.5.5", "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.5.5.tgz", "integrity": "sha512-WfQI+1gohdf0Dai/Bbmk5L5ItH5tYqm3ki2c5GdWhKjalzjg93N3avFjVStyZZz+A2Em+ZxKH5bNghw9UeylGQ==", "dev": true, "requires": { "tslib": "^1.9.0" } }, "safer-buffer": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", "dev": true }, "semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", "dev": true }, "set-blocking": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true }, "shebang-command": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", "dev": true, "requires": { "shebang-regex": "^1.0.0" } }, "shebang-regex": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", "dev": true }, "signal-exit": { "version": "3.0.3", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz", "integrity": "sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA==", "dev": true }, "slice-ansi": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.1.0.tgz", "integrity": "sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==", "dev": true, "requires": { "ansi-styles": "^3.2.0", "astral-regex": "^1.0.0", "is-fullwidth-code-point": "^2.0.0" }, "dependencies": { "is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true } } }, "sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", "dev": true }, "string-width": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.0.tgz", "integrity": "sha512-zUz5JD+tgqtuDjMhwIg5uFVV3dtqZ9yQJlZVfq4I01/K5Paj5UHj7VyrQOJvzawSVlKpObApbfD0Ed6yJc+1eg==", "dev": true, "requires": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", "strip-ansi": "^6.0.0" }, "dependencies": { "strip-ansi": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", "dev": true, "requires": { "ansi-regex": "^5.0.0" } } } }, "string.prototype.trimend": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", "dev": true, "requires": { "define-properties": "^1.1.3", "es-abstract": "^1.17.5" } }, "string.prototype.trimleft": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/string.prototype.trimleft/-/string.prototype.trimleft-2.1.2.tgz", "integrity": "sha512-gCA0tza1JBvqr3bfAIFJGqfdRTyPae82+KTnm3coDXkZN9wnuW3HjGgN386D7hfv5CHQYCI022/rJPVlqXyHSw==", "dev": true, "requires": { "define-properties": "^1.1.3", "es-abstract": "^1.17.5", "string.prototype.trimstart": "^1.0.0" } }, "string.prototype.trimright": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/string.prototype.trimright/-/string.prototype.trimright-2.1.2.tgz", "integrity": "sha512-ZNRQ7sY3KroTaYjRS6EbNiiHrOkjihL9aQE/8gfQ4DtAC/aEBRHFJa44OmoWxGGqXuJlfKkZW4WcXErGr+9ZFg==", "dev": true, "requires": { "define-properties": "^1.1.3", "es-abstract": "^1.17.5", "string.prototype.trimend": "^1.0.0" } }, "string.prototype.trimstart": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", "dev": true, "requires": { "define-properties": "^1.1.3", "es-abstract": "^1.17.5" } }, "strip-ansi": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", "dev": true, "requires": { "ansi-regex": "^4.1.0" }, "dependencies": { "ansi-regex": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==", "dev": true } } }, "strip-json-comments": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.0.tgz", "integrity": "sha512-e6/d0eBu7gHtdCqFt0xJr642LdToM5/cN4Qb9DbHjVx1CP5RyeM+zH7pbecEmDv/lBqb0QH+6Uqq75rxFPkM0w==", "dev": true }, "supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "requires": { "has-flag": "^4.0.0" }, "dependencies": { "has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" } } }, "table": { "version": "5.4.6", "resolved": "https://registry.npmjs.org/table/-/table-5.4.6.tgz", "integrity": "sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug==", "dev": true, "requires": { "ajv": "^6.10.2", "lodash": "^4.17.14", "slice-ansi": "^2.1.0", "string-width": "^3.0.0" }, "dependencies": { "emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, "is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true }, "string-width": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "requires": { "emoji-regex": "^7.0.1", "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^5.1.0" } } } }, "text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", "integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=", "dev": true }, "through": { "version": "2.3.8", "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", "dev": true }, "tmp": { "version": "0.0.33", "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", "dev": true, "requires": { "os-tmpdir": "~1.0.2" } }, "to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", "dev": true, "requires": { "is-number": "^7.0.0" } }, "tslib": { "version": "1.11.1", "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.11.1.tgz", "integrity": "sha512-aZW88SY8kQbU7gpV19lN24LtXh/yD4ZZg6qieAJDDg+YBsJcSmLGK9QpnUjAKVG/xefmvJGd1WUmfpT/g6AJGA==", "dev": true }, "type-check": { "version": "0.3.2", "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", "dev": true, "requires": { "prelude-ls": "~1.1.2" } }, "type-fest": { "version": "0.8.1", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", "dev": true }, "uri-js": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", "dev": true, "requires": { "punycode": "^2.1.0" } }, "v8-compile-cache": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.1.0.tgz", "integrity": "sha512-usZBT3PW+LOjM25wbqIlZwPeJV+3OSz3M1k1Ws8snlW39dZyYL9lOGC5FgPVHfk0jKmjiDV8Z0mIbVQPiwFs7g==", "dev": true }, "which": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", "dev": true, "requires": { "isexe": "^2.0.0" } }, "which-module": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", "dev": true }, "wide-align": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", "dev": true, "requires": { "string-width": "^1.0.2 || 2" }, "dependencies": { "ansi-regex": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz", "integrity": "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==", "dev": true }, "is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true }, "string-width": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", "dev": true, "requires": { "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^4.0.0" } }, "strip-ansi": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", "dev": true, "requires": { "ansi-regex": "^3.0.0" } } } }, "word-wrap": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==", "dev": true }, "wrap-ansi": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", "dev": true, "requires": { "ansi-styles": "^3.2.0", "string-width": "^3.0.0", "strip-ansi": "^5.0.0" }, "dependencies": { "emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, "is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true }, "string-width": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "requires": { "emoji-regex": "^7.0.1", "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^5.1.0" } } } }, "wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true }, "write": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/write/-/write-1.0.3.tgz", "integrity": "sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig==", "dev": true, "requires": { "mkdirp": "^0.5.1" } }, "y18n": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.1.tgz", "integrity": "sha512-wNcy4NvjMYL8gogWWYAO7ZFWFfHcbdbE57tZO8e4cbpj8tfUcwrwqSl3ad8HxpYWCdXcJUCeKKZS62Av1affwQ==", "dev": true }, "yargs": { "version": "13.3.2", "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", "dev": true, "requires": { "cliui": "^5.0.0", "find-up": "^3.0.0", "get-caller-file": "^2.0.1", "require-directory": "^2.1.1", "require-main-filename": "^2.0.0", "set-blocking": "^2.0.0", "string-width": "^3.0.0", "which-module": "^2.0.0", "y18n": "^4.0.0", "yargs-parser": "^13.1.2" }, "dependencies": { "emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, "is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "dev": true }, "string-width": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "requires": { "emoji-regex": "^7.0.1", "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^5.1.0" } } } }, "yargs-parser": { "version": "13.1.2", "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", "dev": true, "requires": { "camelcase": "^5.0.0", "decamelize": "^1.2.0" } }, "yargs-unparser": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.0.tgz", "integrity": "sha512-W9tKgmSn0DpSatfri0nx52Joq5hVXgeLiqR/5G0sZNDoLZFOr/xjBUDcShCOGNsBnEMNo1KAMBkTej1Hm62HTw==", "dev": true, "requires": { "flat": "^4.1.0", "lodash": "^4.17.15", "yargs": "^13.3.0" } } } } jake-10.8.5/package.json000066400000000000000000000016701422765143500150220ustar00rootroot00000000000000{ "name": "jake", "description": "JavaScript build tool, similar to Make or Rake", "keywords": [ "build", "cli", "make", "rake" ], "version": "10.8.5", "author": "Matthew Eernisse (http://fleegix.org)", "license": "Apache-2.0", "bin": { "jake": "./bin/cli.js" }, "main": "./lib/jake.js", "scripts": { "lint": "eslint --format codeframe \"lib/**/*.js\" \"test/**/*.js\"", "lint:fix": "eslint --fix \"lib/**/*.js\" \"test/**/*.js\"", "test": "./bin/cli.js test", "test:ci": "npm run lint && npm run test" }, "repository": { "type": "git", "url": "git://github.com/jakejs/jake.git" }, "preferGlobal": true, "dependencies": { "async": "^3.2.3", "chalk": "^4.0.2", "filelist": "^1.0.1", "minimatch": "^3.0.4" }, "devDependencies": { "eslint": "^6.8.0", "mocha": "^7.1.1", "q": "^1.5.1" }, "engines": { "node": ">=10" } } jake-10.8.5/test/000077500000000000000000000000001422765143500135075ustar00rootroot00000000000000jake-10.8.5/test/.mocharc.js000066400000000000000000000002141422765143500155340ustar00rootroot00000000000000 module.exports = { ui: 'tdd', exclude: [ 'jakefile.js', 'jakefile.publish.js', 'jakefile.rule.js', 'helpers.js' ] } jake-10.8.5/test/integration/000077500000000000000000000000001422765143500160325ustar00rootroot00000000000000jake-10.8.5/test/integration/concurrent.js000066400000000000000000000031321422765143500205510ustar00rootroot00000000000000let assert = require('assert'); let exec = require('child_process').execSync; const PROJECT_DIR = process.env.PROJECT_DIR; const JAKE_CMD = `${PROJECT_DIR}/bin/cli.js`; suite('concurrent', function () { this.timeout(7000); test(' simple concurrent prerequisites 1', function () { let out = exec(`${JAKE_CMD} -q concurrent:simple1`).toString().trim() assert.equal('Started A\nStarted B\nFinished B\nFinished A', out); }); test(' simple concurrent prerequisites 2', function () { let out = exec(`${JAKE_CMD} -q concurrent:simple2`).toString().trim() assert.equal('Started C\nStarted D\nFinished C\nFinished D', out); }); test(' sequential concurrent prerequisites', function () { let out = exec(`${JAKE_CMD} -q concurrent:seqconcurrent`).toString().trim() assert.equal('Started A\nStarted B\nFinished B\nFinished A\nStarted C\nStarted D\nFinished C\nFinished D', out); }); test(' concurrent concurrent prerequisites', function () { let out = exec(`${JAKE_CMD} -q concurrent:concurrentconcurrent`).toString().trim() assert.equal('Started A\nStarted B\nStarted C\nStarted D\nFinished B\nFinished C\nFinished A\nFinished D', out); }); test(' concurrent prerequisites with subdependency', function () { let out = exec(`${JAKE_CMD} -q concurrent:subdep`).toString().trim() assert.equal('Started A\nFinished A\nStarted Ba\nFinished Ba', out); }); test(' failing in concurrent prerequisites', function () { try { exec(`${JAKE_CMD} -q concurrent:Cfail`); } catch(err) { assert(err.message.indexOf('Command failed') > -1); } }); }); jake-10.8.5/test/integration/file.js000066400000000000000000000147061422765143500173170ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ const PROJECT_DIR = process.env.PROJECT_DIR; let assert = require('assert'); let fs = require('fs'); let path = require('path'); let file = require(`${PROJECT_DIR}/lib/utils/file`); let existsSync = fs.existsSync || path.existsSync; let exec = require('child_process').execSync; suite('fileUtils', function () { test('mkdirP', function () { let expected = [ ['foo'], ['foo', 'bar'], ['foo', 'bar', 'baz'], ['foo', 'bar', 'baz', 'qux'] ]; file.mkdirP('foo/bar/baz/qux'); let res = exec('find foo').toString().trim().split('\n'); for (let i = 0, ii = res.length; i < ii; i++) { assert.equal(path.join.apply(path, expected[i]), res[i]); } file.rmRf('foo'); }); test('rmRf', function () { file.mkdirP('foo/bar/baz/qux'); file.rmRf('foo/bar'); let res = exec('find foo').toString().trim().split('\n'); assert.equal(1, res.length); assert.equal('foo', res[0]); fs.rmdirSync('foo'); }); test('rmRf with symlink subdir', function () { file.mkdirP('foo'); file.mkdirP('bar'); fs.writeFileSync('foo/hello.txt', 'hello, it\'s me'); fs.symlinkSync('../foo', 'bar/foo'); file.rmRf('bar'); // Make sure the bar directory was successfully deleted let barDeleted = false; try { fs.statSync('bar'); } catch(err) { if(err.code == 'ENOENT') { barDeleted = true; } } assert.equal(true, barDeleted); // Make sure that the file inside the linked folder wasn't deleted let res = fs.readdirSync('foo'); assert.equal(1, res.length); assert.equal('hello.txt', res[0]); // Cleanup fs.unlinkSync('foo/hello.txt'); fs.rmdirSync('foo'); }); test('rmRf with symlinked dir', function () { file.mkdirP('foo'); fs.writeFileSync('foo/hello.txt', 'hello!'); fs.symlinkSync('foo', 'bar'); file.rmRf('bar'); // Make sure the bar directory was successfully deleted let barDeleted = false; try { fs.statSync('bar'); } catch(err) { if(err.code == 'ENOENT') { barDeleted = true; } } assert.equal(true, barDeleted); // Make sure that the file inside the linked folder wasn't deleted let res = fs.readdirSync('foo'); assert.equal(1, res.length); assert.equal('hello.txt', res[0]); // Cleanup fs.unlinkSync('foo/hello.txt'); fs.rmdirSync('foo'); }); test('cpR with same name and different directory', function () { file.mkdirP('foo'); fs.writeFileSync('foo/bar.txt', 'w00t'); file.cpR('foo', 'bar'); assert.ok(existsSync('bar/bar.txt')); file.rmRf('foo'); file.rmRf('bar'); }); test('cpR with same to and from will throw', function () { assert.throws(function () { file.cpR('foo.txt', 'foo.txt'); }); }); test('cpR rename via copy in directory', function () { file.mkdirP('foo'); fs.writeFileSync('foo/bar.txt', 'w00t'); file.cpR('foo/bar.txt', 'foo/baz.txt'); assert.ok(existsSync('foo/baz.txt')); file.rmRf('foo'); }); test('cpR rename via copy in base', function () { fs.writeFileSync('bar.txt', 'w00t'); file.cpR('bar.txt', 'baz.txt'); assert.ok(existsSync('baz.txt')); file.rmRf('bar.txt'); file.rmRf('baz.txt'); }); test('cpR keeps file mode', function () { fs.writeFileSync('bar.txt', 'w00t', {mode: 0o750}); fs.writeFileSync('bar1.txt', 'w00t!', {mode: 0o744}); file.cpR('bar.txt', 'baz.txt'); file.cpR('bar1.txt', 'baz1.txt'); assert.ok(existsSync('baz.txt')); assert.ok(existsSync('baz1.txt')); let bazStat = fs.statSync('baz.txt'); let bazStat1 = fs.statSync('baz1.txt'); assert.equal(0o750, bazStat.mode & 0o7777); assert.equal(0o744, bazStat1.mode & 0o7777); file.rmRf('bar.txt'); file.rmRf('baz.txt'); file.rmRf('bar1.txt'); file.rmRf('baz1.txt'); }); test('cpR keeps file mode when overwriting with preserveMode', function () { fs.writeFileSync('bar.txt', 'w00t', {mode: 0o755}); fs.writeFileSync('baz.txt', 'w00t!', {mode: 0o744}); file.cpR('bar.txt', 'baz.txt', {silent: true, preserveMode: true}); assert.ok(existsSync('baz.txt')); let bazStat = fs.statSync('baz.txt'); assert.equal(0o755, bazStat.mode & 0o777); file.rmRf('bar.txt'); file.rmRf('baz.txt'); }); test('cpR does not keep file mode when overwriting', function () { fs.writeFileSync('bar.txt', 'w00t', {mode: 0o766}); fs.writeFileSync('baz.txt', 'w00t!', {mode: 0o744}); file.cpR('bar.txt', 'baz.txt'); assert.ok(existsSync('baz.txt')); let bazStat = fs.statSync('baz.txt'); assert.equal(0o744, bazStat.mode & 0o777); file.rmRf('bar.txt'); file.rmRf('baz.txt'); }); test('cpR copies file mode recursively', function () { fs.mkdirSync('foo'); fs.writeFileSync('foo/bar.txt', 'w00t', {mode: 0o740}); file.cpR('foo', 'baz'); assert.ok(existsSync('baz')); let barStat = fs.statSync('baz/bar.txt'); assert.equal(0o740, barStat.mode & 0o777); file.rmRf('foo'); file.rmRf('baz'); }); test('cpR keeps file mode recursively', function () { fs.mkdirSync('foo'); fs.writeFileSync('foo/bar.txt', 'w00t', {mode: 0o740}); fs.mkdirSync('baz'); fs.mkdirSync('baz/foo'); fs.writeFileSync('baz/foo/bar.txt', 'w00t!', {mode: 0o755}); file.cpR('foo', 'baz', {silent: true, preserveMode: true}); assert.ok(existsSync('baz')); let barStat = fs.statSync('baz/foo/bar.txt'); assert.equal(0o740, barStat.mode & 0o777); file.rmRf('foo'); file.rmRf('baz'); }); test('cpR copies directory mode recursively', function () { fs.mkdirSync('foo', 0o755); fs.mkdirSync('foo/bar', 0o700); file.cpR('foo', 'bar'); assert.ok(existsSync('foo')); let fooBarStat = fs.statSync('bar/bar'); assert.equal(0o700, fooBarStat.mode & 0o777); file.rmRf('foo'); file.rmRf('bar'); }); }); jake-10.8.5/test/integration/file_task.js000066400000000000000000000107251422765143500203360ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ const PROJECT_DIR = process.env.PROJECT_DIR; const JAKE_CMD = `${PROJECT_DIR}/bin/cli.js`; let assert = require('assert'); let fs = require('fs'); let exec = require('child_process').execSync; let { rmRf } = require(`${PROJECT_DIR}/lib/jake`); let cleanUpAndNext = function (callback) { rmRf('./foo', { silent: true }); callback && callback(); }; suite('fileTask', function () { this.timeout(7000); setup(function () { cleanUpAndNext(); }); test('where a file-task prereq does not change with --always-make', function () { let out; out = exec(`${JAKE_CMD} -q fileTest:foo/from-src1.txt`).toString().trim(); assert.equal('fileTest:foo/src1.txt task\nfileTest:foo/from-src1.txt task', out); out = exec(`${JAKE_CMD} -q -B fileTest:foo/from-src1.txt`).toString().trim(); assert.equal('fileTest:foo/src1.txt task\nfileTest:foo/from-src1.txt task', out); cleanUpAndNext(); }); test('concating two files', function () { let out; out = exec(`${JAKE_CMD} -q fileTest:foo/concat.txt`).toString().trim(); assert.equal('fileTest:foo/src1.txt task\ndefault task\nfileTest:foo/src2.txt task\n' + 'fileTest:foo/concat.txt task', out); // Check to see the two files got concat'd let data = fs.readFileSync(process.cwd() + '/foo/concat.txt'); assert.equal('src1src2', data.toString()); cleanUpAndNext(); }); test('where a file-task prereq does not change', function () { let out; out = exec(`${JAKE_CMD} -q fileTest:foo/from-src1.txt`).toString().trim(); assert.equal('fileTest:foo/src1.txt task\nfileTest:foo/from-src1.txt task', out); out = exec(`${JAKE_CMD} -q fileTest:foo/from-src1.txt`).toString().trim(); // Second time should be a no-op assert.equal('', out); cleanUpAndNext(); }); test('where a file-task prereq does change, then does not', function (next) { exec('mkdir -p ./foo'); exec('touch ./foo/from-src1.txt'); setTimeout(() => { fs.writeFileSync('./foo/src1.txt', '-SRC'); // Task should run the first time let out; out = exec(`${JAKE_CMD} -q fileTest:foo/from-src1.txt`).toString().trim(); assert.equal('fileTest:foo/from-src1.txt task', out); // Task should not run on subsequent invocation out = exec(`${JAKE_CMD} -q fileTest:foo/from-src1.txt`).toString().trim(); assert.equal('', out); cleanUpAndNext(next); }, 1000); }); test('a preexisting file', function () { let prereqData = 'howdy'; exec('mkdir -p ./foo'); fs.writeFileSync('foo/prereq.txt', prereqData); let out; out = exec(`${JAKE_CMD} -q fileTest:foo/from-prereq.txt`).toString().trim(); assert.equal('fileTest:foo/from-prereq.txt task', out); let data = fs.readFileSync(process.cwd() + '/foo/from-prereq.txt'); assert.equal(prereqData, data.toString()); out = exec(`${JAKE_CMD} -q fileTest:foo/from-prereq.txt`).toString().trim(); // Second time should be a no-op assert.equal('', out); cleanUpAndNext(); }); test('a preexisting file with --always-make flag', function () { let prereqData = 'howdy'; exec('mkdir -p ./foo'); fs.writeFileSync('foo/prereq.txt', prereqData); let out; out = exec(`${JAKE_CMD} -q fileTest:foo/from-prereq.txt`).toString().trim(); assert.equal('fileTest:foo/from-prereq.txt task', out); let data = fs.readFileSync(process.cwd() + '/foo/from-prereq.txt'); assert.equal(prereqData, data.toString()); out = exec(`${JAKE_CMD} -q -B fileTest:foo/from-prereq.txt`).toString().trim(); assert.equal('fileTest:foo/from-prereq.txt task', out); cleanUpAndNext(); }); test('nested directory-task', function () { exec(`${JAKE_CMD} -q fileTest:foo/bar/baz/bamf.txt`); let data = fs.readFileSync(process.cwd() + '/foo/bar/baz/bamf.txt'); assert.equal('w00t', data); cleanUpAndNext(); }); }); jake-10.8.5/test/integration/helpers.js000066400000000000000000000030661422765143500200370ustar00rootroot00000000000000var exec = require('child_process').exec; var helpers = new (function () { var _tests; var _names = []; var _name; var _callback; var _runner = function () { if ((_name = _names.shift())) { console.log('Running ' + _name); _tests[_name](); } else { _callback(); } }; this.exec = function () { var args = Array.prototype.slice.call(arguments); var arg; var cmd = args.shift(); var opts = {}; var callback; // Optional opts/callback or callback/opts while ((arg = args.shift())) { if (typeof arg == 'function') { callback = arg; } else { opts = arg; } } cmd += ' --trace'; var execOpts = opts.execOpts ? opts.execOpts : {}; exec(cmd, execOpts, function (err, stdout, stderr) { var out = helpers.trim(stdout); if (err) { if (opts.breakOnError === false) { return callback(err); } else { throw err; } } if (stderr) { callback(stderr); } else { callback(out); } }); }; this.trim = function (s) { var str = s || ''; return str.replace(/^\s*|\s*$/g, ''); }; this.parse = function (s) { var str = s || ''; str = helpers.trim(str); str = str.replace(/'/g, '"'); return JSON.parse(str); }; this.run = function (tests, callback) { _tests = tests; _names = Object.keys(tests); _callback = callback; _runner(); }; this.next = function () { _runner(); }; })(); module.exports = helpers; jake-10.8.5/test/integration/jakefile.js000066400000000000000000000216361422765143500201520ustar00rootroot00000000000000let fs = require('fs'); let Q = require('q'); desc('The default t.'); task('default', function () { console.log('default task'); }); desc('No action.'); task({'noAction': ['default']}); desc('No action, no prereqs.'); task('noActionNoPrereqs'); desc('Top-level zerbofrangazoomy task'); task('zerbofrangazoomy', function () { console.log('Whaaaaaaaa? Ran the zerbofrangazoomy task!') }); desc('Task that throws'); task('throwy', function () { let errorListener = function (err) { console.log('Emitted'); console.log(err.toString()); jake.removeListener('error', errorListener); }; jake.on('error', errorListener); throw new Error('I am bad'); }); desc('Task that rejects a Promise'); task('promiseRejecter', function () { const originalOption = jake.program.opts['allow-rejection']; const errorListener = function (err) { console.log(err.toString()); jake.removeListener('error', errorListener); jake.program.opts['allow-rejection'] = originalOption; // Restore original 'allow-rejection' option }; jake.on('error', errorListener); jake.program.opts['allow-rejection'] = false; // Do not allow rejection so the rejection is passed to error handlers Promise.reject(''); }); desc('Accepts args and env vars.'); task('argsEnvVars', function () { let res = { args: arguments , env: { foo: process.env.foo , baz: process.env.baz } }; console.log(JSON.stringify(res)); }); namespace('foo', function () { desc('The foo:bar t.'); task('bar', function () { if (arguments.length) { console.log('foo:bar[' + Array.prototype.join.call(arguments, ',') + '] task'); } else { console.log('foo:bar task'); } }); desc('The foo:baz task, calls foo:bar as a prerequisite.'); task('baz', ['foo:bar'], function () { console.log('foo:baz task'); }); desc('The foo:qux task, calls foo:bar with cmdline args as a prerequisite.'); task('qux', ['foo:bar[asdf,qwer]'], function () { console.log('foo:qux task'); }); desc('The foo:frang task,`invokes` foo:bar with passed args as a prerequisite.'); task('frang', function () { let t = jake.Task['foo:bar']; // Do args pass-through t.invoke.apply(t, arguments); t.on('complete', () => { console.log('foo:frang task'); }); }); desc('The foo:zerb task, `executes` foo:bar with passed args as a prerequisite.'); task('zerb', function () { let t = jake.Task['foo:bar']; // Do args pass-through t.execute.apply(t, arguments); t.on('complete', () => { console.log('foo:zerb task'); }); }); desc('The foo:zoobie task, has no prerequisites.'); task('zoobie', function () { console.log('foo:zoobie task'); }); desc('The foo:voom task, run the foo:zoobie task repeatedly.'); task('voom', function () { let t = jake.Task['foo:bar']; t.on('complete', function () { console.log('complete'); }); t.execute.apply(t); t.execute.apply(t); }); desc('The foo:asdf task, has the same prereq twice.'); task('asdf', ['foo:bar', 'foo:baz'], function () { console.log('foo:asdf task'); }); }); namespace('bar', function () { desc('The bar:foo task, has no prerequisites, is async, returns Promise which resolves.'); task('foo', async function () { return new Promise((resolve, reject) => { console.log('bar:foo task'); resolve(); }); }); desc('The bar:promise task has no prerequisites, is async, returns Q-based promise.'); task('promise', function () { return Q() .then(function () { console.log('bar:promise task'); return 123654; }); }); desc('The bar:dependOnpromise task waits for a promise based async test'); task('dependOnpromise', ['promise'], function () { console.log('bar:dependOnpromise task saw value', jake.Task["bar:promise"].value); }); desc('The bar:brokenPromise task is a failing Q-promise based async task.'); task('brokenPromise', function () { return Q() .then(function () { throw new Error("nom nom nom"); }); }); desc('The bar:bar task, has the async bar:foo task as a prerequisite.'); task('bar', ['bar:foo'], function () { console.log('bar:bar task'); }); }); namespace('hoge', function () { desc('The hoge:hoge task, has no prerequisites.'); task('hoge', function () { console.log('hoge:hoge task'); }); desc('The hoge:piyo task, has no prerequisites.'); task('piyo', function () { console.log('hoge:piyo task'); }); desc('The hoge:fuga task, has hoge:hoge and hoge:piyo as prerequisites.'); task('fuga', ['hoge:hoge', 'hoge:piyo'], function () { console.log('hoge:fuga task'); }); desc('The hoge:charan task, has hoge:fuga as a prerequisite.'); task('charan', ['hoge:fuga'], function () { console.log('hoge:charan task'); }); desc('The hoge:gero task, has hoge:fuga as a prerequisite.'); task('gero', ['hoge:fuga'], function () { console.log('hoge:gero task'); }); desc('The hoge:kira task, has hoge:charan and hoge:gero as prerequisites.'); task('kira', ['hoge:charan', 'hoge:gero'], function () { console.log('hoge:kira task'); }); }); namespace('fileTest', function () { directory('foo'); desc('File task, concatenating two files together'); file('foo/concat.txt', ['fileTest:foo', 'fileTest:foo/src1.txt', 'fileTest:foo/src2.txt'], function () { console.log('fileTest:foo/concat.txt task'); let data1 = fs.readFileSync('foo/src1.txt'); let data2 = fs.readFileSync('foo/src2.txt'); fs.writeFileSync('foo/concat.txt', data1 + data2); }); desc('File task, async creation with writeFile'); file('foo/src1.txt', function () { return new Promise(function (resolve, reject) { fs.writeFile('foo/src1.txt', 'src1', function (err) { if (err) { reject(err); } else { console.log('fileTest:foo/src1.txt task'); resolve(); } }); }); }); desc('File task, sync creation with writeFileSync'); file('foo/src2.txt', ['default'], function () { fs.writeFileSync('foo/src2.txt', 'src2'); console.log('fileTest:foo/src2.txt task'); }); desc('File task, do not run unless the prereq file changes'); file('foo/from-src1.txt', ['fileTest:foo', 'fileTest:foo/src1.txt'], function () { let data = fs.readFileSync('foo/src1.txt').toString(); fs.writeFileSync('foo/from-src1.txt', data); console.log('fileTest:foo/from-src1.txt task'); }); desc('File task, run if the prereq file changes'); task('touch-prereq', function () { fs.writeFileSync('foo/prereq.txt', 'UPDATED'); }) desc('File task, has a preexisting file (with no associated task) as a prereq'); file('foo/from-prereq.txt', ['fileTest:foo', 'foo/prereq.txt'], function () { let data = fs.readFileSync('foo/prereq.txt'); fs.writeFileSync('foo/from-prereq.txt', data); console.log('fileTest:foo/from-prereq.txt task'); }); directory('foo/bar/baz'); desc('Write a file in a nested subdirectory'); file('foo/bar/baz/bamf.txt', ['foo/bar/baz'], function () { fs.writeFileSync('foo/bar/baz/bamf.txt', 'w00t'); }); }); task('blammo'); // Define task task('voom', ['blammo'], function () { console.log(this.prereqs.length); }); // Modify, add a prereq task('voom', ['noActionNoPrereqs']); namespace('vronk', function () { task('groo', function () { let t = jake.Task['vronk:zong']; t.addListener('error', function (e) { console.log(e.message); }); t.invoke(); }); task('zong', function () { throw new Error('OMFGZONG'); }); }); // define namespace namespace('one', function () { task('one', function () { console.log('one:one'); }); }); // modify namespace (add task) namespace('one', function () { task('two', ['one:one'], function () { console.log('one:two'); }); }); task('selfdepconst', [], function () { task('selfdep', ['selfdep'], function () { console.log("I made a task that depends on itself"); }); }); task('selfdepdyn', function () { task('selfdeppar', [], {concurrency: 2}, function () { console.log("I will depend on myself and will fail at runtime"); }); task('selfdeppar', ['selfdeppar']); jake.Task['selfdeppar'].invoke(); }); namespace("large", function () { task("leaf", function () { console.log("large:leaf"); }); const same = []; for (let i = 0; i < 2000; i++) { same.push("leaf"); } desc("Task with a large number of same prereqs"); task("same", same, { concurrency: 2 }, function () { console.log("large:same"); }); const different = []; for (let i = 0; i < 2000; i++) { const name = "leaf-" + i; task(name, function () { if (name === "leaf-12" || name === "leaf-123") { console.log(name); } }); different.push(name); } desc("Task with a large number of different prereqs"); task("different", different, { concurrency: 2 } , function () { console.log("large:different") }) }); jake-10.8.5/test/integration/jakelib/000077500000000000000000000000001422765143500174335ustar00rootroot00000000000000jake-10.8.5/test/integration/jakelib/concurrent.jake.js000066400000000000000000000046511422765143500230720ustar00rootroot00000000000000 namespace('concurrent', function () { task('A', function () { console.log('Started A'); return new Promise((resolve, reject) => { setTimeout(() => { console.log('Finished A'); resolve(); }, 200); }); }); task('B', function () { console.log('Started B'); return new Promise((resolve, reject) => { setTimeout(() => { console.log('Finished B'); resolve(); }, 50); }); }); task('C', function () { console.log('Started C'); return new Promise((resolve, reject) => { setTimeout(() => { console.log('Finished C'); resolve(); }, 100); }); }); task('D', function () { console.log('Started D'); return new Promise((resolve, reject) => { setTimeout(() => { console.log('Finished D'); resolve(); }, 300); }); }); task('Ba', ['A'], function () { console.log('Started Ba'); return new Promise((resolve, reject) => { setTimeout(() => { console.log('Finished Ba'); resolve(); }, 50); }); }); task('Afail', function () { console.log('Started failing task'); return new Promise((resolve, reject) => { setTimeout(() => { console.log('Failing B with error'); throw new Error('I failed'); }, 50); }); }); task('simple1', ['A','B'], {concurrency: 2}, function () { return new Promise((resolve, reject) => { setTimeout(() => { resolve(); }, 50); }); }); task('simple2', ['C','D'], {concurrency: 2}, function () { return new Promise((resolve, reject) => { setTimeout(() => { resolve(); }, 50); }); }); task('seqconcurrent', ['simple1','simple2'], function () { return new Promise((resolve, reject) => { setTimeout(() => { resolve(); }, 50); }); }); task('concurrentconcurrent', ['simple1','simple2'], {concurrency: 2}, function () { return new Promise((resolve, reject) => { setTimeout(() => { resolve(); }, 50); }); }); task('subdep', ['A','Ba'], {concurrency: 2}, function () { return new Promise((resolve, reject) => { setTimeout(() => { resolve(); }, 50); }); }); task('fail', ['A', 'B', 'Afail'], {concurrency: 3}, function () { return new Promise((resolve, reject) => { setTimeout(() => { resolve(); }, 50); }); }); }); jake-10.8.5/test/integration/jakelib/publish.jake.js000066400000000000000000000026051422765143500223530ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ const PROJECT_DIR = process.env.PROJECT_DIR; let fs = require('fs'); let { publishTask, rmRf, mkdirP } = require(`${PROJECT_DIR}/lib/jake`); fs.writeFileSync('package.json', '{"version": "0.0.1"}'); mkdirP('tmp_publish'); fs.writeFileSync('tmp_publish/foo.txt', 'FOO'); publishTask('zerb', function () { this.packageFiles.include([ 'package.json' , 'tmp_publish/**' ]); this.publishCmd = 'node -p -e "\'%filename\'"'; this.gitCmd = 'echo' this.scheduleDelay = 0; this._ensureRepoClean = function () {}; this._getCurrentBranch = function () { return 'v0.0' }; }); jake.setTaskTimeout(5000); jake.Task['publish'].on('complete', function () { rmRf('tmp_publish', {silent: true}); rmRf('package.json', {silent: true}); }); jake-10.8.5/test/integration/jakelib/required_module.jake.js000066400000000000000000000002661422765143500240730ustar00rootroot00000000000000let { task, namespace } = require(`${process.env.PROJECT_DIR}/lib/jake`); namespace('usingRequire', function () { task('test', () => { console.log('howdy test'); }); }); jake-10.8.5/test/integration/jakelib/rule.jake.js000066400000000000000000000153411422765143500216550ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ const PROJECT_DIR = process.env.PROJECT_DIR; let exec = require('child_process').execSync; let fs = require('fs'); let util = require('util'); let { rule, rmRf } = require(`${PROJECT_DIR}/lib/jake`); directory('tmpsrc'); directory('tmpbin'); //////////////////////////////////////////////////////////// // Simple Suffix Rule file('tmp', ['tmp_init', 'tmp_dep1.o', 'tmp_dep2.o'], function (params) { console.log('tmp task'); let data1 = fs.readFileSync('tmp_dep1.o'); let data2 = fs.readFileSync('tmp_dep2.o'); fs.writeFileSync('tmp', data1 + data2); }); rule('.o', '.c', function () { let cmd = util.format('cp %s %s', this.source, this.name); console.log(cmd + ' task'); exec(cmd); }); file('tmp_dep1.c', function () { fs.writeFileSync('tmp_dep1.c', 'src_1'); console.log('tmp_dep1.c task'); }); // note that tmp_dep2.o depends on tmp_dep2.c, which is a // static file. task('tmp_init', function () { fs.writeFileSync('tmp_dep2.c', 'src_2'); console.log('tmp_dep2.c task'); }); //////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////// // Pattern Rule file('tmp_p', ['tmp_init', 'tmp_dep1.oo', 'tmp_dep2.oo'], function (params) { console.log('tmp pattern task'); let data1 = fs.readFileSync('tmp_dep1.oo'); let data2 = fs.readFileSync('tmp_dep2.oo'); fs.writeFileSync('tmp_p', data1 + data2 + ' pattern'); }); rule('%.oo', '%.c', function () { let cmd = util.format('cp %s %s', this.source, this.name); console.log(cmd + ' task'); exec(cmd); }); //////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////// // Pattern Rule with Folder // i.e. rule('tmpbin/%.oo', 'tmpsrc/%.c', ... file('tmp_pf', [ 'tmp_src_init' , 'tmpbin' , 'tmpbin/tmp_dep1.oo' , 'tmpbin/tmp_dep2.oo' ], function (params) { console.log('tmp pattern folder task'); let data1 = fs.readFileSync('tmpbin/tmp_dep1.oo'); let data2 = fs.readFileSync('tmpbin/tmp_dep2.oo'); fs.writeFileSync('tmp_pf', data1 + data2 + ' pattern folder'); }); rule('tmpbin/%.oo', 'tmpsrc/%.c', function () { let cmd = util.format('cp %s %s', this.source, this.name); console.log(cmd + ' task'); exec(cmd); }); file('tmpsrc/tmp_dep2.c',['tmpsrc'], function () { fs.writeFileSync('tmpsrc/tmp_dep2.c', 'src/src_2'); console.log('tmpsrc/tmp_dep2.c task'); }); // Create static files in folder tmpsrc. task('tmp_src_init', ['tmpsrc'], function () { fs.writeFileSync('tmpsrc/tmp_dep1.c', 'src/src_1'); console.log('tmpsrc/tmp_dep1.c task'); }); //////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////// // Namespace Test. This is a Mixed Test. // Test for // - rules belonging to different namespace. // - rules with folder and pattern task('tmp_ns', [ 'tmpbin' , 'rule:init' , 'tmpbin/tmp_dep2.oo' // *** This relies on a rule defined before. , 'rule:tmpbin/dep1.oo' , 'rule:tmpbin/file2.oo' ], function () { console.log('tmp pattern folder namespace task'); let data1 = fs.readFileSync('tmpbin/dep1.oo'); let data2 = fs.readFileSync('tmpbin/tmp_dep2.oo'); let data3 = fs.readFileSync('tmpbin/file2.oo'); fs.writeFileSync('tmp_ns', data1 + data2 + data3 + ' pattern folder namespace'); }); namespace('rule', function () { task('init', ['tmpsrc'], function () { fs.writeFileSync('tmpsrc/file2.c', 'src/src_3'); console.log('tmpsrc/file2.c init task'); }); file('tmpsrc/dep1.c',['tmpsrc'], function () { fs.writeFileSync('tmpsrc/dep1.c', 'src/src_1'); console.log('tmpsrc/dep1.c task'); }, {async: true}); rule('tmpbin/%.oo', 'tmpsrc/%.c', function () { let cmd = util.format('cp %s %s', this.source, this.name); console.log(cmd + ' ns task'); exec(cmd); }); }); //////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////// // Chain rule // rule('tmpbin/%.pdf', 'tmpbin/%.dvi', function() { ... // rule('tmpbin/%.dvi', 'tmpsrc/%.tex', ['tmpbin'], function() { ... task('tmp_cr', [ 'chainrule:init' , 'chainrule:tmpbin/file1.pdf' , 'chainrule:tmpbin/file2.pdf' ], function () { console.log('tmp chainrule namespace task'); let data1 = fs.readFileSync('tmpbin/file1.pdf'); let data2 = fs.readFileSync('tmpbin/file2.pdf'); fs.writeFileSync('tmp_cr', data1 + data2 + ' chainrule namespace'); }); namespace('chainrule', function () { task('init', ['tmpsrc', 'tmpbin'], function () { fs.writeFileSync('tmpsrc/file1.tex', 'tex1 '); fs.writeFileSync('tmpsrc/file2.tex', 'tex2 '); console.log('chainrule init task'); }); rule('tmpbin/%.pdf', 'tmpbin/%.dvi', function () { let cmd = util.format('cp %s %s', this.source, this.name); console.log(cmd + ' dvi->pdf task'); exec(cmd); }); rule('tmpbin/%.dvi', 'tmpsrc/%.tex', ['tmpbin'], function () { let cmd = util.format('cp %s %s', this.source, this.name); console.log(cmd + ' tex->dvi task'); exec(cmd); }); }); //////////////////////////////////////////////////////////// namespace('precedence', function () { task('test', ['foo.html'], function () { console.log('ran test'); }); rule('.html', '.txt', function () { console.log('created html'); let data = fs.readFileSync(this.source); fs.writeFileSync(this.name, data.toString()); }); }); namespace('regexPattern', function () { task('test', ['foo.html'], function () { console.log('ran test'); }); rule(/\.html$/, '.txt', function () { console.log('created html'); let data = fs.readFileSync(this.source); fs.writeFileSync(this.name, data.toString()); }); }); namespace('sourceFunction', function () { let srcFunc = function (taskName) { return taskName.replace(/\.[^.]+$/, '.txt'); }; task('test', ['foo.html'], function () { console.log('ran test'); }); rule('.html', srcFunc, function () { console.log('created html'); let data = fs.readFileSync(this.source); fs.writeFileSync(this.name, data.toString()); }); }); //////////////////////////////////////////////////////////// task('clean', function () { rmRf('./foo'); rmRf('./tmp'); }); jake-10.8.5/test/integration/publish_task.js000066400000000000000000000012461422765143500210630ustar00rootroot00000000000000let assert = require('assert'); let exec = require('child_process').execSync; const PROJECT_DIR = process.env.PROJECT_DIR; const JAKE_CMD = `${PROJECT_DIR}/bin/cli.js`; suite('publishTask', function () { this.timeout(7000); test('default task', function () { let out = exec(`${JAKE_CMD} -q publish`).toString().trim(); let expected = [ 'Fetched remote tags.' , 'On branch v0.0' , 'Bumped version number to v0.0.2.' , 'Created package for zerb v0.0.2' , 'Publishing zerb v0.0.2' , './pkg/zerb-v0.0.2.tar.gz' , 'BOOM! Published.' , 'Cleaned up package' ].join('\n'); assert.equal(expected, out); }); }); jake-10.8.5/test/integration/rule.js000066400000000000000000000152401422765143500173410ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ const PROJECT_DIR = process.env.PROJECT_DIR; const JAKE_CMD = `${PROJECT_DIR}/bin/cli.js`; let assert = require('assert'); let exec = require('child_process').execSync; let fs = require('fs'); let { Rule } = require(`${PROJECT_DIR}/lib/rule`); let { rmRf } = require(`${PROJECT_DIR}/lib/jake`); let cleanUpAndNext = function (callback) { // Gotta add globbing to file utils rmRf let tmpFiles = [ 'tmp' , 'tmp_ns' , 'tmp_cr' , 'tmp_p' , 'tmp_pf' , 'tmpbin' , 'tmpsrc' , 'tmp_dep1.c' , 'tmp_dep1.o' , 'tmp_dep1.oo' , 'tmp_dep2.c' , 'tmp_dep2.o' , 'tmp_dep2.oo' , 'foo' , 'foo.html' ]; tmpFiles.forEach(function (f) { rmRf(f, { silent: true }); }); callback && callback(); }; suite('rule', function () { this.timeout(7000); setup(function (next) { cleanUpAndNext(next); }); // - name foo:bin/main.o // - pattern bin/%.o // - source src/%.c // // return { // 'dep' : 'foo:src/main.c', // 'file': 'src/main.c' // }; test('Rule.getSource', function () { let src = Rule.getSource('foo:bin/main.o', 'bin/%.o', 'src/%.c'); assert.equal('foo:src/main.c', src); }); test('rule w/o pattern', function () { let out = exec( `${JAKE_CMD} -q tmp`).toString().trim(); let output = [ "tmp_dep2.c task" , "tmp_dep1.c task" , "cp tmp_dep1.c tmp_dep1.o task" , "cp tmp_dep2.c tmp_dep2.o task" , "tmp task"]; assert.equal( output.join('\n'), out); let data = fs.readFileSync(process.cwd() + '/tmp'); assert.equal('src_1src_2', data.toString()); cleanUpAndNext(); }); test('rule w pattern w/o folder w/o namespace', function () { let out = exec( `${JAKE_CMD} -q tmp_p`).toString().trim(); let output = [ "tmp_dep2.c task" , "tmp_dep1.c task" , "cp tmp_dep1.c tmp_dep1.oo task" , "cp tmp_dep2.c tmp_dep2.oo task" , "tmp pattern task"]; let data; assert.equal( output.join('\n'), out); data = fs.readFileSync(process.cwd() + '/tmp_p'); assert.equal('src_1src_2 pattern', data.toString()); cleanUpAndNext(); }); test('rule w pattern w folder w/o namespace', function () { let out = exec( `${JAKE_CMD} -q tmp_pf`).toString().trim(); let output = [ "tmpsrc/tmp_dep1.c task" , "cp tmpsrc/tmp_dep1.c tmpbin/tmp_dep1.oo task" , "tmpsrc/tmp_dep2.c task" , "cp tmpsrc/tmp_dep2.c tmpbin/tmp_dep2.oo task" , "tmp pattern folder task"]; let data; assert.equal( output.join('\n'), out); data = fs.readFileSync(process.cwd() + '/tmp_pf'); assert.equal('src/src_1src/src_2 pattern folder', data.toString()); cleanUpAndNext(); }); test.skip('rule w pattern w folder w namespace', function () { let out = exec( `${JAKE_CMD} -q tmp_ns`).toString().trim(); let output = [ "tmpsrc/file2.c init task" // yes , "tmpsrc/tmp_dep2.c task" // no , "cp tmpsrc/tmp_dep2.c tmpbin/tmp_dep2.oo task" // no , "tmpsrc/dep1.c task" // no , "cp tmpsrc/dep1.c tmpbin/dep1.oo ns task" // no , "cp tmpsrc/file2.c tmpbin/file2.oo ns task" // yes , "tmp pattern folder namespace task"]; // yes let data; assert.equal( output.join('\n'), out); data = fs.readFileSync(process.cwd() + '/tmp_ns'); assert.equal('src/src_1src/src_2src/src_3 pattern folder namespace', data.toString()); cleanUpAndNext(); }); test.skip('rule w chain w pattern w folder w namespace', function () { let out = exec( `${JAKE_CMD} -q tmp_cr`).toString().trim(); let output = [ "chainrule init task" , "cp tmpsrc/file1.tex tmpbin/file1.dvi tex->dvi task" , "cp tmpbin/file1.dvi tmpbin/file1.pdf dvi->pdf task" , "cp tmpsrc/file2.tex tmpbin/file2.dvi tex->dvi task" , "cp tmpbin/file2.dvi tmpbin/file2.pdf dvi->pdf task" , "tmp chainrule namespace task"]; let data; assert.equal( output.join('\n'), out); data = fs.readFileSync(process.cwd() + '/tmp_cr'); assert.equal('tex1 tex2 chainrule namespace', data.toString()); cleanUpAndNext(); }); ['precedence', 'regexPattern', 'sourceFunction'].forEach(function (key) { test('rule with source file not created yet (' + key + ')', function () { let write = process.stderr.write; process.stderr.write = () => {}; rmRf('foo.txt', {silent: true}); rmRf('foo.html', {silent: true}); try { exec(`${JAKE_CMD} ` + key + ':test'); } catch(err) { // foo.txt prereq doesn't exist yet assert.ok(err.message.indexOf('Unknown task "foo.html"') > -1); } process.stderr.write = write; }); test('rule with source file now created (' + key + ')', function () { fs.writeFileSync('foo.txt', ''); let out = exec(`${JAKE_CMD} -q ` + key + ':test').toString().trim(); // Should run prereq and test task let output = [ 'created html' , 'ran test' ]; assert.equal(output.join('\n'), out); }); test('rule with source file modified (' + key + ')', function (next) { setTimeout(function () { fs.writeFileSync('foo.txt', ''); let out = exec(`${JAKE_CMD} -q ` + key + ':test').toString().trim(); // Should again run both prereq and test task let output = [ 'created html' , 'ran test' ]; assert.equal(output.join('\n'), out); //next(); cleanUpAndNext(next); }, 1000); // Wait to do the touch to ensure mod-time is different }); test('rule with existing objective file and no source ' + ' (should be normal file-task) (' + key + ')', function () { // Remove just the source file fs.writeFileSync('foo.html', ''); rmRf('foo.txt', {silent: true}); let out = exec(`${JAKE_CMD} -q ` + key + ':test').toString().trim(); // Should treat existing objective file as plain file-task, // and just run test-task let output = [ 'ran test' ]; assert.equal(output.join('\n'), out); cleanUpAndNext(); }); }); }); jake-10.8.5/test/integration/selfdep.js000066400000000000000000000014541422765143500200160ustar00rootroot00000000000000let assert = require('assert'); let exec = require('child_process').execSync; const PROJECT_DIR = process.env.PROJECT_DIR; const JAKE_CMD = `${PROJECT_DIR}/bin/cli.js`; suite('selfDep', function () { this.timeout(7000); let origStderrWrite; setup(function () { origStderrWrite = process.stderr.write; process.stderr.write = function () {}; }); teardown(function () { process.stderr.write = origStderrWrite; }); test('self dep const', function () { try { exec(`${JAKE_CMD} selfdepconst`); } catch(e) { assert(e.message.indexOf('dependency of itself') > -1) } }); test('self dep dyn', function () { try { exec(`${JAKE_CMD} selfdepdyn`); } catch(e) { assert(e.message.indexOf('dependency of itself') > -1) } }); }); jake-10.8.5/test/integration/task_base.js000066400000000000000000000130701422765143500203250ustar00rootroot00000000000000let assert = require('assert'); let h = require('./helpers'); let exec = require('child_process').execSync; const PROJECT_DIR = process.env.PROJECT_DIR; const JAKE_CMD = `${PROJECT_DIR}/bin/cli.js`; suite('taskBase', function () { this.timeout(7000); test('default task', function () { let out; out = exec(`${JAKE_CMD} -q`).toString().trim(); assert.equal(out, 'default task'); out = exec(`${JAKE_CMD} -q default`).toString().trim(); assert.equal(out, 'default task'); }); test('task with no action', function () { let out = exec(`${JAKE_CMD} -q noAction`).toString().trim(); assert.equal(out, 'default task'); }); test('a task with no action and no prereqs', function () { exec(`${JAKE_CMD} noActionNoPrereqs`); }); test('a task that exists at the top-level, and not in the specified namespace, should error', function () { let res = require('child_process').spawnSync(`${JAKE_CMD}`, ['asdfasdfasdf:zerbofrangazoomy']); let err = res.stderr.toString(); assert.ok(err.indexOf('Unknown task' > -1)); }); test('passing args to a task', function () { let out = exec(`${JAKE_CMD} -q argsEnvVars[foo,bar]`).toString().trim(); let parsed = h.parse(out); let args = parsed.args; assert.equal(args[0], 'foo'); assert.equal(args[1], 'bar'); }); test('a task with environment vars', function () { let out = exec(`${JAKE_CMD} -q argsEnvVars foo=bar baz=qux`).toString().trim(); let parsed = h.parse(out); let env = parsed.env; assert.equal(env.foo, 'bar'); assert.equal(env.baz, 'qux'); }); test('passing args and using environment vars', function () { let out = exec(`${JAKE_CMD} -q argsEnvVars[foo,bar] foo=bar baz=qux`).toString().trim(); let parsed = h.parse(out); let args = parsed.args; let env = parsed.env; assert.equal(args[0], 'foo'); assert.equal(args[1], 'bar'); assert.equal(env.foo, 'bar'); assert.equal(env.baz, 'qux'); }); test('a simple prereq', function () { let out = exec(`${JAKE_CMD} -q foo:baz`).toString().trim(); assert.equal(out, 'foo:bar task\nfoo:baz task'); }); test('a duplicate prereq only runs once', function () { let out = exec(`${JAKE_CMD} -q foo:asdf`).toString().trim(); assert.equal(out, 'foo:bar task\nfoo:baz task\nfoo:asdf task'); }); test('a prereq with command-line args', function () { let out = exec(`${JAKE_CMD} -q foo:qux`).toString().trim(); assert.equal(out, 'foo:bar[asdf,qwer] task\nfoo:qux task'); }); test('a prereq with args via invoke', function () { let out = exec(`${JAKE_CMD} -q foo:frang[zxcv,uiop]`).toString().trim(); assert.equal(out, 'foo:bar[zxcv,uiop] task\nfoo:frang task'); }); test('a prereq with args via execute', function () { let out = exec(`${JAKE_CMD} -q foo:zerb[zxcv,uiop]`).toString().trim(); assert.equal(out, 'foo:bar[zxcv,uiop] task\nfoo:zerb task'); }); test('repeating the task via execute', function () { let out = exec(`${JAKE_CMD} -q foo:voom`).toString().trim(); assert.equal(out, 'foo:bar task\nfoo:bar task\ncomplete\ncomplete'); }); test('prereq execution-order', function () { let out = exec(`${JAKE_CMD} -q hoge:fuga`).toString().trim(); assert.equal(out, 'hoge:hoge task\nhoge:piyo task\nhoge:fuga task'); }); test('basic async task', function () { let out = exec(`${JAKE_CMD} -q bar:bar`).toString().trim(); assert.equal(out, 'bar:foo task\nbar:bar task'); }); test('promise async task', function () { let out = exec(`${JAKE_CMD} -q bar:dependOnpromise`).toString().trim(); assert.equal(out, 'bar:promise task\nbar:dependOnpromise task saw value 123654'); }); test('failing promise async task', function () { try { exec(`${JAKE_CMD} -q bar:brokenPromise`); } catch(e) { assert(e.message.indexOf('Command failed') > -1); } }); test('that current-prereq index gets reset', function () { let out = exec(`${JAKE_CMD} -q hoge:kira`).toString().trim(); assert.equal(out, 'hoge:hoge task\nhoge:piyo task\nhoge:fuga task\n' + 'hoge:charan task\nhoge:gero task\nhoge:kira task'); }); test('modifying a task by adding prereq during execution', function () { let out = exec(`${JAKE_CMD} -q voom`).toString().trim(); assert.equal(out, 2); }); test('listening for task error-event', function () { try { exec(`${JAKE_CMD} -q vronk:groo`).toString().trim(); } catch(e) { assert(e.message.indexOf('OMFGZONG') > -1); } }); test('listening for jake error-event', function () { let out = exec(`${JAKE_CMD} -q throwy`).toString().trim(); assert(out.indexOf('Emitted\nError: I am bad') > -1); }); test('listening for jake unhandledRejection-event', function () { let out = exec(`${JAKE_CMD} -q promiseRejecter`).toString().trim(); assert.equal(out, ''); }); test('large number of same prereqs', function () { let out = exec(`${JAKE_CMD} -q large:same`).toString().trim(); assert.equal(out, 'large:leaf\nlarge:same'); }); test('large number of different prereqs', function () { let out = exec(`${JAKE_CMD} -q large:different`).toString().trim(); assert.equal(out, 'leaf-12\nleaf-123\nlarge:different'); }); test('large number of different prereqs', function () { let out = exec(`${JAKE_CMD} -q usingRequire:test`).toString().trim(); assert.equal(out, 'howdy test'); }); test('modifying a namespace by adding a new task', function () { let out = exec(`${JAKE_CMD} -q one:two`).toString().trim(); assert.equal('one:one\none:two', out); }); }); jake-10.8.5/test/unit/000077500000000000000000000000001422765143500144665ustar00rootroot00000000000000jake-10.8.5/test/unit/jakefile.js000066400000000000000000000011041422765143500165720ustar00rootroot00000000000000 task('foo', function () { console.log('ran top-level foo'); }); task('bar', function () { console.log('ran top-level bar'); }); task('zerb', function () { console.log('ran zerb'); }); namespace('zooby', function () { task('zerp', function () {}); task('derp', ['zerp'], function () {}); namespace('frang', function () { namespace('w00t', function () { task('bar', function () { console.log('ran zooby:frang:w00t:bar'); }); }); task('asdf', function () {}); }); }); namespace('hurr', function () { namespace('durr'); }); jake-10.8.5/test/unit/namespace.js000066400000000000000000000050261422765143500167630ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ const PROJECT_DIR = process.env.PROJECT_DIR; // Load the jake global require(`${PROJECT_DIR}/lib/jake`); let { Namespace } = require(`${PROJECT_DIR}/lib/namespace`); require('./jakefile'); let assert = require('assert'); suite('namespace', function () { this.timeout(7000); test('resolve namespace by relative name', function () { let aaa, bbb, ccc; aaa = namespace('aaa', function () { bbb = namespace('bbb', function () { ccc = namespace('ccc', function () { }); }); }); assert.ok(aaa, Namespace.ROOT_NAMESPACE.resolveNamespace('aaa')); assert.ok(bbb === aaa.resolveNamespace('bbb')); assert.ok(ccc === aaa.resolveNamespace('bbb:ccc')); }); test('resolve task in sub-namespace by relative path', function () { let curr = Namespace.ROOT_NAMESPACE.resolveNamespace('zooby'); let task = curr.resolveTask('frang:w00t:bar'); assert.ok(task.action.toString().indexOf('zooby:frang:w00t:bar') > -1); }); test('prefer local to top-level', function () { let curr = Namespace.ROOT_NAMESPACE.resolveNamespace('zooby:frang:w00t'); let task = curr.resolveTask('bar'); assert.ok(task.action.toString().indexOf('zooby:frang:w00t:bar') > -1); }); test('does resolve top-level', function () { let curr = Namespace.ROOT_NAMESPACE.resolveNamespace('zooby:frang:w00t'); let task = curr.resolveTask('foo'); assert.ok(task.action.toString().indexOf('top-level foo') > -1); }); test('absolute lookup works from sub-namespaces', function () { let curr = Namespace.ROOT_NAMESPACE.resolveNamespace('hurr:durr'); let task = curr.resolveTask('zooby:frang:w00t:bar'); assert.ok(task.action.toString().indexOf('zooby:frang:w00t:bar') > -1); }); test('resolution miss with throw error', function () { let curr = Namespace.ROOT_NAMESPACE; let task = curr.resolveTask('asdf:qwer'); assert.ok(!task); }); }); jake-10.8.5/test/unit/parseargs.js000066400000000000000000000123101422765143500170100ustar00rootroot00000000000000/* * Jake JavaScript build tool * Copyright 2112 Matthew Eernisse (mde@fleegix.org) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ const PROJECT_DIR = process.env.PROJECT_DIR; let parseargs = require(`${PROJECT_DIR}/lib/parseargs`); let assert = require('assert'); let optsReg = [ { full: 'directory', abbr: 'C', preempts: false, expectValue: true }, { full: 'jakefile', abbr: 'f', preempts: false, expectValue: true }, { full: 'tasks', abbr: 'T', preempts: true }, { full: 'tasks', abbr: 'ls', preempts: true }, { full: 'trace', abbr: 't', preempts: false, expectValue: false }, { full: 'help', abbr: 'h', preempts: true }, { full: 'version', abbr: 'V', preempts: true } ]; let p = new parseargs.Parser(optsReg); let z = function (s) { return s.split(' '); }; let res; suite('parseargs', function () { test('long preemptive opt and val with equal-sign, ignore further opts', function () { res = p.parse(z('--tasks=foo --jakefile=asdf')); assert.equal('foo', res.opts.tasks); assert.equal(undefined, res.opts.jakefile); }); test('long preemptive opt and val without equal-sign, ignore further opts', function () { res = p.parse(z('--tasks foo --jakefile=asdf')); assert.equal('foo', res.opts.tasks); assert.equal(undefined, res.opts.jakefile); }); test('long preemptive opt and no val, ignore further opts', function () { res = p.parse(z('--tasks --jakefile=asdf')); assert.equal(true, res.opts.tasks); assert.equal(undefined, res.opts.jakefile); }); test('preemptive opt with no val, should be true', function () { res = p.parse(z('-T')); assert.equal(true, res.opts.tasks); }); test('preemptive opt with no val, should be true and ignore further opts', function () { res = p.parse(z('-T -f')); assert.equal(true, res.opts.tasks); assert.equal(undefined, res.opts.jakefile); }); test('preemptive opt with val, should be val', function () { res = p.parse(z('-T zoobie -f foo/bar/baz')); assert.equal('zoobie', res.opts.tasks); assert.equal(undefined, res.opts.jakefile); }); test('-f expects a value, -t does not (howdy is task-name)', function () { res = p.parse(z('-f zoobie -t howdy')); assert.equal('zoobie', res.opts.jakefile); assert.equal(true, res.opts.trace); assert.equal('howdy', res.taskNames[0]); }); test('different order, -f expects a value, -t does not (howdy is task-name)', function () { res = p.parse(z('-f zoobie howdy -t')); assert.equal('zoobie', res.opts.jakefile); assert.equal(true, res.opts.trace); assert.equal('howdy', res.taskNames[0]); }); test('-f expects a value, -t does not (foo=bar is env var)', function () { res = p.parse(z('-f zoobie -t foo=bar')); assert.equal('zoobie', res.opts.jakefile); assert.equal(true, res.opts.trace); assert.equal('bar', res.envVars.foo); assert.equal(undefined, res.taskNames[0]); }); test('-f expects a value, -t does not (foo=bar is env-var, task-name follows)', function () { res = p.parse(z('-f zoobie -t howdy foo=bar')); assert.equal('zoobie', res.opts.jakefile); assert.equal(true, res.opts.trace); assert.equal('bar', res.envVars.foo); assert.equal('howdy', res.taskNames[0]); }); test('-t does not expect a value, -f does (howdy is task-name)', function () { res = p.parse(z('-t howdy -f zoobie')); assert.equal(true, res.opts.trace); assert.equal('zoobie', res.opts.jakefile); assert.equal('howdy', res.taskNames[0]); }); test('--trace does not expect a value, -f does (howdy is task-name)', function () { res = p.parse(z('--trace howdy --jakefile zoobie')); assert.equal(true, res.opts.trace); assert.equal('zoobie', res.opts.jakefile); assert.equal('howdy', res.taskNames[0]); }); test('--trace does not expect a value (equal), -f does (throw howdy away)', function () { res = p.parse(z('--trace=howdy --jakefile=zoobie')); assert.equal(true, res.opts.trace); assert.equal('zoobie', res.opts.jakefile); assert.equal(undefined, res.taskNames[0]); }); /* , test('task-name with positional args', function () { res = p.parse(z('foo:bar[asdf,qwer]')); assert.equal('asdf', p.taskArgs[0]); assert.equal('qwer', p.taskArgs[1]); } , test('opts, env vars, task-name with positional args', function () { res = p.parse(z('-f ./tests/Jakefile -t default[asdf,qwer] foo=bar')); assert.equal('./tests/Jakefile', res.opts.jakefile); assert.equal(true, res.opts.trace); assert.equal('bar', res.envVars.foo); assert.equal('default', res.taskName); assert.equal('asdf', p.taskArgs[0]); assert.equal('qwer', p.taskArgs[1]); } */ }); jake-10.8.5/usage.txt000066400000000000000000000017411422765143500144000ustar00rootroot00000000000000Jake JavaScript build tool ******************************************************************************** If no flags are given, Jake looks for a Jakefile or Jakefile.js in the current directory. ******************************************************************************** {Usage}: jake [options ...] [env variables ...] target {Options}: -f, --jakefile FILE Use FILE as the Jakefile. -C, --directory DIRECTORY Change to DIRECTORY before running tasks. -B, --always-make Unconditionally make all targets. -T/-ls, --tasks Display the tasks (matching optional PATTERN) with descriptions, then exit. -J, --jakelibdir JAKELIBDIR Auto-import any .jake files in JAKELIBDIR. (default is \'jakelib\') -h, --help Display this help message. -V/-v, --version Display the Jake version. -ar, --allow-rejection Keep running even after unhandled promise rejection