diff --git a/.appveyor.yml b/.appveyor.yml index 1bfe3b9..20a9f3c 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -3,7 +3,7 @@ skip_tags: true skip_branch_with_pr: true environment: - nodejs_version: "8" + nodejs_version: "9" CODE_TESTS_WORKSPACE: "$(APPVEYOR_BUILD_FOLDER)/test/_workspace" CODE_TESTS_PATH: "$(APPVEYOR_BUILD_FOLDER)/out/test/single-workspace-tests" diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..968ff41 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,13 @@ +root = true + +[*] +indent_style = space +indent_size = 2 +end_of_line = lf +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true +max_line_length = 125 + +[*.md] +trim_trailing_whitespace = false diff --git a/.travis.yml b/.travis.yml index 6c61338..83c96c1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,5 +1,5 @@ language: node_js -node_js: '8' +node_js: '9' stages: - name: test @@ -44,30 +44,22 @@ jobs: before_script: - greenkeeper-lockfile-update script: - - exit 0 - yarn test --silent after_script: - - exit 0 - greenkeeper-lockfile-upload - stage: deploy - env: - - BUILD_LEADER_ID=2 install: - rvm get stable - rvm install 2.4 - gem install github_changelog_generator - - yarn global add vsce semantic-release@^8.2.0 semantic-release-visualstudio-marketplace-version + - yarn global add vsce semantic-release@^12.2.0 semantic-release-vsce@^1.0.0 - yarn install - script: + before_script: - yarn build - - semantic-release pre - - github_changelog_generator --no-verbose -u buehler -p typescript-hero --enhancement-labels "enhancement,feature" --include-labels "bug,enhancement,feature" --future-release $(node -p "require('./package.json').version") - after_script: - yarn install --production - after_success: - - vsce package - - vsce publish -p $VSCE_TOKEN - - semantic-release post + script: + - semantic-release + #- github_changelog_generator --no-verbose -u buehler -p typescript-hero --enhancement-labels "enhancement,feature" --include-labels "bug,enhancement,feature" --future-release $(node -p "require('./package.json').version") # add as soon as multi root workspaces are available: #- CODE_TESTS_WORKSPACE=$TRAVIS_BUILD_DIR/test/multi-root.code-workspace CODE_TESTS_PATH=$TRAVIS_BUILD_DIR/out/test/multi-root-workspace-tests diff --git a/.vscode/launch.json b/.vscode/launch.json index 35e2961..53db298 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -1,80 +1,80 @@ { - "version": "0.2.0", - "configurations": [ - { - "name": "Launch Extension", - "type": "extensionHost", - "request": "launch", - "runtimeExecutable": "${execPath}", - "args": [ - "${workspaceRoot}/test/_workspace", - "--extensionDevelopmentPath=${workspaceRoot}" - ], - "env": { - "EXT_DEBUG": "true" - }, - "stopOnEntry": false, - "sourceMaps": true, - "outFiles": [ - "${workspaceRoot}/out/src/**/*.js" - ] - }, - { - "name": "Launch Extension Multi-Root", - "type": "extensionHost", - "request": "launch", - "runtimeExecutable": "${execPath}", - "args": [ - "${workspaceRoot}/test/multi-root.code-workspace", - "--extensionDevelopmentPath=${workspaceRoot}" - ], - "env": { - "EXT_DEBUG": "true" - }, - "stopOnEntry": false, - "sourceMaps": true, - "outFiles": [ - "${workspaceRoot}/out/src/**/*.js" - ] - }, - { - "name": "Launch Tests (single Workspace)", - "type": "extensionHost", - "request": "launch", - "runtimeExecutable": "${execPath}", - "args": [ - "${workspaceRoot}/test/_workspace", - "--extensionDevelopmentPath=${workspaceRoot}", - "--extensionTestsPath=${workspaceRoot}/out/test/single-workspace-tests/" - ], - "env": { - "CI": "true" - }, - "stopOnEntry": false, - "sourceMaps": true, - "outFiles": [ - "${workspaceRoot}/out/test/single-workspace-tests/**/*.js" - ] - }, - { - "name": "Launch Tests (multi-root Workspace)", - "type": "extensionHost", - "request": "launch", - "runtimeExecutable": "${execPath}", - "args": [ - "${workspaceRoot}/test/multi-root.code-workspace", - "--extensionDevelopmentPath=${workspaceRoot}", - "--extensionTestsPath=${workspaceRoot}/out/test/multi-root-workspace-tests/" - ], - "env": { - "CI": "true" - }, - "stopOnEntry": false, - "sourceMaps": true, - "outFiles": [ - "${workspaceRoot}/out/test/**/*.js" - ] - } - ], - "compounds": [] + "version": "0.2.0", + "configurations": [ + { + "name": "Launch Extension", + "type": "extensionHost", + "request": "launch", + "runtimeExecutable": "${execPath}", + "args": [ + "${workspaceRoot}/test/_workspace", + "--extensionDevelopmentPath=${workspaceRoot}" + ], + "env": { + "EXT_DEBUG": "true" + }, + "stopOnEntry": false, + "sourceMaps": true, + "outFiles": [ + "${workspaceRoot}/out/src/**/*.js" + ] + }, + { + "name": "Launch Extension Multi-Root", + "type": "extensionHost", + "request": "launch", + "runtimeExecutable": "${execPath}", + "args": [ + "${workspaceRoot}/test/multi-root.code-workspace", + "--extensionDevelopmentPath=${workspaceRoot}" + ], + "env": { + "EXT_DEBUG": "true" + }, + "stopOnEntry": false, + "sourceMaps": true, + "outFiles": [ + "${workspaceRoot}/out/src/**/*.js" + ] + }, + { + "name": "Launch Tests (single Workspace)", + "type": "extensionHost", + "request": "launch", + "runtimeExecutable": "${execPath}", + "args": [ + "${workspaceRoot}/test/_workspace", + "--extensionDevelopmentPath=${workspaceRoot}", + "--extensionTestsPath=${workspaceRoot}/out/test/single-workspace-tests/" + ], + "env": { + "CI": "true" + }, + "stopOnEntry": false, + "sourceMaps": true, + "outFiles": [ + "${workspaceRoot}/out/test/single-workspace-tests/**/*.js" + ] + }, + { + "name": "Launch Tests (multi-root Workspace)", + "type": "extensionHost", + "request": "launch", + "runtimeExecutable": "${execPath}", + "args": [ + "${workspaceRoot}/test/multi-root.code-workspace", + "--extensionDevelopmentPath=${workspaceRoot}", + "--extensionTestsPath=${workspaceRoot}/out/test/multi-root-workspace-tests/" + ], + "env": { + "CI": "true" + }, + "stopOnEntry": false, + "sourceMaps": true, + "outFiles": [ + "${workspaceRoot}/out/test/**/*.js" + ] + } + ], + "compounds": [] } diff --git a/README.md b/README.md index 87ef3e9..b1c650f 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,7 @@ # TypeScript Hero TypeScript Hero is a vscode extension that makes your life easier. -When you are coding a lot of `TypeScript` you may want vscode to automatically -include your imports. - -If you search for this feature: here's the solution (and many more). Typescript hero will be extended -in the future and there are many features in the pipeline that will enhance the way you -work with typescript. +When you are coding a lot of `TypeScript` you may want vscode to organize your imports. [![Travis build](https://img.shields.io/travis/buehler/typescript-hero.svg)](https://travis-ci.org/buehler/typescript-hero) [![AppVeyor status](https://ci.appveyor.com/api/projects/status/p1vbbyh69j4s0rbh?svg=true)](https://ci.appveyor.com/project/buehler/typescript-hero) @@ -26,29 +21,16 @@ If you'd like to buy me a beer :-) Here is a brief list, of what TypeScript Hero is capable of (more at the end): -- Add imports of your project or libraries to your current file -- Add an import for the current name under the cursor -- Add all missing imports of a file with one command -- Intellisense that suggests symbols and automatically adds the needed imports -- "Light bulb feature" that fixes code you wrote - Sort and organize your imports (sort and remove unused) - Code outline view of your open TS / TSX document -- All the cool stuff for JavaScript as well! (experimental stage though, better description below.) - - Add imports from javascript files - - Code outline for JS / JSX files - - Intellisense for JS / JSX files ## Commands All commands are preceeded by `typescriptHero`. -| Command | Extension part | Description | -| ---------------------------- | --------------- | --------------------------------------------------------- | -| resolve.addImport | import resolver | Shows a pick list with all recognized, importable symbols | -| resolve.addImportUnderCursor | import resolver | Imports the symbol under the cursor | -| resolve.addMissingImports | import resolver | Imports all missing symbols for the actual document | -| resolve.organizeImports | import resolver | Removes unused imports and orders all imports | -| resolve.rebuildCache | import resolver | Rebuilds the whole symbol cache (or index) | +| Command | Extension part | Description | +| ---------------------------- | ---------------- | --------------------------------------------------------- | +| imports.organize | import organizer | Removes unused imports and orders all imports | ## Keybindings @@ -56,10 +38,7 @@ The following commands are bound by default when the extension is installed. | Command | Keybinding | | ---------------------------- | ------------------ | -| resolve.addImport | `ctrl+shift+i` | -| resolve.addImportUnderCursor | `ctrl+alt+i` | -| resolve.addMissingImports | `ctrl+alt+shift+i` | -| resolve.organizeImports | `ctrl+alt+o` | +| imports.organize | `ctrl+alt+o` | ## Settings @@ -76,37 +55,25 @@ These settings do not have a prefix. | ---------- | --------------------------------------------------------------------------------------- | | verbosity | The log level that the extension writes its messages to the output channel and the file | -### Code completion - -The following settings do have the prefix `codeCompletion`. So an example setting could be -`typescriptHero.codeCompletion.completionSortOrder`. - -| Setting | Description | -| ------------------- | ----------------------------------------------------------------------------- | -| completionSortOrder | The order of import completions in suggestion list, `bottom` pushes them down | +### Import Organizer -### Import resolver - -The following settings do have the prefix `resolver`. So an example setting could be -`typescriptHero.resolver.stringQuoteStyle`. +The following settings do have the prefix `imports`. So an example setting could be +`typescriptHero.imports.stringQuoteStyle`. | Setting | Description | | ------------------------------------- | --------------------------------------------------------------------------------------------- | -| stringQuoteStyle | The string delimiter to use for the imports (`'` or `"`) | -| workspaceIgnorePatterns | If any of these strings is part of a file path, the file is ignored during workspace indexing | -| moduleIgnorePatterns | If any of these strings is part of a file path, the file is ignored during module indexing | +| disableImportSorting | Disable sorting during organize imports action | +| disableImportRemovalOnOrganize | Disable removal unsed imports during organize imports action | | insertSpaceBeforeAndAfterImportBraces | If the extension should place spaces into import braces (`{Symbol}` vs `{ Symbol }`) | | insertSemicolons | If the extension should add a semicolon to the end of a statement | +| importGroups | The groups that are used for sorting the imports (description below) | +| ignoredFromRemoval | Imports that are never removed during organize import (e.g. react) | | multiLineWrapThreshold | The threshold, when imports are converted into multiline imports | | multiLineTrailingComma | When multiline imports are created, `true` inserts a trailing comma to the last line | -| disableImportSorting | Disable sorting during organize imports action | -| disableImportRemovalOnOrganize | Disable removal unsed imports during organize imports action | -| importGroups | The groups that are used for sorting the imports (description below) | -| ignoreImportsForOrganize | Imports that are never removed during organize import (e.g. react) | -| resolverMode | Which files should be considered to index for TypeScript Hero | | organizeOnSave | Enable or disable the `organizeImports` action on a save of a document | | organizeSortsByFirstSpecifier | When organizing runs, sort by first specifier/alias (if any) instead of module path | -| promptForSpecifiers | If the extension should ask the user for aliases and duplicate specifiers | +| removeTrailingIndex | Remove trailing `/index` from imports, since that is javascript default to look there | +| stringQuoteStyle | The string delimiter to use for the imports (`'` or `"`) | ### Code outline view @@ -123,13 +90,9 @@ The following settings do have the prefix `codeOutline`. So an example setting c TypeScript Hero can manage your imports. It is capable of: -- Import something you select from a list of all possible indexed symbols -- Import something that is beneath your current cursor position (and ask you if it's not sure which one) -- Import all missing identifiers of the current file - Remove unused imports and sort the remaining ones by alphabet - Do organize the imports when a document is saved - - Note that this feature is only enabled if the vscode setting `editor.formatOnSave` is enabled as well! - - Organizing used module paths by default, sorted lexicographically. An option lets you use first + - Organizing used module paths by default, sorted lexicographically. An option lets you use first import specifier/alias instead, in natural-language order. #### Import groups @@ -217,21 +180,6 @@ import 'reflect-metadata'; import {Server} from './server'; ``` -### Intellisense - -Intellisense is a common IDE feature. TypeScript Hero provides you with symbols as you type your code -and does add the import to the top of the file, if you don't have already imported the symbol. - -### Code fixing - -The "light-bulb" feature of VSCode can provide some code-fix actions to take when you make mistakes. -TypeScript Hero offers the following fix actions: - -- Detect a missing import and automatically add the import to the file -- Detect a missing import and offer to add all missing imports to the file -- Detect missing methods / properties of an interface that you implemented and implement them for you (implement interface refactoring) -- Detect missing abstract methods of an extended abstract class and implement them for you (implement abstract class refactoring) - ### Code outline view This view is below your file explorer. It displays a code outline of your actually opened typescript or typescript-react @@ -241,16 +189,6 @@ see what's in them. If you click on an element, the editor will jump to the loca By now, only typescript / typescript-react is supported. Maybe this will wander in it's own extension to support more languages than those two. -### ES6 / JavaScript support - -As of now, this is kind of an experimental stage. TypeScript Hero can be set into an `ES6` or `Both` mode, instead -of only `TypeScript`. With one of either modes, it will scan for javascript files in the workspace. - -Right now, only files in the workspace are considered "worth", because of the immense amount of javascript files -in the `node_modules`. So if you set TSH to `ES6` it will scan all typescript declarations in the `node_modules`, and -your javascript files in the workspace. If you set it to `Both`, it will scan all typescript files and the javascript -files in the workspace (as well as the declarations). - ## Known Issues Please visit [the issue list](https://github.com/buehler/typescript-hero/issues) :-) diff --git a/config/tsconfig.base.json b/config/tsconfig.base.json index 3287faf..7814af4 100644 --- a/config/tsconfig.base.json +++ b/config/tsconfig.base.json @@ -1,27 +1,29 @@ { - "compilerOptions": { - "module": "commonjs", - "target": "es6", - "outDir": "../out", - "lib": [ - "es6", - "es2017" - ], - "rootDir": "..", - "emitDecoratorMetadata": true, - "experimentalDecorators": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "strictNullChecks": true, - "importHelpers": true, - "removeComments": true - }, - "include": [ - "../src/**/*", - "../test/**/*" + "compilerOptions": { + "module": "commonjs", + "target": "es6", + "outDir": "../out", + "moduleResolution": "node", + "lib": [ + "es6", + "es2017", + "dom" ], - "exclude": [ - "../test/_workspace", - "../test/_workspace_2" - ] + "rootDir": "../src", + "emitDecoratorMetadata": true, + "experimentalDecorators": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "strictNullChecks": true, + "importHelpers": true, + "removeComments": true + }, + "include": [ + "../src/**/*" + ], + "exclude": [ + "../src/_old", + "../node_modules", + "../out" + ] } diff --git a/config/tsconfig.build.json b/config/tsconfig.build.json index 0a4d973..c23d4db 100644 --- a/config/tsconfig.build.json +++ b/config/tsconfig.build.json @@ -1,9 +1,10 @@ { - "extends": "./tsconfig.base.json", - "include": [ - "../src/**/*" - ], - "exclude": [ - "../test" - ] + "extends": "./tsconfig.base.json", + "include": [ + "../src/**/*" + ], + "exclude": [ + "../src/_old", + "../test" + ] } diff --git a/config/tsconfig.test.json b/config/tsconfig.test.json deleted file mode 100644 index 3ee7a6c..0000000 --- a/config/tsconfig.test.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "extends": "./tsconfig.base.json" -} diff --git a/jest.json b/jest.json new file mode 100644 index 0000000..e9a4ef5 --- /dev/null +++ b/jest.json @@ -0,0 +1,19 @@ +{ + "collectCoverage": true, + "mapCoverage": true, + "transform": { + "^.+\\.tsx?$": "/node_modules/ts-jest/preprocessor.js" + }, + "testMatch": [ + "**/test/**/*.spec.ts" + ], + "testPathIgnorePatterns": [ + "/node_modules/" + ], + "moduleFileExtensions": [ + "ts", + "tsx", + "js", + "json" + ] +} diff --git a/package.json b/package.json index 77b1f95..486a4bd 100644 --- a/package.json +++ b/package.json @@ -18,13 +18,10 @@ "Other", "Languages" ], - "main": "./out/src/extension/extension", + "main": "./out/extension", "author": "Christoph Bühler ", "license": "MIT", "contributors": [], - "release": { - "getLastRelease": "semantic-release-visualstudio-marketplace-version" - }, "badges": [ { "url": "https://img.shields.io/travis/buehler/typescript-hero.svg", @@ -56,37 +53,54 @@ }, "homepage": "https://buehler.github.io/typescript-hero/", "scripts": { - "predevelop": "del-cli ./out", - "develop": "tsc", "postinstall": "node ./etc/test_install.js && node ./node_modules/vscode/bin/install || echo 'vscode/bin/install not found'", - "lint": "tslint -c tslint.json --project ./config/tsconfig.build.json", - "pretest": "del-cli ./out && tsc -p ./config/tsconfig.test.json && yarn lint", - "test": "node ./node_modules/vscode/bin/test", - "build": "del-cli ./out && tsc -p ./config/tsconfig.build.json" + "clean": "del-cli ./out ./coverage", + "build": "npm run clean && tsc -p ./config/tsconfig.build.json", + "develop": "npm run clean && tsc -p .", + "lint": "tslint -c ./tslint.json -p ./config/tsconfig.build.json", + "test": "npm run lint && npm run clean && jest -c ./jest.json", + "test:watch": "npm run clean && jest -c ./jest.json --watch --no-coverage", + "test:vscode": "echo 'beside unit test with jest, there could be integration test with node ./node_modules/vscode/bin/test'", + "semantic-release": "semantic-release" + }, + "release": { + "verifyConditions": [ + "semantic-release-vsce", + "@semantic-release/github" + ], + "getLastRelease": "semantic-release-vsce", + "publish": [ + { + "path": "semantic-release-vsce", + "packageVsix": "your-extension.vsix" + }, + { + "path": "@semantic-release/github", + "assets": "your-extension.vsix" + } + ] }, "devDependencies": { - "@types/chai": "^4.0.8", - "@types/mocha": "^2.2.44", - "@types/node": "^8.0.57", + "@smartive/tslint-config": "^2.0.0", + "@types/jest": "^22.0.1", + "@types/node": "^9.3.0", "@types/reflect-metadata": "0.1.0", - "@types/sinon": "^4.1.0", - "@types/sinon-chai": "^2.7.29", - "chai": "^4.1.2", - "cross-env": "^5.1.1", + "cross-env": "^5.1.3", "del-cli": "^1.1.0", "filewalker": "^0.1.3", - "mocha-testdata": "^1.2.0", - "sinon": "^4.1.3", - "sinon-chai": "^2.14.0", - "tslint": "^5.8.0", - "tslint-config-airbnb": "^5.4.2", - "tsutils": "^2.13.0", + "jest": "^22.1.2", + "semantic-release": "^12.2.2", + "semantic-release-vsce": "^1.0.2", + "ts-jest": "^22.0.1", + "tslint": "^5.9.1", + "tsutils": "^2.19.1", "vscode": "^1.1.10" }, "dependencies": { - "inversify": "^4.6.0", - "inversify-inject-decorators": "^3.0.2", - "reflect-metadata": "^0.1.10", + "inversify": "^4.9.0", + "inversify-inject-decorators": "^3.1.0", + "reflect-metadata": "^0.1.12", + "rxjs": "^5.5.6", "tslib": "^1.8.1", "typescript": "~2.6.2", "typescript-parser": "^2.2.2", @@ -101,56 +115,17 @@ "contributes": { "commands": [ { - "command": "typescriptHero.resolve.addImport", - "title": "TS Hero: Add an import to current file" - }, - { - "command": "typescriptHero.resolve.addImportUnderCursor", - "title": "TS Hero: Adds the current symbol under the cursor as an import to current file" - }, - { - "command": "typescriptHero.resolve.addMissingImports", - "title": "TS Hero: Adds all missing imports for the open document" - }, - { - "command": "typescriptHero.resolve.organizeImports", + "command": "typescriptHero.imports.organize", "title": "TS Hero: Organize imports (sort and remove unused)" }, { - "command": "typescriptHero.resolve.rebuildCache", - "title": "TS Hero: Rebuild the resolver cache" - }, - { - "command": "typescriptHero.codeFix.executeCodeAction", - "title": "TS Hero (internal): Execute a code action" - }, - { - "command": "typescriptHero.codeCompletion.executeIntellisenseItem", - "title": "TS Hero (internal): Execute the command for a intellisense item" - }, - { - "command": "typescriptHero.documentCodeOutline.gotoNode", + "command": "typescriptHero.codeOutline.gotoNode", "title": "TS Hero (internal): Jump to the given nodes location" } ], "keybindings": [ { - "command": "typescriptHero.resolve.addImport", - "key": "ctrl+shift+i", - "when": "editorTextFocus" - }, - { - "command": "typescriptHero.resolve.addImportUnderCursor", - "key": "ctrl+alt+i", - "when": "editorTextFocus" - }, - { - "command": "typescriptHero.resolve.addMissingImports", - "key": "ctrl+alt+shift+i", - "when": "editorTextFocus" - }, - { - "command": "typescriptHero.resolve.organizeImports", + "command": "typescriptHero.imports.organize", "key": "ctrl+alt+o", "when": "editorTextFocus" } @@ -158,7 +133,7 @@ "views": { "explorer": [ { - "id": "documentCodeOutline", + "id": "codeOutline", "name": "Code outline", "when": "config.typescriptHero.codeOutline.enabled != false" } @@ -178,28 +153,31 @@ "description": "Defines the log output level in the output window. In the log file, it's always info or debug.", "scope": "window" }, - "typescriptHero.codeCompletion.completionSortMode": { - "enum": [ - "default", - "bottom" - ], - "default": "default", - "description": "Defines the sortmode of the code completion in intellisense (bottom means sorted to bottom).", - "scope": "resource" + "typescriptHero.codeOutline.enabled": { + "type": "boolean", + "default": true, + "description": "Defines if the code outline feature (and window) are enabled or not.", + "scope": "window" }, - "typescriptHero.resolver.insertSpaceBeforeAndAfterImportBraces": { + "typescriptHero.imports.insertSpaceBeforeAndAfterImportBraces": { "type": "boolean", "default": true, "description": "Defines if there should be a space inside the curly braces of an import statement.", "scope": "resource" }, - "typescriptHero.resolver.insertSemicolons": { + "typescriptHero.imports.removeTrailingIndex": { + "type": "boolean", + "default": true, + "description": "Defines if a trailing '/index' should be removed from imports.", + "scope": "resource" + }, + "typescriptHero.imports.insertSemicolons": { "type": "boolean", "default": true, "description": "Defines if there should be a semicolon at the end of a statement.", "scope": "resource" }, - "typescriptHero.resolver.stringQuoteStyle": { + "typescriptHero.imports.stringQuoteStyle": { "enum": [ "'", "\"" @@ -208,33 +186,7 @@ "description": "Defines if single or double quotes should be used.", "scope": "resource" }, - "typescriptHero.resolver.workspaceIgnorePatterns": { - "type": "array", - "items": { - "type": "string" - }, - "uniqueItems": true, - "default": [ - "**/build/**/*", - "**/out/**/*", - "**/dist/**/*" - ], - "description": "Defines partial pathes (globs) that are ignored during indexing of the **workspace** (e.g. 'node_modules/**/*' would exclude all modules).", - "scope": "resource" - }, - "typescriptHero.resolver.moduleIgnorePatterns": { - "type": "array", - "items": { - "type": "string" - }, - "uniqueItems": true, - "default": [ - "**/node_modules/**/*" - ], - "description": "Defines partial pathes (globs) that are ignored during indexing of the **node_modules**. This patterns are attached to the node_module/ of each found module.", - "scope": "resource" - }, - "typescriptHero.resolver.multiLineWrapThreshold": { + "typescriptHero.imports.multiLineWrapThreshold": { "type": "number", "minimum": 1, "multipleOf": 1, @@ -242,36 +194,37 @@ "description": "Defines the threshold when an import should be wrapped into a multiline import.", "scope": "resource" }, - "typescriptHero.resolver.multiLineTrailingComma": { + "typescriptHero.imports.multiLineTrailingComma": { "type": "boolean", "default": true, "description": "Defined if multi line imports contain the last trailing comma.", "scope": "resource" }, - "typescriptHero.resolver.disableImportsSorting": { + "typescriptHero.imports.organizeOnSave": { "type": "boolean", "default": false, - "description": "Defines if sorting is disable during organize imports.", + "description": "Defines if the imports should be organized on save.", "scope": "resource" }, - "typescriptHero.resolver.disableImportRemovalOnOrganize": { + "typescriptHero.imports.organizeSortsByFirstSpecifier": { "type": "boolean", "default": false, - "description": "Defines, if removal unsed imports is obligatory during organize imports" + "description": "Defines if the imports are organized by first specifier/alias instead of module path.", + "scope": "resource" }, - "typescriptHero.resolver.organizeOnSave": { + "typescriptHero.imports.disableImportsSorting": { "type": "boolean", "default": false, - "description": "Defines if the imports should be organized on save.", + "description": "Defines if sorting is disable during organize imports.", "scope": "resource" }, - "typescriptHero.resolver.organizeSortsByFirstSpecifier": { + "typescriptHero.imports.disableImportRemovalOnOrganize": { "type": "boolean", "default": false, - "description": "Defines if the imports are organized by first specifier/alias instead of module path.", + "description": "Defines if any imports should be removed at all on an organize imports command.", "scope": "resource" }, - "typescriptHero.resolver.ignoreImportsForOrganize": { + "typescriptHero.imports.ignoredFromRemoval": { "type": "array", "items": { "type": "string" @@ -283,7 +236,7 @@ "description": "Defines imports (libraries, so the 'from' part), which are not removed during 'organize imports'.", "scope": "resource" }, - "typescriptHero.resolver.importGroups": { + "typescriptHero.imports.grouping": { "type": "array", "items": { "anyOf": [ @@ -352,28 +305,6 @@ ], "description": "Defines the groups of the imports ordering. Multiple groups possible, see readme for instructions.", "scope": "resource" - }, - "typescriptHero.resolver.resolverMode": { - "enum": [ - "TypeScript", - "ES6", - "Both" - ], - "default": "Both", - "description": "Defines the mode of the symbol resolver. (Note that JavaScript mode only indexes workspace files)", - "scope": "resource" - }, - "typescriptHero.resolver.promptForSpecifiers": { - "type": "boolean", - "default": true, - "description": "Defines if typescript hero should ask the user for default specifiers or duplicate specifier aliases.", - "scope": "window" - }, - "typescriptHero.codeOutline.enabled": { - "type": "boolean", - "default": true, - "description": "Defines if the code outline feature (and window) are enabled or not.", - "scope": "window" } } } diff --git a/src/common/config/CodeCompletionConfig.ts b/src/_old/common/config/CodeCompletionConfig.ts similarity index 100% rename from src/common/config/CodeCompletionConfig.ts rename to src/_old/common/config/CodeCompletionConfig.ts diff --git a/src/common/config/CodeOutlineConfig.ts b/src/_old/common/config/CodeOutlineConfig.ts similarity index 100% rename from src/common/config/CodeOutlineConfig.ts rename to src/_old/common/config/CodeOutlineConfig.ts diff --git a/src/common/config/ExtensionConfig.ts b/src/_old/common/config/ExtensionConfig.ts similarity index 100% rename from src/common/config/ExtensionConfig.ts rename to src/_old/common/config/ExtensionConfig.ts diff --git a/src/common/config/ResolverConfig.ts b/src/_old/common/config/ResolverConfig.ts similarity index 100% rename from src/common/config/ResolverConfig.ts rename to src/_old/common/config/ResolverConfig.ts diff --git a/src/common/config/index.ts b/src/_old/common/config/index.ts similarity index 100% rename from src/common/config/index.ts rename to src/_old/common/config/index.ts diff --git a/src/common/enums.ts b/src/_old/common/enums.ts similarity index 100% rename from src/common/enums.ts rename to src/_old/common/enums.ts diff --git a/src/common/errors/ClassNotFoundError.ts b/src/_old/common/errors/ClassNotFoundError.ts similarity index 100% rename from src/common/errors/ClassNotFoundError.ts rename to src/_old/common/errors/ClassNotFoundError.ts diff --git a/src/common/errors/MethodDuplicatedError.ts b/src/_old/common/errors/MethodDuplicatedError.ts similarity index 100% rename from src/common/errors/MethodDuplicatedError.ts rename to src/_old/common/errors/MethodDuplicatedError.ts diff --git a/src/common/errors/MethodNotFoundError.ts b/src/_old/common/errors/MethodNotFoundError.ts similarity index 100% rename from src/common/errors/MethodNotFoundError.ts rename to src/_old/common/errors/MethodNotFoundError.ts diff --git a/src/common/errors/NotImplementedYetError.ts b/src/_old/common/errors/NotImplementedYetError.ts similarity index 100% rename from src/common/errors/NotImplementedYetError.ts rename to src/_old/common/errors/NotImplementedYetError.ts diff --git a/src/common/errors/PropertyDuplicatedError.ts b/src/_old/common/errors/PropertyDuplicatedError.ts similarity index 100% rename from src/common/errors/PropertyDuplicatedError.ts rename to src/_old/common/errors/PropertyDuplicatedError.ts diff --git a/src/common/errors/PropertyNotFoundError.ts b/src/_old/common/errors/PropertyNotFoundError.ts similarity index 100% rename from src/common/errors/PropertyNotFoundError.ts rename to src/_old/common/errors/PropertyNotFoundError.ts diff --git a/src/common/errors/index.ts b/src/_old/common/errors/index.ts similarity index 100% rename from src/common/errors/index.ts rename to src/_old/common/errors/index.ts diff --git a/src/common/factories/index.ts b/src/_old/common/factories/index.ts similarity index 100% rename from src/common/factories/index.ts rename to src/_old/common/factories/index.ts diff --git a/src/_old/common/helpers/DeclarationIndexHelpers.ts b/src/_old/common/helpers/DeclarationIndexHelpers.ts new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/src/_old/common/helpers/DeclarationIndexHelpers.ts @@ -0,0 +1 @@ + diff --git a/src/_old/common/helpers/ImportHelpers.ts b/src/_old/common/helpers/ImportHelpers.ts new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/src/_old/common/helpers/ImportHelpers.ts @@ -0,0 +1 @@ + diff --git a/src/common/helpers/index.ts b/src/_old/common/helpers/index.ts similarity index 100% rename from src/common/helpers/index.ts rename to src/_old/common/helpers/index.ts diff --git a/src/common/quick-pick-items/ResolveQuickPickItem.ts b/src/_old/common/quick-pick-items/ResolveQuickPickItem.ts similarity index 100% rename from src/common/quick-pick-items/ResolveQuickPickItem.ts rename to src/_old/common/quick-pick-items/ResolveQuickPickItem.ts diff --git a/src/common/quick-pick-items/index.ts b/src/_old/common/quick-pick-items/index.ts similarity index 100% rename from src/common/quick-pick-items/index.ts rename to src/_old/common/quick-pick-items/index.ts diff --git a/src/extension/IoC.ts b/src/_old/extension/IoC.ts similarity index 100% rename from src/extension/IoC.ts rename to src/_old/extension/IoC.ts diff --git a/src/extension/IoCSymbols.ts b/src/_old/extension/IoCSymbols.ts similarity index 100% rename from src/extension/IoCSymbols.ts rename to src/_old/extension/IoCSymbols.ts diff --git a/src/extension/TypeScriptHero.ts b/src/_old/extension/TypeScriptHero.ts similarity index 100% rename from src/extension/TypeScriptHero.ts rename to src/_old/extension/TypeScriptHero.ts diff --git a/src/extension/code-actions/CodeAction.ts b/src/_old/extension/code-actions/CodeAction.ts similarity index 100% rename from src/extension/code-actions/CodeAction.ts rename to src/_old/extension/code-actions/CodeAction.ts diff --git a/src/extension/code-actions/CodeActionCreator.ts b/src/_old/extension/code-actions/CodeActionCreator.ts similarity index 100% rename from src/extension/code-actions/CodeActionCreator.ts rename to src/_old/extension/code-actions/CodeActionCreator.ts diff --git a/src/extension/code-actions/MissingImplementationInClassCreator.ts b/src/_old/extension/code-actions/MissingImplementationInClassCreator.ts similarity index 100% rename from src/extension/code-actions/MissingImplementationInClassCreator.ts rename to src/_old/extension/code-actions/MissingImplementationInClassCreator.ts diff --git a/src/extension/code-actions/MissingImportCreator.ts b/src/_old/extension/code-actions/MissingImportCreator.ts similarity index 100% rename from src/extension/code-actions/MissingImportCreator.ts rename to src/_old/extension/code-actions/MissingImportCreator.ts diff --git a/src/extension/code-actions/index.ts b/src/_old/extension/code-actions/index.ts similarity index 100% rename from src/extension/code-actions/index.ts rename to src/_old/extension/code-actions/index.ts diff --git a/src/extension/config/VscodeCodeCompletionConfig.ts b/src/_old/extension/config/VscodeCodeCompletionConfig.ts similarity index 100% rename from src/extension/config/VscodeCodeCompletionConfig.ts rename to src/_old/extension/config/VscodeCodeCompletionConfig.ts diff --git a/src/extension/config/VscodeCodeOutlineConfig.ts b/src/_old/extension/config/VscodeCodeOutlineConfig.ts similarity index 100% rename from src/extension/config/VscodeCodeOutlineConfig.ts rename to src/_old/extension/config/VscodeCodeOutlineConfig.ts diff --git a/src/extension/config/VscodeExtensionConfig.ts b/src/_old/extension/config/VscodeExtensionConfig.ts similarity index 100% rename from src/extension/config/VscodeExtensionConfig.ts rename to src/_old/extension/config/VscodeExtensionConfig.ts diff --git a/src/extension/config/VscodeResolverConfig.ts b/src/_old/extension/config/VscodeResolverConfig.ts similarity index 100% rename from src/extension/config/VscodeResolverConfig.ts rename to src/_old/extension/config/VscodeResolverConfig.ts diff --git a/src/extension/extension.ts b/src/_old/extension/extension.ts similarity index 100% rename from src/extension/extension.ts rename to src/_old/extension/extension.ts diff --git a/src/extension/extensions/BaseExtension.ts b/src/_old/extension/extensions/BaseExtension.ts similarity index 100% rename from src/extension/extensions/BaseExtension.ts rename to src/_old/extension/extensions/BaseExtension.ts diff --git a/src/extension/extensions/CodeActionExtension.ts b/src/_old/extension/extensions/CodeActionExtension.ts similarity index 100% rename from src/extension/extensions/CodeActionExtension.ts rename to src/_old/extension/extensions/CodeActionExtension.ts diff --git a/src/extension/extensions/CodeCompletionExtension.ts b/src/_old/extension/extensions/CodeCompletionExtension.ts similarity index 100% rename from src/extension/extensions/CodeCompletionExtension.ts rename to src/_old/extension/extensions/CodeCompletionExtension.ts diff --git a/src/extension/extensions/DocumentSymbolStructureExtension.ts b/src/_old/extension/extensions/DocumentSymbolStructureExtension.ts similarity index 100% rename from src/extension/extensions/DocumentSymbolStructureExtension.ts rename to src/_old/extension/extensions/DocumentSymbolStructureExtension.ts diff --git a/src/extension/extensions/ImportResolveExtension.ts b/src/_old/extension/extensions/ImportResolveExtension.ts similarity index 100% rename from src/extension/extensions/ImportResolveExtension.ts rename to src/_old/extension/extensions/ImportResolveExtension.ts diff --git a/src/extension/extensions/OrganizeImportsOnSaveExtension.ts b/src/_old/extension/extensions/OrganizeImportsOnSaveExtension.ts similarity index 100% rename from src/extension/extensions/OrganizeImportsOnSaveExtension.ts rename to src/_old/extension/extensions/OrganizeImportsOnSaveExtension.ts diff --git a/src/extension/helpers/index.ts b/src/_old/extension/helpers/index.ts similarity index 100% rename from src/extension/helpers/index.ts rename to src/_old/extension/helpers/index.ts diff --git a/src/_old/extension/helpers/nodeRangeHelpers.ts b/src/_old/extension/helpers/nodeRangeHelpers.ts new file mode 100644 index 0000000..c056c10 --- /dev/null +++ b/src/_old/extension/helpers/nodeRangeHelpers.ts @@ -0,0 +1,17 @@ +import { Position, Range, TextDocument } from 'vscode'; + +/** + * Returns the range of a node in the given document. If start or end is undefined, + * the document head (aka first line) is returned as range. + * + * @export + * @param {TextDocument} document + * @param {number} [start] + * @param {number} [end] + * @returns {Range} + */ +export function nodeRange(document: TextDocument, start?: number, end?: number): Range { + return start !== undefined && end !== undefined ? + new Range(document.positionAt(start), document.positionAt(end)) : + new Range(new Position(0, 0), new Position(0, 0)); +} diff --git a/src/extension/managers/ClassManager.ts b/src/_old/extension/managers/ClassManager.ts similarity index 100% rename from src/extension/managers/ClassManager.ts rename to src/_old/extension/managers/ClassManager.ts diff --git a/src/extension/managers/ObjectManager.ts b/src/_old/extension/managers/ObjectManager.ts similarity index 100% rename from src/extension/managers/ObjectManager.ts rename to src/_old/extension/managers/ObjectManager.ts diff --git a/src/extension/managers/index.ts b/src/_old/extension/managers/index.ts similarity index 100% rename from src/extension/managers/index.ts rename to src/_old/extension/managers/index.ts diff --git a/src/extension/proxy-objects/Changeable.ts b/src/_old/extension/proxy-objects/Changeable.ts similarity index 100% rename from src/extension/proxy-objects/Changeable.ts rename to src/_old/extension/proxy-objects/Changeable.ts diff --git a/src/extension/utilities/DeclarationIndexMapper.ts b/src/_old/extension/utilities/DeclarationIndexMapper.ts similarity index 100% rename from src/extension/utilities/DeclarationIndexMapper.ts rename to src/_old/extension/utilities/DeclarationIndexMapper.ts diff --git a/src/_old/old-config.json b/src/_old/old-config.json new file mode 100644 index 0000000..fd95050 --- /dev/null +++ b/src/_old/old-config.json @@ -0,0 +1,111 @@ +{ + "configuration": { + "typescriptHero.codeCompletion.completionSortMode": { + "enum": [ + "default", + "bottom" + ], + "default": "default", + "description": "Defines the sortmode of the code completion in intellisense (bottom means sorted to bottom).", + "scope": "resource" + }, + "typescriptHero.resolver.workspaceIgnorePatterns": { + "type": "array", + "items": { + "type": "string" + }, + "uniqueItems": true, + "default": [ + "**/build/**/*", + "**/out/**/*", + "**/dist/**/*" + ], + "description": "Defines partial pathes (globs) that are ignored during indexing of the **workspace** (e.g. 'node_modules/**/*' would exclude all modules).", + "scope": "resource" + }, + "typescriptHero.resolver.moduleIgnorePatterns": { + "type": "array", + "items": { + "type": "string" + }, + "uniqueItems": true, + "default": [ + "**/node_modules/**/*" + ], + "description": "Defines partial pathes (globs) that are ignored during indexing of the **node_modules**. This patterns are attached to the node_module/ of each found module.", + "scope": "resource" + }, + "typescriptHero.resolver.resolverMode": { + "enum": [ + "TypeScript", + "ES6", + "Both" + ], + "default": "Both", + "description": "Defines the mode of the symbol resolver. (Note that JavaScript mode only indexes workspace files)", + "scope": "resource" + }, + "typescriptHero.resolver.promptForSpecifiers": { + "type": "boolean", + "default": true, + "description": "Defines if typescript hero should ask the user for default specifiers or duplicate specifier aliases.", + "scope": "window" + } + }, + "commands": [ + { + "command": "typescriptHero.resolve.addImport", + "title": "TS Hero: Add an import to current file" + }, + { + "command": "typescriptHero.resolve.addImportUnderCursor", + "title": "TS Hero: Adds the current symbol under the cursor as an import to current file" + }, + { + "command": "typescriptHero.resolve.addMissingImports", + "title": "TS Hero: Adds all missing imports for the open document" + }, + { + "command": "typescriptHero.resolve.organizeImports", + "title": "TS Hero: Organize imports (sort and remove unused)" + }, + { + "command": "typescriptHero.resolve.rebuildCache", + "title": "TS Hero: Rebuild the resolver cache" + }, + { + "command": "typescriptHero.codeFix.executeCodeAction", + "title": "TS Hero (internal): Execute a code action" + }, + { + "command": "typescriptHero.codeCompletion.executeIntellisenseItem", + "title": "TS Hero (internal): Execute the command for a intellisense item" + }, + { + "command": "typescriptHero.documentCodeOutline.gotoNode", + "title": "TS Hero (internal): Jump to the given nodes location" + } + ], + "keybindings": [ + { + "command": "typescriptHero.resolve.addImport", + "key": "ctrl+shift+i", + "when": "editorTextFocus" + }, + { + "command": "typescriptHero.resolve.addImportUnderCursor", + "key": "ctrl+alt+i", + "when": "editorTextFocus" + }, + { + "command": "typescriptHero.resolve.addMissingImports", + "key": "ctrl+alt+shift+i", + "when": "editorTextFocus" + }, + { + "command": "typescriptHero.resolve.organizeImports", + "key": "ctrl+alt+o", + "when": "editorTextFocus" + } + ] +} diff --git a/src/activatable.ts b/src/activatable.ts new file mode 100644 index 0000000..824cb63 --- /dev/null +++ b/src/activatable.ts @@ -0,0 +1,6 @@ +export default interface Activatable { + setup(): void; + start(): void; + stop(): void; + dispose(): void; +} diff --git a/src/extension/assets/icons/declarations/callable.svg b/src/assets/icons/declarations/callable.svg similarity index 100% rename from src/extension/assets/icons/declarations/callable.svg rename to src/assets/icons/declarations/callable.svg diff --git a/src/extension/assets/icons/declarations/class.svg b/src/assets/icons/declarations/class.svg similarity index 100% rename from src/extension/assets/icons/declarations/class.svg rename to src/assets/icons/declarations/class.svg diff --git a/src/extension/assets/icons/declarations/const.svg b/src/assets/icons/declarations/const.svg similarity index 100% rename from src/extension/assets/icons/declarations/const.svg rename to src/assets/icons/declarations/const.svg diff --git a/src/extension/assets/icons/declarations/default.svg b/src/assets/icons/declarations/default.svg similarity index 100% rename from src/extension/assets/icons/declarations/default.svg rename to src/assets/icons/declarations/default.svg diff --git a/src/extension/assets/icons/declarations/enum.svg b/src/assets/icons/declarations/enum.svg similarity index 100% rename from src/extension/assets/icons/declarations/enum.svg rename to src/assets/icons/declarations/enum.svg diff --git a/src/extension/assets/icons/declarations/import.svg b/src/assets/icons/declarations/import.svg similarity index 100% rename from src/extension/assets/icons/declarations/import.svg rename to src/assets/icons/declarations/import.svg diff --git a/src/extension/assets/icons/declarations/interface.svg b/src/assets/icons/declarations/interface.svg similarity index 100% rename from src/extension/assets/icons/declarations/interface.svg rename to src/assets/icons/declarations/interface.svg diff --git a/src/extension/assets/icons/declarations/module.svg b/src/assets/icons/declarations/module.svg similarity index 100% rename from src/extension/assets/icons/declarations/module.svg rename to src/assets/icons/declarations/module.svg diff --git a/src/extension/assets/icons/declarations/property.svg b/src/assets/icons/declarations/property.svg similarity index 100% rename from src/extension/assets/icons/declarations/property.svg rename to src/assets/icons/declarations/property.svg diff --git a/src/extension/assets/icons/declarations/variable.svg b/src/assets/icons/declarations/variable.svg similarity index 100% rename from src/extension/assets/icons/declarations/variable.svg rename to src/assets/icons/declarations/variable.svg diff --git a/src/code-outline/base-structure-tree-item.ts b/src/code-outline/base-structure-tree-item.ts new file mode 100644 index 0000000..843d5ec --- /dev/null +++ b/src/code-outline/base-structure-tree-item.ts @@ -0,0 +1,43 @@ +import { Command, TreeItem } from 'vscode'; + +/** + * Base class for the document structure (code outline) tree items + * + * @export + * @abstract + * @class BaseStructureTreeItem + * @extends {TreeItem} + */ +export default abstract class BaseStructureTreeItem extends TreeItem { + constructor(label: string) { + super(label); + } + + /** + * Returns the children of the current structure tree item (if any) + * + * @returns {BaseStructureTreeItem[]} + * + * @memberof BaseStructureTreeItem + */ + public getChildren(): BaseStructureTreeItem[] { + return []; + } + + /** + * Creates a command with the given arguments. + * + * @protected + * @param {any[]} args + * @returns {Command} + * + * @memberof BaseStructureTreeItem + */ + protected createJumpToCommand(args: any[]): Command { + return { + arguments: args, + title: 'Jump to node', + command: 'typescriptHero.codeOutline.gotoNode', + }; + } +} diff --git a/src/code-outline/declaration-structure-tree-item.ts b/src/code-outline/declaration-structure-tree-item.ts new file mode 100644 index 0000000..4e061e7 --- /dev/null +++ b/src/code-outline/declaration-structure-tree-item.ts @@ -0,0 +1,121 @@ +import { + ClassDeclaration, + Declaration, + FunctionDeclaration, + GetterDeclaration, + InterfaceDeclaration, + MethodDeclaration, + PropertyDeclaration, + SetterDeclaration, + VariableDeclaration, +} from 'typescript-parser'; +import { stringTemplate } from 'typescript-parser/utilities/StringTemplate'; +import { CompletionItemKind, ExtensionContext, TreeItemCollapsibleState } from 'vscode'; + +import { getItemKind } from '../utilities/utility-functions'; +import BaseStructureTreeItem from './base-structure-tree-item'; + +const fileTemplate = stringTemplate`./src/assets/icons/declarations/${0}.svg`; + +/** + * Function to calculate the displayed name of the declaration structure item. + * + * @param {Declaration} declaration + * @returns {string} + */ +function getDeclarationLabel(declaration: Declaration): string { + if ( + declaration instanceof FunctionDeclaration || + declaration instanceof MethodDeclaration + ) { + const params = declaration.parameters.map(p => p.name + (p.type ? `: ${p.type}` : '')).join(', '); + return `${declaration.name}(${params})${declaration.type ? `: ${declaration.type}` : ''}`; + } + + if (declaration instanceof PropertyDeclaration) { + return declaration.name + (declaration.type ? `: ${declaration.type}` : ''); + } + + if ( + declaration instanceof ClassDeclaration || + declaration instanceof InterfaceDeclaration + ) { + return declaration.name + (declaration.typeParameters ? `<${declaration.typeParameters.join(', ')}>` : ''); + } + + if ( + declaration instanceof GetterDeclaration || + declaration instanceof SetterDeclaration + ) { + return `${declaration instanceof GetterDeclaration ? 'get' : 'set'}() ${declaration.name}` + + `${declaration.type ? `: ${declaration.type}` : ''}`; + } + + return declaration.name; +} + +/** + * Structure item that represents a typescript declaration of any way. + * + * @export + * @class DeclarationStructureTreeItem + * @extends {BaseStructureTreeItem} + */ +export default class DeclarationStructureTreeItem extends BaseStructureTreeItem { + public get iconPath(): string | undefined { + switch (getItemKind(this.declaration)) { + case CompletionItemKind.Class: + case CompletionItemKind.Keyword: + return this.context.asAbsolutePath(fileTemplate('class')); + case CompletionItemKind.Interface: + return this.context.asAbsolutePath(fileTemplate('interface')); + case CompletionItemKind.Enum: + return this.context.asAbsolutePath(fileTemplate('enum')); + case CompletionItemKind.Function: + case CompletionItemKind.Method: + return this.context.asAbsolutePath(fileTemplate('callable')); + case CompletionItemKind.Module: + return this.context.asAbsolutePath(fileTemplate('module')); + case CompletionItemKind.Property: + return this.context.asAbsolutePath(fileTemplate('property')); + default: + break; + } + + if (getItemKind(this.declaration) === CompletionItemKind.Variable) { + return (this.declaration as VariableDeclaration).isConst ? + this.context.asAbsolutePath(fileTemplate('const')) : + this.context.asAbsolutePath(fileTemplate('variable')); + } + + return this.context.asAbsolutePath(fileTemplate('default')); + } + + constructor(public declaration: Declaration, private context: ExtensionContext) { + super(getDeclarationLabel(declaration)); + + if ( + declaration instanceof ClassDeclaration || + declaration instanceof InterfaceDeclaration + ) { + this.collapsibleState = TreeItemCollapsibleState.Collapsed; + } else { + this.command = this.command = this.createJumpToCommand([declaration]); + } + } + + public getChildren(): BaseStructureTreeItem[] { + if ( + this.declaration instanceof ClassDeclaration || + this.declaration instanceof InterfaceDeclaration + ) { + return [ + ...this.declaration.accessors.map(p => new DeclarationStructureTreeItem(p, this.context)), + ...this.declaration.properties.map(p => new DeclarationStructureTreeItem(p, this.context)), + ...this.declaration.methods.map(m => new DeclarationStructureTreeItem(m, this.context)), + ]; + } + return []; + } +} + diff --git a/src/code-outline/disabled-structure-tree-item.ts b/src/code-outline/disabled-structure-tree-item.ts new file mode 100644 index 0000000..1e7dea1 --- /dev/null +++ b/src/code-outline/disabled-structure-tree-item.ts @@ -0,0 +1,14 @@ +import BaseStructureTreeItem from './base-structure-tree-item'; + +/** + * Structure tree item that is used when the feature is disabled via config. + * + * @export + * @class DisabledStructureTreeItem + * @extends {BaseStructureTreeItem} + */ +export default class DisabledStructureTreeItem extends BaseStructureTreeItem { + constructor() { + super('Feature is disabled.'); + } +} diff --git a/src/code-outline/imports-structure-tree-item.ts b/src/code-outline/imports-structure-tree-item.ts new file mode 100644 index 0000000..cdc4fb4 --- /dev/null +++ b/src/code-outline/imports-structure-tree-item.ts @@ -0,0 +1,83 @@ +import { ExternalModuleImport, Import, NamedImport, NamespaceImport, Resource, StringImport } from 'typescript-parser'; +import { ExtensionContext, TreeItemCollapsibleState } from 'vscode'; + +import BaseStructureTreeItem from './base-structure-tree-item'; + +/** + * Import specifier tree item that represents a specific (named) import of an import statement. + * + * @export + * @class ImportSpecifierStructureTreeItem + * @extends {BaseStructureTreeItem} + */ +export class ImportSpecifierStructureTreeItem extends BaseStructureTreeItem { + constructor(name: string, tsImport: Import, context: ExtensionContext) { + super(name); + this.iconPath = context.asAbsolutePath('./src/assets/icons/declarations/default.svg'); + this.command = this.createJumpToCommand([tsImport]); + } +} + +/** + * Structure item that represents an import in a file. + * + * @export + * @class ImportStructureTreeItem + * @extends {BaseStructureTreeItem} + */ +export class ImportStructureTreeItem extends BaseStructureTreeItem { + constructor(private tsImport: Import, private context: ExtensionContext) { + super(tsImport.libraryName); + this.iconPath = context.asAbsolutePath('./src/assets/icons/declarations/import.svg'); + this.command = this.createJumpToCommand([tsImport]); + + if (!(tsImport instanceof StringImport)) { + this.collapsibleState = TreeItemCollapsibleState.Collapsed; + } + } + + public getChildren(): BaseStructureTreeItem[] { + const imp = this.tsImport; + if (imp instanceof ExternalModuleImport) { + return [new ImportSpecifierStructureTreeItem(imp.alias, imp, this.context)]; + } + if (imp instanceof NamedImport) { + const specifiers = imp.specifiers.map( + s => new ImportSpecifierStructureTreeItem( + `${s.specifier}${s.alias ? ` as ${s.alias}` : ''}`, + imp, + this.context, + ), + ); + if (imp.defaultAlias) { + specifiers.unshift(new ImportSpecifierStructureTreeItem(`(default) ${imp.defaultAlias}`, imp, this.context)); + } + + return specifiers; + } + if (imp instanceof NamespaceImport) { + return [new ImportSpecifierStructureTreeItem(imp.alias, imp, this.context)]; + } + return []; + } +} + +/** + * Structure item that contains all imports from the file. + * Collapsed by default. + * + * @export + * @class ImportsStructureTreeItem + * @extends {BaseStructureTreeItem} + */ +export class ImportsStructureTreeItem extends BaseStructureTreeItem { + constructor(private resource: Resource, private context: ExtensionContext) { + super('Imports'); + this.collapsibleState = TreeItemCollapsibleState.Collapsed; + this.iconPath = context.asAbsolutePath('./src/assets/icons/declarations/module.svg'); + } + + public getChildren(): BaseStructureTreeItem[] { + return this.resource.imports.map(i => new ImportStructureTreeItem(i, this.context)); + } +} diff --git a/src/code-outline/index.ts b/src/code-outline/index.ts new file mode 100644 index 0000000..31981e4 --- /dev/null +++ b/src/code-outline/index.ts @@ -0,0 +1,184 @@ +import { inject, injectable } from 'inversify'; +import { Subscription } from 'rxjs'; +import { File, Node, TypescriptParser } from 'typescript-parser'; +import { + commands, + Disposable, + Event, + EventEmitter, + ExtensionContext, + ProviderResult, + Selection, + TextEditorRevealType, + TreeDataProvider, + window, + workspace, +} from 'vscode'; + +import Activatable from '../activatable'; +import Configuration from '../configuration'; +import iocSymbols from '../ioc-symbols'; +import { Logger } from '../utilities/logger'; +import { getScriptKind } from '../utilities/utility-functions'; +import BaseStructureTreeItem from './base-structure-tree-item'; +import DeclarationStructureTreeItem from './declaration-structure-tree-item'; +import DisabledStructureTreeItem from './disabled-structure-tree-item'; +import { ImportsStructureTreeItem } from './imports-structure-tree-item'; +import NotParseableStructureTreeItem from './not-parseable-structure-tree-item'; +import ResourceStructureTreeItem from './resource-structure-tree-item'; + +@injectable() +export default class CodeOutline implements Activatable, TreeDataProvider { + private _onDidChangeTreeData: EventEmitter; + + private subscription: Subscription; + private disposables: Disposable[] = []; + private documentCache?: File; + + public get onDidChangeTreeData(): Event { + return this._onDidChangeTreeData.event; + } + + constructor( + @inject(iocSymbols.extensionContext) private context: ExtensionContext, + @inject(iocSymbols.logger) private logger: Logger, + @inject(iocSymbols.configuration) private config: Configuration, + @inject(iocSymbols.parser) private parser: TypescriptParser, + ) { } + + public setup(): void { + this.logger.debug('Setting up CodeOutline.'); + this.subscription = this.config.configurationChanged.subscribe(() => { + if (this.config.codeOutline.isEnabled() && !this.disposables) { + this.start(); + } else if (!this.config.codeOutline.isEnabled() && this.disposables) { + this.stop(); + } + }); + this.context.subscriptions.push(commands.registerCommand( + 'typescriptHero.codeOutline.gotoNode', + (node: Node | undefined) => this.jumpToNode(node), + )); + } + + public start(): void { + if (!this.config.codeOutline.isEnabled()) { + this.logger.info(`Not starting CodeOutline. It's disabled by config.`); + return; + } + this.logger.info('Starting up CodeOutline.'); + this._onDidChangeTreeData = new EventEmitter(); + this.disposables.push(window.registerTreeDataProvider('codeOutline', this)); + this.disposables.push(this._onDidChangeTreeData); + this.disposables.push(window.onDidChangeActiveTextEditor(() => this.activeWindowChanged())); + this.disposables.push(workspace.onDidSaveTextDocument(() => this.activeWindowChanged())); + } + + public stop(): void { + if (this.config.codeOutline.isEnabled()) { + this.logger.info(`Not stopping CodeOutline. It's enabled by config.`); + return; + } + this.logger.info('Stopping CodeOutline.'); + for (const disposable of this.disposables) { + disposable.dispose(); + } + this.disposables = []; + } + + public dispose(): void { + this.logger.debug('Disposing CodeOutline.'); + if (this.subscription) { + this.subscription.unsubscribe(); + delete this.subscription; + } + for (const disposable of this.disposables) { + disposable.dispose(); + } + this.disposables = []; + } + + public getTreeItem(element: BaseStructureTreeItem): BaseStructureTreeItem { + return element; + } + + public async getChildren(element?: BaseStructureTreeItem): Promise> { + if (!window.activeTextEditor) { + return []; + } + + if (!this.config.codeOutline.isEnabled()) { + return [new DisabledStructureTreeItem()]; + } + + if (!this.config.parseableLanguages().some( + lang => lang === window.activeTextEditor!.document.languageId, + )) { + return [new NotParseableStructureTreeItem()]; + } + + if (!this.documentCache) { + try { + this.documentCache = await this.parser.parseSource( + window.activeTextEditor.document.getText(), + getScriptKind(window.activeTextEditor.document.fileName), + ); + } catch (e) { + this.logger.error( + `[CodeOutline] document could not be parsed, error: ${e}`, + ); + return []; + } + } + + if (!element) { + const items: BaseStructureTreeItem[] = []; + if (this.documentCache.imports && this.documentCache.imports.length) { + items.push(new ImportsStructureTreeItem(this.documentCache, this.context)); + } + items.push(...this.documentCache.resources.map(r => new ResourceStructureTreeItem(r, this.context))); + items.push(...this.documentCache.declarations.map(d => new DeclarationStructureTreeItem(d, this.context))); + return items; + } + return element.getChildren(); + } + + /** + * Method that recalculates the current document when the active window changed. + * + * @private + * + * @memberof DocumentSymbolStructureExtension + */ + private activeWindowChanged(): void { + this.logger.debug('[CodeOutline] activeWindowChanged, reparsing'); + this.documentCache = undefined; + this._onDidChangeTreeData.fire(); + } + + /** + * Takes a node (or undefined) and jumps to the nodes location. If undefined is passed, a warning message is displayed. + * + * @private + * @param {(Node | undefined)} node + * @returns {Promise} + * + * @memberof DocumentSymbolStructureExtension + */ + private async jumpToNode(node: Node | undefined): Promise { + if (!node) { + this.logger.warn('[CodeOutline] jumpToNode used without param'); + window.showWarningMessage('This command is for internal use only. It cannot be used from Cmd+P'); + return; + } + + if (!window.activeTextEditor || node.start === undefined) { + return; + } + + const newPosition = window.activeTextEditor.document.positionAt(node.start); + window.activeTextEditor.selection = new Selection(newPosition, newPosition); + window.activeTextEditor.revealRange(window.activeTextEditor.selection, TextEditorRevealType.InCenter); + await window.showTextDocument(window.activeTextEditor.document); + } +} diff --git a/src/code-outline/not-parseable-structure-tree-item.ts b/src/code-outline/not-parseable-structure-tree-item.ts new file mode 100644 index 0000000..7eb34db --- /dev/null +++ b/src/code-outline/not-parseable-structure-tree-item.ts @@ -0,0 +1,14 @@ +import BaseStructureTreeItem from './base-structure-tree-item'; + +/** + * Structure tree item that is used when a document is not parseable (i.e. not typescript) + * + * @export + * @class NotParseableStructureTreeItem + * @extends {BaseStructureTreeItem} + */ +export default class NotParseableStructureTreeItem extends BaseStructureTreeItem { + constructor() { + super('File not parseable.'); + } +} diff --git a/src/code-outline/resource-structure-tree-item.ts b/src/code-outline/resource-structure-tree-item.ts new file mode 100644 index 0000000..383d982 --- /dev/null +++ b/src/code-outline/resource-structure-tree-item.ts @@ -0,0 +1,31 @@ +import { Resource } from 'typescript-parser'; +import { ExtensionContext, TreeItemCollapsibleState } from 'vscode'; + +import BaseStructureTreeItem from './base-structure-tree-item'; +import DeclarationStructureTreeItem from './declaration-structure-tree-item'; +import { ImportsStructureTreeItem } from './imports-structure-tree-item'; + +/** + * Structure item that represents an additional resource in a file (namespace etc). + * + * @export + * @class ResourceStructureTreeItem + * @extends {BaseStructureTreeItem} + */ +export default class ResourceStructureTreeItem extends BaseStructureTreeItem { + constructor(public resource: Resource, private context: ExtensionContext) { + super(resource.identifier); + this.collapsibleState = TreeItemCollapsibleState.Collapsed; + this.iconPath = this.context.asAbsolutePath('./src/assets/icons/declarations/module.svg'); + } + + public getChildren(): BaseStructureTreeItem[] { + const items: BaseStructureTreeItem[] = []; + if (this.resource.imports && this.resource.imports.length) { + items.push(new ImportsStructureTreeItem(this.resource, this.context)); + } + items.push(...this.resource.resources.map(r => new ResourceStructureTreeItem(r, this.context))); + items.push(...this.resource.declarations.map(d => new DeclarationStructureTreeItem(d, this.context))); + return items; + } +} diff --git a/src/common/helpers/DeclarationIndexHelpers.ts b/src/common/helpers/DeclarationIndexHelpers.ts deleted file mode 100644 index c884801..0000000 --- a/src/common/helpers/DeclarationIndexHelpers.ts +++ /dev/null @@ -1,171 +0,0 @@ -import { existsSync } from 'fs'; -import { join, normalize, parse, relative } from 'path'; -import { - DeclarationInfo, - DefaultDeclaration, - ExternalModuleImport, - Import, - NamedImport, - NamespaceImport, -} from 'typescript-parser'; -import { toPosix } from 'typescript-parser/utilities/PathHelpers'; -import { RelativePattern, Uri, workspace, WorkspaceFolder } from 'vscode'; - -import { ExtensionConfig } from '../config'; - -/** - * Calculates a list of declarationInfos filtered by the already imported ones in the given document. - * The result is a list of declarations that are not already imported by the document. - * - * @export - * @param {ResolveIndex} resolveIndex - * @param {string} documentPath - * @param {TsImport[]} imports - * @param {string} [rootPath] - * @returns {DeclarationInfo[]} - */ -export function getDeclarationsFilteredByImports( - declarationInfos: DeclarationInfo[], - documentPath: string, - imports: Import[], - rootPath?: string, -): DeclarationInfo[] { - let declarations = declarationInfos; - - for (const tsImport of imports) { - const importedLib = getAbsolutLibraryName(tsImport.libraryName, documentPath, rootPath); - - if (tsImport instanceof NamedImport) { - declarations = declarations.filter( - d => d.from !== importedLib || - !tsImport.specifiers.some(s => s.specifier === d.declaration.name), - ); - if (tsImport.defaultAlias) { - declarations = declarations.filter( - d => !(tsImport.defaultAlias && d.declaration instanceof DefaultDeclaration && d.from === importedLib), - ); - } - } else if (tsImport instanceof NamespaceImport || tsImport instanceof ExternalModuleImport) { - declarations = declarations.filter(o => o.from !== tsImport.libraryName); - } - } - - return declarations; -} - -/** - * Returns the absolut workspace specific library path. - * If the library is a node module or a typings module, the name - * is returned. If the "lib" is in the local workspace, then the - * absolut path from the workspace root is returned. - * - * @param {string} library Name of the library - * @param {string} actualFilePath Filepath of the actually open file - * @param {string} [rootPath] Root path of the workspace - * @returns {string} Absolut path from the workspace root to the desired library - */ -export function getAbsolutLibraryName(library: string, actualFilePath: string, rootPath?: string): string { - if (!library.startsWith('.') || !rootPath) { - return library; - } - return '/' + toPosix(relative( - rootPath, - normalize(join(parse(actualFilePath).dir, library)), - )).replace(/\/$/, ''); -} - -/** - * Returns the relative path to a specific library. - * If the library is a node module or a typings module, the name - * is returned. If the "lib" is in the local workspace, then the - * relative path from the actual file is returned. - * - * @param {string} library Name of the library - * @param {string} actualFilePath Filepath of the actually open file - * @param {string} [rootPath] Root path of the workspace - * @returns {string} Relative path from the actual file to the library - */ -export function getRelativeLibraryName(library: string, actualFilePath: string, rootPath?: string): string { - if (!library.startsWith('/') || !rootPath) { - return library; - } - - const actualDir = parse('/' + relative(rootPath, actualFilePath)).dir; - let relativePath = relative(actualDir, library); - - if (!relativePath.startsWith('.')) { - relativePath = './' + relativePath; - } else if (relativePath === '..') { - relativePath += '/'; - } - return toPosix(relativePath); -} - -/** - * This function searches for files in a specific workspace folder. The files are relative to the given - * workspace folder and the searched type is determined by the configuration of the extension (TS, JS or Both mode). - * - * If a node_modules folder is present, but NO package.json, the node_modules are ignored completely. - * (For performance and memory reasons) - * - * @export - * @param {ExtensionConfig} config - * @param {WorkspaceFolder} workspaceFolder - * @returns {Promise} - */ -export async function findFiles(config: ExtensionConfig, workspaceFolder: WorkspaceFolder): Promise { - const workspaceExcludes = [ - ...config.resolver.workspaceIgnorePatterns, - 'node_modules/**/*', - 'typings/**/*', - ]; - const moduleExcludes = config.resolver.moduleIgnorePatterns; - const searches: PromiseLike[] = [ - workspace.findFiles( - new RelativePattern(workspaceFolder, `{${config.resolver.resolverModeFileGlobs.join(',')}}`), - new RelativePattern(workspaceFolder, `{${workspaceExcludes.join(',')}}`), - ), - ]; - - // TODO: check the package json and index javascript file in node_modules (?) - - let globs: string[] = ['typings/**/*.d.ts']; - let ignores: string[] = []; - const rootPath = workspaceFolder.uri.fsPath; - const hasPackageJson = existsSync(join(rootPath, 'package.json')); - - if (rootPath && hasPackageJson) { - const packageJson = require(join(rootPath, 'package.json')); - for (const folder of ['dependencies', 'devDependencies']) { - if (packageJson[folder]) { - globs = globs.concat( - Object.keys(packageJson[folder]).map(o => `node_modules/${o}/**/*.d.ts`), - ); - ignores = ignores.concat( - Object.keys(packageJson[folder]).reduce( - (all, pkg) => { - return all.concat( - moduleExcludes.map(exclude => `node_modules/${pkg}/${exclude}`), - ); - }, - [] as string[], - ), - ); - } - } - } else { - ignores.push('node_modules/**/*'); - } - - searches.push( - workspace.findFiles( - new RelativePattern(workspaceFolder, `{${globs.join(',')}}`), - new RelativePattern(workspaceFolder, `{${ignores.join(',')}}`), - ), - ); - - const uris = await Promise.all(searches); - return uris - .reduce((all, cur) => all.concat(cur), []) - .map(o => o.fsPath); -} diff --git a/src/common/helpers/ImportHelpers.ts b/src/common/helpers/ImportHelpers.ts deleted file mode 100644 index 786931e..0000000 --- a/src/common/helpers/ImportHelpers.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { Position, TextEditor } from 'vscode'; - -const REGEX_IGNORED_LINE = /^\s*(?:\/\/|\/\*\*|\*\/|\*|(['"])use strict\1)/; - -/** - * Calculate the position, where a new import should be inserted. - * Does respect the "use strict" string as first line of a document. - * - * @export - * @param {TextEditor | undefined} editor - * @returns {Position} - */ -export function getImportInsertPosition(editor: TextEditor | undefined): Position { - if (!editor) { - return new Position(0, 0); - } - const lines = editor.document.getText().split('\n'); - const index = lines.findIndex(line => !REGEX_IGNORED_LINE.test(line)); - return new Position(Math.max(0, index), 0); -} diff --git a/src/configuration/document-outline-config.ts b/src/configuration/document-outline-config.ts new file mode 100644 index 0000000..0404d16 --- /dev/null +++ b/src/configuration/document-outline-config.ts @@ -0,0 +1,9 @@ +import { workspace } from 'vscode'; + +const sectionKey = 'typescriptHero.codeOutline'; + +export default class DocumentOutlineConfig { + public isEnabled(): boolean { + return workspace.getConfiguration(sectionKey).get('enabled', true); + } +} diff --git a/src/configuration/imports-config.ts b/src/configuration/imports-config.ts new file mode 100644 index 0000000..4a7a92f --- /dev/null +++ b/src/configuration/imports-config.ts @@ -0,0 +1,76 @@ +import { Uri, workspace } from 'vscode'; + +import { + ImportGroup, + ImportGroupSetting, + ImportGroupSettingParser, + RemainImportGroup, +} from '../import-organizer/import-grouping'; + +const sectionKey = 'typescriptHero.imports'; + +export default class ImportsConfig { + public insertSpaceBeforeAndAfterImportBraces(resource: Uri): boolean { + return workspace.getConfiguration(sectionKey, resource).get('insertSpaceBeforeAndAfterImportBraces', true); + } + + public insertSemicolons(resource: Uri): boolean { + return workspace.getConfiguration(sectionKey, resource).get('insertSemicolons', true); + } + + public removeTrailingIndex(resource: Uri): boolean { + return workspace.getConfiguration(sectionKey, resource).get('removeTrailingIndex', true); + } + + public stringQuoteStyle(resource: Uri): '"' | '\'' { + return workspace.getConfiguration(sectionKey, resource).get('stringQuoteStyle', `'`); + } + + public multiLineWrapThreshold(resource: Uri): number { + return workspace.getConfiguration(sectionKey, resource).get('multiLineWrapThreshold', 125); + } + + public multiLineTrailingComma(resource: Uri): boolean { + return workspace.getConfiguration(sectionKey, resource).get('multiLineTrailingComma', true); + } + + public disableImportRemovalOnOrganize(resource: Uri): boolean { + return workspace.getConfiguration(sectionKey, resource).get('disableImportRemovalOnOrganize', false); + } + + public disableImportsSorting(resource: Uri): boolean { + return workspace.getConfiguration(sectionKey, resource).get('disableImportsSorting', false); + } + + public organizeOnSave(resource: Uri): boolean { + return workspace.getConfiguration(sectionKey, resource).get('organizeOnSave', false); + } + + public organizeSortsByFirstSpecifier(resource: Uri): boolean { + return workspace.getConfiguration(sectionKey, resource).get('organizeSortsByFirstSpecifier', false); + } + + public ignoredFromRemoval(resource: Uri): string[] { + return workspace.getConfiguration(sectionKey, resource).get('ignoredFromRemoval', ['react']); + } + + public grouping(resource: Uri): ImportGroup[] { + const groups = workspace.getConfiguration(sectionKey, resource).get('importGroups'); + let importGroups: ImportGroup[] = []; + + try { + if (groups) { + importGroups = groups.map(g => ImportGroupSettingParser.parseSetting(g)); + } else { + importGroups = ImportGroupSettingParser.default; + } + } catch (e) { + importGroups = ImportGroupSettingParser.default; + } + if (!importGroups.some(i => i instanceof RemainImportGroup)) { + importGroups.push(new RemainImportGroup()); + } + + return importGroups; + } +} diff --git a/src/configuration/index.ts b/src/configuration/index.ts new file mode 100644 index 0000000..a77f689 --- /dev/null +++ b/src/configuration/index.ts @@ -0,0 +1,60 @@ +import { inject, injectable } from 'inversify'; +import { Observable, Subject } from 'rxjs'; +import { TypescriptGenerationOptions } from 'typescript-parser'; +import { ExtensionContext, Uri, window, workspace } from 'vscode'; + +import iocSymbols from '../ioc-symbols'; +import DocumentOutlineConfig from './document-outline-config'; +import ImportsConfig from './imports-config'; + +const sectionKey = 'typescriptHero'; + +@injectable() +export default class Configuration { + public readonly codeOutline: DocumentOutlineConfig = new DocumentOutlineConfig(); + public readonly imports: ImportsConfig = new ImportsConfig(); + + private readonly _configurationChanged: Subject = new Subject(); + + public get configurationChanged(): Observable { + return this._configurationChanged; + } + + constructor( + @inject(iocSymbols.extensionContext) context: ExtensionContext, + ) { + context.subscriptions.push( + workspace.onDidChangeConfiguration(() => this._configurationChanged.next()), + ); + } + + public parseableLanguages(): string[] { + return [ + 'typescript', + 'typescriptreact', + 'javascript', + 'javascriptreact', + ]; + } + + public verbosity(): 'error' | 'warn' | 'info' | 'debug' { + const verbosity = workspace.getConfiguration(sectionKey).get<'error' | 'warn' | 'info' | 'debug'>('verbosity', 'warn'); + if (['error', 'warn', 'info', 'debug'].indexOf(verbosity) < 0) { + return 'warn'; + } + return verbosity; + } + + public typescriptGeneratorOptions(resource: Uri): TypescriptGenerationOptions { + return { + eol: this.imports.insertSemicolons(resource) ? ';' : '', + multiLineTrailingComma: this.imports.multiLineTrailingComma(resource), + multiLineWrapThreshold: this.imports.multiLineWrapThreshold(resource), + spaceBraces: this.imports.insertSpaceBeforeAndAfterImportBraces(resource), + stringQuoteStyle: this.imports.stringQuoteStyle(resource), + tabSize: window.activeTextEditor && window.activeTextEditor.options.tabSize ? + (window.activeTextEditor.options.tabSize as any) * 1 : + workspace.getConfiguration('editor', resource).get('tabSize', 4), + }; + } +} diff --git a/src/extension.ts b/src/extension.ts new file mode 100644 index 0000000..03db1e8 --- /dev/null +++ b/src/extension.ts @@ -0,0 +1,38 @@ +import 'reflect-metadata'; + +import { ExtensionContext } from 'vscode'; + +import Activatable from './activatable'; +import ioc from './ioc'; +import iocSymbols from './ioc-symbols'; +import TypescriptHero from './typescript-hero'; + +let extension: Activatable; + +/** + * Activates TypeScript Hero + * + * @export + * @param {ExtensionContext} context + */ +export async function activate(context: ExtensionContext): Promise { + if (ioc.isBound(iocSymbols.extensionContext)) { + ioc.unbind(iocSymbols.extensionContext); + } + ioc.bind(iocSymbols.extensionContext).toConstantValue(context); + + extension = ioc.get(TypescriptHero); + + extension.setup(); + extension.start(); +} + +/** + * Deactivates TypeScript Hero + * + * @export + */ +export function deactivate(): void { + extension.stop(); + extension.dispose(); +} diff --git a/src/extension/helpers/nodeRangeHelpers.ts b/src/extension/helpers/nodeRangeHelpers.ts deleted file mode 100644 index 43b204e..0000000 --- a/src/extension/helpers/nodeRangeHelpers.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { Position, Range, TextDocument } from 'vscode'; - -/** - * Returns the range of a node in the given document. If start or end is undefined, - * the document head (aka first line) is returned as range. - * - * @export - * @param {TextDocument} document - * @param {number} [start] - * @param {number} [end] - * @returns {Range} - */ -export function nodeRange(document: TextDocument, start?: number, end?: number): Range { - return start !== undefined && end !== undefined ? - new Range(document.positionAt(start), document.positionAt(end)) : - new Range(new Position(0, 0), new Position(0, 0)); -} - -/** - * Function that calculates the range object for an import. - * - * @export - * @param {TextDocument} document - * @param {number} [start] - * @param {number} [end] - * @returns {Range} - */ -export function importRange(document: TextDocument, start?: number, end?: number): Range { - return start !== undefined && end !== undefined ? - new Range( - document.lineAt(document.positionAt(start).line).rangeIncludingLineBreak.start, - document.lineAt(document.positionAt(end).line).rangeIncludingLineBreak.end, - ) : - new Range(new Position(0, 0), new Position(0, 0)); -} diff --git a/src/extension/import-grouping/ImportGroup.ts b/src/extension/import-grouping/ImportGroup.ts deleted file mode 100644 index a2095da..0000000 --- a/src/extension/import-grouping/ImportGroup.ts +++ /dev/null @@ -1,56 +0,0 @@ -import { Import } from 'typescript-parser'; - -import { ImportGroupOrder } from './ImportGroupOrder'; - -/** - * Interface for an import group. A group contains a list of imports that are grouped and sorted - * together on organizing all imports and inserting new imports. - * - * @export - * @interface ImportGroup - * @extends {Generatable} - */ -export interface ImportGroup { - /** - * The readonly list of imports for this group. - * - * @type {Import[]} - * @memberof ImportGroup - */ - readonly imports: Import[]; - - /** - * A sorted list of the imports of this group. - * - * @type {Import[]} - * @memberof ImportGroup - */ - readonly sortedImports: Import[]; - - /** - * The order of the imports (asc / desc). - * - * @type {ImportGroupOrder} - * @memberof ImportGroup - */ - order: ImportGroupOrder; - - /** - * Adds the given import to itself if it is the correct group for the import. Does return true if the import is - * handled, otherwise it must return false. - * - * @param {Import} tsImport - * @returns {boolean} - * - * @memberof ImportGroup - */ - processImport(tsImport: Import): boolean; - - /** - * Resets the import group (clears the imports). - * - * - * @memberof ImportGroup - */ - reset(): void; -} diff --git a/src/extension/import-grouping/ImportGroupSettingParser.ts b/src/extension/import-grouping/ImportGroupSettingParser.ts deleted file mode 100644 index 03ea14a..0000000 --- a/src/extension/import-grouping/ImportGroupSettingParser.ts +++ /dev/null @@ -1,80 +0,0 @@ -import { ImportGroup } from './ImportGroup'; -import { ImportGroupIdentifierInvalidError } from './ImportGroupIdentifierInvalidError'; -import { ImportGroupKeyword } from './ImportGroupKeyword'; -import { ImportGroupOrder } from './ImportGroupOrder'; -import { KeywordImportGroup } from './KeywordImportGroup'; -import { RegexImportGroup } from './RegexImportGroup'; -import { RemainImportGroup } from './RemainImportGroup'; - -/** - * Inserted setting that is contained in the settings.json of .vscode. - */ -export type ImportGroupSetting = string | { identifier: string, order: ImportGroupOrder }; - -const REGEX_REGEX_GROUP = /^\/.+\/$/; - -/** - * Parser that takes the vscode - setting and creates import groups out of it. - * Contains a default if the parsing fails. - * - * @export - * @class ImportGroupSettingParser - */ -export class ImportGroupSettingParser { - /** - * Default value for the import groups. - * Contains the following: - * - Plain imports - * - Module imports - * - Workspace imports - * - * @readonly - * @static - * @type {ImportGroup[]} - * @memberof ImportGroupSettingParser - */ - public static get default(): ImportGroup[] { - return [ - new KeywordImportGroup(ImportGroupKeyword.Plains), - new KeywordImportGroup(ImportGroupKeyword.Modules), - new KeywordImportGroup(ImportGroupKeyword.Workspace), - new RemainImportGroup(), - ]; - } - - /** - * Function that takes a string or object ({@link ImportGroupSetting}) and parses an import group out of it. - * - * @static - * @param {ImportGroupSetting} setting - * @returns {ImportGroup} - * @throws {ImportGroupIdentifierInvalidError} When the identifier is invalid (neither keyword nor valid regex) - * - * @memberof ImportGroupSettingParser - */ - public static parseSetting(setting: ImportGroupSetting): ImportGroup { - let identifier: string; - let order: ImportGroupOrder = 'asc'; - - if (typeof setting === 'string') { - identifier = setting; - } else { - identifier = setting.identifier; - order = setting.order; - } - - if (REGEX_REGEX_GROUP.test(identifier)) { - return new RegexImportGroup(identifier, order); - } - - if (ImportGroupKeyword[identifier] === ImportGroupKeyword.Remaining) { - return new RemainImportGroup(order); - } - - if (ImportGroupKeyword[identifier] !== undefined) { - return new KeywordImportGroup(ImportGroupKeyword[identifier], order); - } - - throw new ImportGroupIdentifierInvalidError(identifier); - } -} diff --git a/src/extension/import-grouping/KeywordImportGroup.ts b/src/extension/import-grouping/KeywordImportGroup.ts deleted file mode 100644 index fe62527..0000000 --- a/src/extension/import-grouping/KeywordImportGroup.ts +++ /dev/null @@ -1,104 +0,0 @@ -import { Import, StringImport } from 'typescript-parser'; - -import { importSort } from '../utilities/utilityFunctions'; -import { ImportGroup } from './ImportGroup'; -import { ImportGroupKeyword } from './ImportGroupKeyword'; -import { ImportGroupOrder } from './ImportGroupOrder'; - -/** - * Importgroup for keywords. Uses "Modules", "Plains", "Workspace" as a keyword and processes the corresponding imports. - * - * @export - * @class KeywordImportGroup - * @implements {ImportGroup} - */ -export class KeywordImportGroup implements ImportGroup { - public readonly imports: Import[] = []; - - public get sortedImports(): Import[] { - return this.imports.sort((i1, i2) => importSort(i1, i2, this.order)); - } - - constructor(public readonly keyword: ImportGroupKeyword, public readonly order: ImportGroupOrder = 'asc') { } - - public reset(): void { - this.imports.length = 0; - } - - public processImport(tsImport: Import): boolean { - switch (this.keyword) { - case ImportGroupKeyword.Modules: - return this.processModulesImport(tsImport); - case ImportGroupKeyword.Plains: - return this.processPlainsImport(tsImport); - case ImportGroupKeyword.Workspace: - return this.processWorkspaceImport(tsImport); - default: - return false; - } - } - - /** - * Process a library import. - * @example import ... from 'vscode'; - * - * @private - * @param {Import} tsImport - * @returns {boolean} - * - * @memberof KeywordImportGroup - */ - private processModulesImport(tsImport: Import): boolean { - if ( - tsImport instanceof StringImport || - tsImport.libraryName.startsWith('.') || - tsImport.libraryName.startsWith('/') - ) { - return false; - } - this.imports.push(tsImport); - return true; - } - - /** - * Process a string only import. - * @example import 'reflect-metadata'; - * - * @private - * @param {Import} tsImport - * @returns {boolean} - * - * @memberof KeywordImportGroup - */ - private processPlainsImport(tsImport: Import): boolean { - if (!(tsImport instanceof StringImport)) { - return false; - } - this.imports.push(tsImport); - return true; - } - - /** - * Process a workspace import (not string nor lib import). - * @example import ... from './server'; - * - * @private - * @param {Import} tsImport - * @returns {boolean} - * - * @memberof KeywordImportGroup - */ - private processWorkspaceImport(tsImport: Import): boolean { - if ( - tsImport instanceof StringImport || - ( - !tsImport.libraryName.startsWith('.') && - !tsImport.libraryName.startsWith('/') - ) - ) { - return false; - } - this.imports.push(tsImport); - return true; - } -} diff --git a/src/extension/import-grouping/RegexImportGroup.ts b/src/extension/import-grouping/RegexImportGroup.ts deleted file mode 100644 index 3068273..0000000 --- a/src/extension/import-grouping/RegexImportGroup.ts +++ /dev/null @@ -1,51 +0,0 @@ -import { Import, StringImport } from 'typescript-parser'; - -import { importSort } from '../utilities/utilityFunctions'; -import { ImportGroup } from './ImportGroup'; -import { ImportGroupOrder } from './ImportGroupOrder'; - -/** - * Importgroup that processes all imports that match a certain regex (the lib name). - * - * @export - * @class RegexImportGroup - * @implements {ImportGroup} - */ -export class RegexImportGroup implements ImportGroup { - public readonly imports: Import[] = []; - - public get sortedImports(): Import[] { - const sorted = this.imports.sort((i1, i2) => importSort(i1, i2, this.order)); - return [ - ...sorted.filter(i => i instanceof StringImport), - ...sorted.filter(i => !(i instanceof StringImport)), - ]; - } - - /** - * Creates an instance of RegexImportGroup. - * - * @param {string} regex The regex that is matched against the imports library name. - * @param {ImportGroupOrder} [order='asc'] - * - * @memberof RegexImportGroup - */ - constructor(public readonly regex: string, public readonly order: ImportGroupOrder = 'asc') { } - - public reset(): void { - this.imports.length = 0; - } - - public processImport(tsImport: Import): boolean { - let regexString = this.regex; - regexString = regexString.startsWith('/') ? regexString.substring(1) : regexString; - regexString = regexString.endsWith('/') ? regexString.substring(0, regexString.length - 1) : regexString; - const regex = new RegExp(regexString, 'g'); - - if (regex.test(tsImport.libraryName)) { - this.imports.push(tsImport); - return true; - } - return false; - } -} diff --git a/src/extension/import-grouping/RemainImportGroup.ts b/src/extension/import-grouping/RemainImportGroup.ts deleted file mode 100644 index e7cb2cc..0000000 --- a/src/extension/import-grouping/RemainImportGroup.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { Import, StringImport } from 'typescript-parser'; - -import { importSort } from '../utilities/utilityFunctions'; -import { ImportGroup } from './ImportGroup'; -import { ImportGroupOrder } from './ImportGroupOrder'; - -/** - * Importgroup that processes all imports. Should be used if other groups don't process the import. - * - * @export - * @class RemainImportGroup - * @implements {ImportGroup} - */ -export class RemainImportGroup implements ImportGroup { - public readonly imports: Import[] = []; - - public get sortedImports(): Import[] { - const sorted = this.imports.sort((i1, i2) => importSort(i1, i2, this.order)); - return [ - ...sorted.filter(i => i instanceof StringImport), - ...sorted.filter(i => !(i instanceof StringImport)), - ]; - } - - constructor(public readonly order: ImportGroupOrder = 'asc') { } - - public reset(): void { - this.imports.length = 0; - } - - public processImport(tsImport: Import): boolean { - this.imports.push(tsImport); - return true; - } -} diff --git a/src/extension/managers/ImportManager.ts b/src/extension/managers/ImportManager.ts deleted file mode 100644 index cead6bd..0000000 --- a/src/extension/managers/ImportManager.ts +++ /dev/null @@ -1,552 +0,0 @@ -import { - DeclarationIndex, - DeclarationInfo, - DefaultDeclaration, - ExternalModuleImport, - File, - Import, - isAliasedImport, - ModuleDeclaration, - NamedImport, - NamespaceImport, - StringImport, - SymbolSpecifier, - TypescriptCodeGenerator, - TypescriptParser, -} from 'typescript-parser'; -import { InputBoxOptions, Range, TextDocument, TextEdit, window, workspace, WorkspaceEdit } from 'vscode'; - -import { ExtensionConfig } from '../../common/config'; -import { ConfigFactory } from '../../common/factories'; -import { - getAbsolutLibraryName, - getDeclarationsFilteredByImports, - getImportInsertPosition, - getRelativeLibraryName, -} from '../../common/helpers'; -import { ResolveQuickPickItem } from '../../common/quick-pick-items'; -import { importRange } from '../helpers'; -import { ImportGroup } from '../import-grouping'; -import { Container } from '../IoC'; -import { iocSymbols } from '../IoCSymbols'; -import { - getScriptKind, - importGroupSortForPrecedence, - importSort, - importSortByFirstSpecifier, - specifierSort, -} from '../utilities/utilityFunctions'; -import { Logger } from '../utilities/winstonLogger'; -import { ObjectManager } from './ObjectManager'; - -function sameSpecifiers(specs1: SymbolSpecifier[], specs2: SymbolSpecifier[]): boolean { - for (const spec of specs1) { - const spec2 = specs2[specs1.indexOf(spec)]; - if (!spec2 || - spec.specifier !== spec2.specifier || - spec.alias !== spec2.alias) { - return false; - } - } - return true; -} - -/** - * Management class for the imports of a document. Can add and remove imports to the document - * and commit the virtual document to the TextEditor. - * - * @export - * @class ImportManager - */ -export class ImportManager implements ObjectManager { - private static get parser(): TypescriptParser { - return Container.get(iocSymbols.typescriptParser); - } - - private static get config(): ConfigFactory { - return Container.get(iocSymbols.configuration); - } - - private static get generator(): TypescriptCodeGenerator { - return Container.get<() => TypescriptCodeGenerator>(iocSymbols.generatorFactory)(); - } - - private static get logger(): Logger { - return Container.get(iocSymbols.logger); - } - - private importGroups: ImportGroup[]; - private imports: Import[] = []; - private userImportDecisions: { [usage: string]: DeclarationInfo[] }[] = []; - private organize: boolean; - - private get config(): ExtensionConfig { - return ImportManager.config(this.document.uri); - } - - private get rootPath(): string | undefined { - const rootFolder = workspace.getWorkspaceFolder(this.document.uri); - return rootFolder ? rootFolder.uri.fsPath : undefined; - } - - /** - * Document resource for this controller. Contains the parsed document. - * - * @readonly - * @type {File} - * @memberof ImportManager - */ - public get parsedDocument(): File { - return this._parsedDocument; - } - - private constructor( - public readonly document: TextDocument, - private _parsedDocument: File, - ) { - ImportManager.logger.debug( - '[%s] create import manager', - ImportManager.name, - { file: document.fileName }, - ); - this.reset(); - } - - /** - * Creates an instance of an ImportManager. - * Does parse the document text first and returns a promise that - * resolves to an ImportManager. - * - * @static - * @param {TextDocument} document The document that should be managed - * @returns {Promise} - * - * @memberof ImportManager - */ - public static async create(document: TextDocument): Promise { - const source = await ImportManager.parser.parseSource(document.getText(), getScriptKind(document.fileName)); - return new ImportManager(document, source); - } - - /** - * Resets the imports and the import groups back to the initial state of the parsed document. - * - * @memberof ImportManager - */ - public reset(): void { - this.imports = this._parsedDocument.imports.map(o => o.clone()); - this.importGroups = this.config.resolver.importGroups; - this.addImportsToGroups(this.imports); - } - - /** - * Adds an import for a declaration to the documents imports. - * This index is merged and commited during the commit() function. - * If it's a default import or there is a duplicate identifier, the controller will ask for the name on commit(). - * - * @param {DeclarationInfo} declarationInfo The import that should be added to the document - * @returns {ImportManager} - * - * @memberof ImportManager - */ - public addDeclarationImport(declarationInfo: DeclarationInfo): this { - ImportManager.logger.debug( - '[%s] add declaration as import', - ImportManager.name, - { file: this.document.fileName, specifier: declarationInfo.declaration.name, library: declarationInfo.from }, - ); - // If there is something already imported, it must be a NamedImport - const alreadyImported: NamedImport = this.imports.find( - o => declarationInfo.from === getAbsolutLibraryName( - o.libraryName, - this.document.fileName, - this.rootPath, - ) && o instanceof NamedImport, - ) as NamedImport; - - if (alreadyImported) { - // If we found an import for this declaration, it's named import (with a possible default declaration) - if (declarationInfo.declaration instanceof DefaultDeclaration) { - delete alreadyImported.defaultAlias; - alreadyImported.defaultAlias = declarationInfo.declaration.name; - } else if (!alreadyImported.specifiers.some(o => o.specifier === declarationInfo.declaration.name)) { - alreadyImported.specifiers.push(new SymbolSpecifier(declarationInfo.declaration.name)); - } - } else { - let imp: Import = new NamedImport(getRelativeLibraryName( - declarationInfo.from, - this.document.fileName, - this.rootPath, - )); - - if (declarationInfo.declaration instanceof ModuleDeclaration) { - imp = new NamespaceImport( - declarationInfo.from, - declarationInfo.declaration.name, - ); - } else if (declarationInfo.declaration instanceof DefaultDeclaration) { - (imp as NamedImport).defaultAlias = declarationInfo.declaration.name; - } else { - (imp as NamedImport).specifiers.push(new SymbolSpecifier(declarationInfo.declaration.name)); - } - this.imports.push(imp); - this.addImportsToGroups([imp]); - } - - return this; - } - - /** - * Adds all missing imports to the actual document. If multiple declarations are found for one missing - * specifier, the user is asked when the commit() function is executed. - * - * @param {DeclarationIndex} index - * @returns {this} - * - * @memberof ImportManager - */ - public addMissingImports(index: DeclarationIndex): this { - ImportManager.logger.debug( - '[%s] add all missing imports', - ImportManager.name, - { file: this.document.fileName }, - ); - const declarations = getDeclarationsFilteredByImports( - index.declarationInfos, - this.document.fileName, - this.imports, - this.rootPath, - ); - - for (const usage of this._parsedDocument.nonLocalUsages) { - const foundDeclarations = declarations.filter(o => o.declaration.name === usage); - if (foundDeclarations.length <= 0) { - continue; - } else if (foundDeclarations.length === 1) { - this.addDeclarationImport(foundDeclarations[0]); - } else { - this.userImportDecisions[usage] = foundDeclarations; - } - } - return this; - } - - /** - * Organizes the imports of the document. Orders all imports and removes unused imports. - * Order: - * 1. string-only imports (e.g. import 'reflect-metadata') - * 2. rest, but in alphabetical order - * - * @returns {ImportManager} - * - * @memberof ImportManager - */ - public organizeImports(): this { - ImportManager.logger.debug( - '[%s] organize the imports', - ImportManager.name, - { file: this.document.fileName }, - ); - this.organize = true; - let keep: Import[] = []; - - if (this.config.resolver.disableImportRemovalOnOrganize) { - keep = this.imports; - } else { - for (const actImport of this.imports) { - if (this.config.resolver.ignoreImportsForOrganize.indexOf(actImport.libraryName) >= 0) { - keep.push(actImport); - continue; - } - if (actImport instanceof NamespaceImport || - actImport instanceof ExternalModuleImport) { - if (this._parsedDocument.nonLocalUsages.indexOf(actImport.alias) > -1) { - keep.push(actImport); - } - } else if (actImport instanceof NamedImport) { - actImport.specifiers = actImport.specifiers - .filter(o => this._parsedDocument.nonLocalUsages.indexOf(o.alias || o.specifier) > -1) - .sort(specifierSort); - const defaultSpec = actImport.defaultAlias; - if (actImport.specifiers.length || - (!!defaultSpec && this._parsedDocument.nonLocalUsages.indexOf(defaultSpec) >= 0)) { - keep.push(actImport); - } - } else if (actImport instanceof StringImport) { - keep.push(actImport); - } - } - } - - if (!this.config.resolver.disableImportSorting) { - const sorter = this.config.resolver.organizeSortsByFirstSpecifier - ? importSortByFirstSpecifier - : importSort; - - keep = [ - ...keep.filter(o => o instanceof StringImport).sort(sorter), - ...keep.filter(o => !(o instanceof StringImport)).sort(sorter), - ]; - } - - for (const group of this.importGroups) { - group.reset(); - } - this.imports = keep; - this.addImportsToGroups(this.imports); - - return this; - } - - /** - * Does commit the currently virtual document to the TextEditor. - * Returns a promise that resolves to a boolean if all changes - * could be applied. - * - * @returns {Promise} - * - * @memberof ImportManager - */ - public async commit(): Promise { - await this.resolveImportSpecifiers(); - - const edits: TextEdit[] = this.calculateTextEdits(); - const workspaceEdit = new WorkspaceEdit(); - - workspaceEdit.set(this.document.uri, edits); - - ImportManager.logger.debug( - '[%s] commit the file', - ImportManager.name, - { file: this.document.fileName }, - ); - - const result = await workspace.applyEdit(workspaceEdit); - - if (result) { - delete this.organize; - this._parsedDocument = await ImportManager.parser.parseSource( - this.document.getText(), - getScriptKind(this.document.fileName), - ); - this.imports = this._parsedDocument.imports.map(o => o.clone()); - for (const group of this.importGroups) { - group.reset(); - } - this.addImportsToGroups(this.imports); - } - - return result; - } - - /** - * Calculate the needed {@link TextEdit} array for the actual changes in the imports. - * - * @returns {TextEdit[]} - * - * @memberof ImportManager - */ - public calculateTextEdits(): TextEdit[] { - const edits: TextEdit[] = []; - - if (this.organize) { - // since the imports should be organized: - // delete all imports and the following lines (if empty) - // newly generate all groups. - for (const imp of this._parsedDocument.imports) { - edits.push(TextEdit.delete(importRange(this.document, imp.start, imp.end))); - if (imp.end !== undefined) { - const nextLine = this.document.lineAt(this.document.positionAt(imp.end).line + 1); - if (nextLine.text === '') { - edits.push(TextEdit.delete(nextLine.rangeIncludingLineBreak)); - } - } - } - const imports = this.importGroups - .map(group => ImportManager.generator.generate(group as any)) - .filter(Boolean) - .join('\n'); - if (!!imports) { - edits.push(TextEdit.insert( - getImportInsertPosition(window.activeTextEditor), - `${imports}\n`, - )); - } - } else { - // Commit the documents imports: - // 1. Remove imports that are in the document, but not anymore - // 2. Update existing / insert new ones - for (const imp of this._parsedDocument.imports) { - if (!this.imports.some(o => o.libraryName === imp.libraryName)) { - edits.push(TextEdit.delete(importRange(this.document, imp.start, imp.end))); - } - } - const actualDocumentsNamed = this._parsedDocument.imports.filter(o => o instanceof NamedImport); - for (const imp of this.imports) { - if (imp instanceof NamedImport && - actualDocumentsNamed.some((o: NamedImport) => - o.libraryName === imp.libraryName && - o.defaultAlias === imp.defaultAlias && - o.specifiers.length === imp.specifiers.length && - sameSpecifiers(o.specifiers, imp.specifiers))) { - continue; - } - if (imp.isNew) { - edits.push(TextEdit.insert( - getImportInsertPosition( - window.activeTextEditor, - ), - ImportManager.generator.generate(imp) + '\n', - )); - } else { - edits.push(TextEdit.replace( - new Range( - this.document.positionAt(imp.start!), - this.document.positionAt(imp.end!), - ), - ImportManager.generator.generate(imp), - )); - } - } - } - - return edits; - } - - /** - * Add a list of imports to the groups of the ImportManager. - * - * @private - * @param {Import[]} imports - * - * @memberof ImportManager - */ - private addImportsToGroups(imports: Import[]): void { - const importGroupsWithPrecedence = importGroupSortForPrecedence(this.importGroups); - for (const tsImport of imports) { - for (const group of importGroupsWithPrecedence) { - if (group.processImport(tsImport)) { - break; - } - } - } - } - - /** - * Solves conflicts in named specifiers and does ask the user for aliases. Also resolves namings for default - * imports. As long as the user has a duplicate, he will be asked again. - * - * @private - * @returns {Promise} - * - * @memberof ImportManager - */ - private async resolveImportSpecifiers(): Promise { - const getSpecifiers = () => this.imports - .reduce( - (all, cur) => { - let specifiers = all; - if (cur instanceof NamedImport) { - specifiers = specifiers.concat(cur.specifiers.map(o => o.alias || o.specifier)); - if (cur.defaultAlias) { - specifiers.push(cur.defaultAlias); - } - } - if (isAliasedImport(cur)) { - specifiers.push(cur.alias); - } - return specifiers; - }, - [] as string[], - ); - - for (const decision of Object.keys( - this.userImportDecisions, - ).filter(o => this.userImportDecisions[o].length > 0)) { - const declarations: ResolveQuickPickItem[] = this.userImportDecisions[decision].map( - o => new ResolveQuickPickItem(o), - ); - - const result = await window.showQuickPick(declarations, { - placeHolder: `Multiple declarations for "${decision}" found.`, - }); - - if (result) { - this.addDeclarationImport(result.declarationInfo); - } - } - - const named = this.imports.filter(o => o instanceof NamedImport) as NamedImport[]; - - for (const imp of named) { - if (imp.defaultAlias) { - const specifiers = getSpecifiers(); - if ( - specifiers.filter(o => o === imp.defaultAlias).length > 1 && - this.config.resolver.promptForSpecifiers - ) { - imp.defaultAlias = await this.getDefaultIdentifier(imp.defaultAlias); - } - } - - for (const spec of imp.specifiers) { - const specifiers = getSpecifiers(); - if ( - specifiers.filter(o => o === (spec.alias || spec.specifier)).length > 1 && - this.config.resolver.promptForSpecifiers - ) { - spec.alias = await this.getSpecifierAlias(spec.alias || spec.specifier); - } - } - } - } - - /** - * Does resolve a duplicate specifier issue. - * - * @private - * @returns {Promise} - * - * @memberof ImportManager - */ - private async getSpecifierAlias(specifierName: string): Promise { - const result = await this.vscodeInputBox({ - placeHolder: `Alias for specifier "${specifierName}"`, - prompt: `Please enter an alias for the specifier "${specifierName}"...`, - validateInput: s => !!s ? '' : 'Please enter a variable name', - }); - return !!result ? result : undefined; - } - - /** - * Calls the vscode input box to ask for an indentifier for a default export. - * - * @private - * @param {string} declarationName - * @returns {Promise} - * - * @memberof ImportManager - */ - private async getDefaultIdentifier(declarationName: string): Promise { - const result = await this.vscodeInputBox({ - placeHolder: 'Default export name', - prompt: 'Please enter an alias name for the default export...', - validateInput: s => !!s ? '' : 'Please enter a variable name', - value: declarationName, - }); - return !!result ? result.replace(/[,.-_]/g, '') : undefined; - } - - /** - * Ultimately asks the user for an input. - * - * @private - * @param {InputBoxOptions} options - * @returns {Promise} - * - * @memberof ImportManager - */ - private async vscodeInputBox(options: InputBoxOptions): Promise { - return await window.showInputBox(options); - } -} diff --git a/src/extension/provider-items/document-structure/BaseStructureTreeItem.ts b/src/extension/provider-items/document-structure/BaseStructureTreeItem.ts deleted file mode 100644 index 1cfdea4..0000000 --- a/src/extension/provider-items/document-structure/BaseStructureTreeItem.ts +++ /dev/null @@ -1,43 +0,0 @@ -import { TreeItem, Command } from 'vscode'; - -/** - * Base class for the document structure (code outline) tree items - * - * @export - * @abstract - * @class BaseStructureTreeItem - * @extends {TreeItem} - */ -export abstract class BaseStructureTreeItem extends TreeItem { - constructor(label: string) { - super(label); - } - - /** - * Returns the children of the current structure tree item (if any) - * - * @returns {BaseStructureTreeItem[]} - * - * @memberof BaseStructureTreeItem - */ - public getChildren(): BaseStructureTreeItem[] { - return []; - } - - /** - * Creates a command with the given arguments. - * - * @protected - * @param {any[]} args - * @returns {Command} - * - * @memberof BaseStructureTreeItem - */ - protected createJumpToCommand(args: any[]): Command { - return { - arguments: args, - title: 'Jump to node', - command: 'typescriptHero.documentCodeOutline.gotoNode', - }; - } -} diff --git a/src/extension/provider-items/document-structure/DeclarationStructureTreeItem.ts b/src/extension/provider-items/document-structure/DeclarationStructureTreeItem.ts deleted file mode 100644 index 96b8cea..0000000 --- a/src/extension/provider-items/document-structure/DeclarationStructureTreeItem.ts +++ /dev/null @@ -1,121 +0,0 @@ -import { - ClassDeclaration, - Declaration, - FunctionDeclaration, - GetterDeclaration, - InterfaceDeclaration, - MethodDeclaration, - PropertyDeclaration, - SetterDeclaration, - VariableDeclaration, -} from 'typescript-parser'; -import { stringTemplate } from 'typescript-parser/utilities/StringTemplate'; -import { CompletionItemKind, ExtensionContext, TreeItemCollapsibleState } from 'vscode'; - -import { getItemKind } from '../../utilities/utilityFunctions'; -import { BaseStructureTreeItem } from './BaseStructureTreeItem'; - -const fileTemplate = stringTemplate`./src/extension/assets/icons/declarations/${0}.svg`; - -/** - * Function to calculate the displayed name of the declaration structure item. - * - * @param {Declaration} declaration - * @returns {string} - */ -function getDeclarationLabel(declaration: Declaration): string { - if ( - declaration instanceof FunctionDeclaration || - declaration instanceof MethodDeclaration - ) { - const params = declaration.parameters.map(p => p.name + (p.type ? `: ${p.type}` : '')).join(', '); - return `${declaration.name}(${params})${declaration.type ? `: ${declaration.type}` : ''}`; - } - - if (declaration instanceof PropertyDeclaration) { - return declaration.name + (declaration.type ? `: ${declaration.type}` : ''); - } - - if ( - declaration instanceof ClassDeclaration || - declaration instanceof InterfaceDeclaration - ) { - return declaration.name + (declaration.typeParameters ? `<${declaration.typeParameters.join(', ')}>` : ''); - } - - if ( - declaration instanceof GetterDeclaration || - declaration instanceof SetterDeclaration - ) { - return `${declaration instanceof GetterDeclaration ? 'get' : 'set'}() ${declaration.name}` + - `${declaration.type ? `: ${declaration.type}` : ''}`; - } - - return declaration.name; -} - -/** - * Structure item that represents a typescript declaration of any way. - * - * @export - * @class DeclarationStructureTreeItem - * @extends {BaseStructureTreeItem} - */ -export class DeclarationStructureTreeItem extends BaseStructureTreeItem { - public get iconPath(): string | undefined { - switch (getItemKind(this.declaration)) { - case CompletionItemKind.Class: - case CompletionItemKind.Keyword: - return this.context.asAbsolutePath(fileTemplate('class')); - case CompletionItemKind.Interface: - return this.context.asAbsolutePath(fileTemplate('interface')); - case CompletionItemKind.Enum: - return this.context.asAbsolutePath(fileTemplate('enum')); - case CompletionItemKind.Function: - case CompletionItemKind.Method: - return this.context.asAbsolutePath(fileTemplate('callable')); - case CompletionItemKind.Module: - return this.context.asAbsolutePath(fileTemplate('module')); - case CompletionItemKind.Property: - return this.context.asAbsolutePath(fileTemplate('property')); - default: - break; - } - - if (getItemKind(this.declaration) === CompletionItemKind.Variable) { - return (this.declaration as VariableDeclaration).isConst ? - this.context.asAbsolutePath(fileTemplate('const')) : - this.context.asAbsolutePath(fileTemplate('variable')); - } - - return this.context.asAbsolutePath(fileTemplate('default')); - } - - constructor(public declaration: Declaration, private context: ExtensionContext) { - super(getDeclarationLabel(declaration)); - - if ( - declaration instanceof ClassDeclaration || - declaration instanceof InterfaceDeclaration - ) { - this.collapsibleState = TreeItemCollapsibleState.Collapsed; - } else { - this.command = this.command = this.createJumpToCommand([declaration]); - } - } - - public getChildren(): BaseStructureTreeItem[] { - if ( - this.declaration instanceof ClassDeclaration || - this.declaration instanceof InterfaceDeclaration - ) { - return [ - ...this.declaration.accessors.map(p => new DeclarationStructureTreeItem(p, this.context)), - ...this.declaration.properties.map(p => new DeclarationStructureTreeItem(p, this.context)), - ...this.declaration.methods.map(m => new DeclarationStructureTreeItem(m, this.context)), - ]; - } - return []; - } -} - diff --git a/src/extension/provider-items/document-structure/DisabledStructureTreeItem.ts b/src/extension/provider-items/document-structure/DisabledStructureTreeItem.ts deleted file mode 100644 index 3ac1b4a..0000000 --- a/src/extension/provider-items/document-structure/DisabledStructureTreeItem.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { BaseStructureTreeItem } from './BaseStructureTreeItem'; - -/** - * Structure tree item that is used when the feature is disabled via config. - * - * @export - * @class DisabledStructureTreeItem - * @extends {BaseStructureTreeItem} - */ -export class DisabledStructureTreeItem extends BaseStructureTreeItem { - constructor() { - super('Feature is disabled.'); - } -} diff --git a/src/extension/provider-items/document-structure/ImportsStructureTreeItem.ts b/src/extension/provider-items/document-structure/ImportsStructureTreeItem.ts deleted file mode 100644 index 7d9ac8b..0000000 --- a/src/extension/provider-items/document-structure/ImportsStructureTreeItem.ts +++ /dev/null @@ -1,83 +0,0 @@ -import { ExternalModuleImport, Import, NamedImport, NamespaceImport, Resource, StringImport } from 'typescript-parser'; -import { ExtensionContext, TreeItemCollapsibleState } from 'vscode'; - -import { BaseStructureTreeItem } from './BaseStructureTreeItem'; - -/** - * Import specifier tree item that represents a specific (named) import of an import statement. - * - * @export - * @class ImportSpecifierStructureTreeItem - * @extends {BaseStructureTreeItem} - */ -export class ImportSpecifierStructureTreeItem extends BaseStructureTreeItem { - constructor(name: string, tsImport: Import, context: ExtensionContext) { - super(name); - this.iconPath = context.asAbsolutePath('./src/extension/assets/icons/declarations/default.svg'); - this.command = this.createJumpToCommand([tsImport]); - } -} - -/** - * Structure item that represents an import in a file. - * - * @export - * @class ImportStructureTreeItem - * @extends {BaseStructureTreeItem} - */ -export class ImportStructureTreeItem extends BaseStructureTreeItem { - constructor(private tsImport: Import, private context: ExtensionContext) { - super(tsImport.libraryName); - this.iconPath = context.asAbsolutePath('./src/extension/assets/icons/declarations/import.svg'); - this.command = this.createJumpToCommand([tsImport]); - - if (!(tsImport instanceof StringImport)) { - this.collapsibleState = TreeItemCollapsibleState.Collapsed; - } - } - - public getChildren(): BaseStructureTreeItem[] { - const imp = this.tsImport; - if (imp instanceof ExternalModuleImport) { - return [new ImportSpecifierStructureTreeItem(imp.alias, imp, this.context)]; - } - if (imp instanceof NamedImport) { - const specifiers = imp.specifiers.map( - s => new ImportSpecifierStructureTreeItem( - `${s.specifier}${s.alias ? ` as ${s.alias}` : ''}`, - imp, - this.context, - ), - ); - if (imp.defaultAlias) { - specifiers.unshift(new ImportSpecifierStructureTreeItem(`(default) ${imp.defaultAlias}`, imp, this.context)); - } - - return specifiers; - } - if (imp instanceof NamespaceImport) { - return [new ImportSpecifierStructureTreeItem(imp.alias, imp, this.context)]; - } - return []; - } -} - -/** - * Structure item that contains all imports from the file. - * Collapsed by default. - * - * @export - * @class ImportsStructureTreeItem - * @extends {BaseStructureTreeItem} - */ -export class ImportsStructureTreeItem extends BaseStructureTreeItem { - constructor(private resource: Resource, private context: ExtensionContext) { - super('Imports'); - this.collapsibleState = TreeItemCollapsibleState.Collapsed; - this.iconPath = context.asAbsolutePath('./src/extension/assets/icons/declarations/module.svg'); - } - - public getChildren(): BaseStructureTreeItem[] { - return this.resource.imports.map(i => new ImportStructureTreeItem(i, this.context)); - } -} diff --git a/src/extension/provider-items/document-structure/NotParseableStructureTreeItem.ts b/src/extension/provider-items/document-structure/NotParseableStructureTreeItem.ts deleted file mode 100644 index 9e96b25..0000000 --- a/src/extension/provider-items/document-structure/NotParseableStructureTreeItem.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { BaseStructureTreeItem } from './BaseStructureTreeItem'; - -/** - * Structure tree item that is used when a document is not parseable (i.e. not typescript) - * - * @export - * @class NotParseableStructureTreeItem - * @extends {BaseStructureTreeItem} - */ -export class NotParseableStructureTreeItem extends BaseStructureTreeItem { - constructor() { - super('File not parseable.'); - } -} diff --git a/src/extension/provider-items/document-structure/ResourceStructureTreeItem.ts b/src/extension/provider-items/document-structure/ResourceStructureTreeItem.ts deleted file mode 100644 index 7ce6b90..0000000 --- a/src/extension/provider-items/document-structure/ResourceStructureTreeItem.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { Resource } from 'typescript-parser'; -import { ExtensionContext, TreeItemCollapsibleState } from 'vscode'; - -import { BaseStructureTreeItem } from './BaseStructureTreeItem'; -import { DeclarationStructureTreeItem } from './DeclarationStructureTreeItem'; -import { ImportsStructureTreeItem } from './ImportsStructureTreeItem'; - -/** - * Structure item that represents an additional resource in a file (namespace etc). - * - * @export - * @class ResourceStructureTreeItem - * @extends {BaseStructureTreeItem} - */ -export class ResourceStructureTreeItem extends BaseStructureTreeItem { - constructor(public resource: Resource, private context: ExtensionContext) { - super(resource.identifier); - this.collapsibleState = TreeItemCollapsibleState.Collapsed; - this.iconPath = this.context.asAbsolutePath('./src/extension/assets/icons/declarations/module.svg'); - } - - public getChildren(): BaseStructureTreeItem[] { - const items: BaseStructureTreeItem[] = []; - if (this.resource.imports && this.resource.imports.length) { - items.push(new ImportsStructureTreeItem(this.resource, this.context)); - } - items.push(...this.resource.resources.map(r => new ResourceStructureTreeItem(r, this.context))); - items.push(...this.resource.declarations.map(d => new DeclarationStructureTreeItem(d, this.context))); - return items; - } -} diff --git a/src/extension/utilities/utilityFunctions.ts b/src/extension/utilities/utilityFunctions.ts deleted file mode 100644 index 90597d2..0000000 --- a/src/extension/utilities/utilityFunctions.ts +++ /dev/null @@ -1,231 +0,0 @@ -import { basename, parse } from 'path'; -import { ScriptKind } from 'typescript'; -import { - ClassDeclaration, - ConstructorDeclaration, - Declaration, - DefaultDeclaration, - EnumDeclaration, - ExternalModuleImport, - FunctionDeclaration, - GetterDeclaration, - Import, - InterfaceDeclaration, - MethodDeclaration, - ModuleDeclaration, - NamedImport, - NamespaceImport, - ParameterDeclaration, - PropertyDeclaration, - SetterDeclaration, - StringImport, - SymbolSpecifier, - TypeAliasDeclaration, - VariableDeclaration, -} from 'typescript-parser'; -import { CompletionItemKind } from 'vscode'; - -import { ImportGroup, RegexImportGroup } from '../import-grouping'; - -/** - * String-Sort function. - * - * @export - * @param {string} strA - * @param {string} strB - * @param {('asc' | 'desc')} [order='asc'] - * @returns {number} - */ -export function stringSort(strA: string, strB: string, order: 'asc' | 'desc' = 'asc'): number { - let result: number = 0; - if (strA < strB) { - result = -1; - } else if (strA > strB) { - result = 1; - } - if (order === 'desc') { - result *= -1; - } - return result; -} - -/** - * Orders import groups by matching precedence (regex first). This is used internally by - * `ImportManager` when assigning imports to groups, so regex groups can appear later than - * keyword groups yet capture relevant imports nonetheless. - * - * @export - * @param {ImportGroup[]} importGroups The original import groups (as per extension configuration) - * @returns {ImportGroup[]} The same list, with Regex import groups appearing first. - */ -export function importGroupSortForPrecedence(importGroups: ImportGroup[]): ImportGroup[] { - const regexGroups: ImportGroup[] = []; - const otherGroups: ImportGroup[] = []; - for (const ig of importGroups) { - (ig instanceof RegexImportGroup ? regexGroups : otherGroups).push(ig); - } - return regexGroups.concat(otherGroups); -} - -/** - * Locale-sensitive ("Human-compatible") String-Sort function. - * - * @param {string} strA - * @param {string} strB - * @param {('asc' | 'desc')} [order='asc'] - * @returns {number} - */ -function localeStringSort(strA: string, strB: string, order: 'asc' | 'desc' = 'asc'): number { - let result: number = strA.localeCompare(strB); - if (order === 'desc') { - result *= -1; - } - return result; -} - -/** - * Order imports by library name. - * - * @export - * @param {Import} i1 - * @param {Import} i2 - * @param {('asc' | 'desc')} [order='asc'] - * @returns {number} - */ -export function importSort(i1: Import, i2: Import, order: 'asc' | 'desc' = 'asc'): number { - const strA = i1.libraryName.toLowerCase(); - const strB = i2.libraryName.toLowerCase(); - - return stringSort(strA, strB, order); -} - -/** - * Order imports by first specifier name. Does not re-sort specifiers internally: - * assumes they were sorted AOT (which happens in `ImportManager#organizeImports`, - * indeed). - * - * @export - * @param {Import} i1 - * @param {Import} i2 - * @param {('asc' | 'desc')} [order='asc'] - * @returns {number} - */ -export function importSortByFirstSpecifier(i1: Import, i2: Import, order: 'asc' | 'desc' = 'asc'): number { - const strA = getImportFirstSpecifier(i1); - const strB = getImportFirstSpecifier(i2); - - return localeStringSort(strA, strB, order); -} - -/** - * Computes the first specifier/alias of an import, falling back ot its - * module path (for StringImports, basically). Does not re-sort specifiers - * internally: assumes they were sorted AOT (which happens in - * `ImportManager#organizeImports`, indeed). - * - * @param {Import} imp - * @returns {String} - */ -function getImportFirstSpecifier(imp: Import): string { - if (imp instanceof NamespaceImport || imp instanceof ExternalModuleImport) { - return imp.alias; - } - - if (imp instanceof StringImport) { - return basename(imp.libraryName); - } - - if (imp instanceof NamedImport) { - const namedSpecifiers = (imp as NamedImport).specifiers - .map(s => s.alias || s.specifier) - .filter(Boolean); - const marker = namedSpecifiers[0] || imp.defaultAlias; - if (marker) { - return marker; - } - } - - return basename(imp.libraryName); -} - -/** - * Order specifiers by name. - * - * @export - * @param {SymbolSpecifier} i1 - * @param {SymbolSpecifier} i2 - * @returns {number} - */ -export function specifierSort(i1: SymbolSpecifier, i2: SymbolSpecifier): number { - return stringSort(i1.specifier, i2.specifier); -} - -/** - * Returns the item kind for a given declaration. - * - * @export - * @param {Declaration} declaration - * @returns {CompletionItemKind} - */ -export function getItemKind(declaration: Declaration): CompletionItemKind { - switch (true) { - case declaration instanceof ClassDeclaration: - return CompletionItemKind.Class; - case declaration instanceof ConstructorDeclaration: - return CompletionItemKind.Constructor; - case declaration instanceof DefaultDeclaration: - return CompletionItemKind.File; - case declaration instanceof EnumDeclaration: - return CompletionItemKind.Enum; - case declaration instanceof FunctionDeclaration: - return CompletionItemKind.Function; - case declaration instanceof InterfaceDeclaration: - return CompletionItemKind.Interface; - case declaration instanceof MethodDeclaration: - return CompletionItemKind.Method; - case declaration instanceof ModuleDeclaration: - return CompletionItemKind.Module; - case declaration instanceof ParameterDeclaration: - return CompletionItemKind.Variable; - case declaration instanceof PropertyDeclaration: - return CompletionItemKind.Property; - case declaration instanceof TypeAliasDeclaration: - return CompletionItemKind.TypeParameter; - case declaration instanceof VariableDeclaration: - const variable = declaration as VariableDeclaration; - return variable.isConst ? - CompletionItemKind.Constant : - CompletionItemKind.Variable; - case declaration instanceof GetterDeclaration: - case declaration instanceof SetterDeclaration: - return CompletionItemKind.Method; - default: - return CompletionItemKind.Reference; - } -} - -/** - * Calculates the scriptkind for the typescript parser based on filepath. - * - * @export - * @param {string} filePath - * @returns {ScriptKind} - */ -export function getScriptKind(filePath: string | undefined): ScriptKind { - if (!filePath) { - return ScriptKind.TS; - } - const parsed = parse(filePath); - switch (parsed.ext) { - case '.ts': - return ScriptKind.TS; - case '.tsx': - return ScriptKind.TSX; - case '.js': - return ScriptKind.JS; - case '.jsx': - return ScriptKind.JSX; - default: - return ScriptKind.Unknown; - } -} diff --git a/src/extension/utilities/winstonLogger.ts b/src/extension/utilities/winstonLogger.ts deleted file mode 100644 index e9c292d..0000000 --- a/src/extension/utilities/winstonLogger.ts +++ /dev/null @@ -1,150 +0,0 @@ -import { ExtensionContext, OutputChannel, window } from 'vscode'; - -const { createLogger, exceptions, format, transports } = require('winston'); -const transport = require('winston-transport'); -const { LEVEL, MESSAGE } = require('triple-beam'); - -const { combine, timestamp, printf } = format; -const Transport = transport as { new(...args: any[]): any; }; - -const levels = { - error: 0, - warn: 1, - info: 2, - debug: 3, -}; - -class OutputWindowTransport extends Transport { - constructor(opts: any, private channel: OutputChannel) { - super(opts); - } - - public log(info: any, callback: any): void { - setImmediate(() => { - this.emit('logged', info); - }); - this.channel.appendLine(info[MESSAGE]); - callback(); - } -} - -class ConsoleLogTransport extends Transport { - constructor(opts?: any) { - super(opts); - } - - public log(info: any, callback: any): void { - setImmediate(() => { - this.emit('logged', info); - }); - const level = info[LEVEL]; - - switch (level) { - case 'error': - console.error(info[MESSAGE]); - break; - case 'warn': - console.warn(info[MESSAGE]); - break; - default: - console.log(info[MESSAGE]); - break; - } - callback(); - } -} - -// class HandleUncatchedException extends Transport { -// constructor(private path: string) { -// super(); -// } - -// public async log(info: any, callback: any): Promise { -// setImmediate(() => { -// this.emit('logged', info); -// }); - -// const result = await window.showErrorMessage( -// 'There was an uncaught exception, do you want to see the logfile?', -// { modal: true }, -// 'Yes, show me.', -// ); - -// if (result) { -// const doc = await workspace.openTextDocument(join(this.path, 'typescript-hero.log')); -// await window.showTextDocument(doc); -// } - -// callback(); -// } -// } - -export interface Logger { - error: (message: string, ...data: any[]) => void; - warn: (message: string, ...data: any[]) => void; - info: (message: string, ...data: any[]) => void; - debug: (message: string, ...data: any[]) => void; - profile: (name: string) => void; - startTimer(): { done: (info: { message: string }) => void; }; -} - -const loggerTransports = [ - new ConsoleLogTransport({ - level: !!process.env.CI ? 'error' : 'debug', - }), -]; - -export default function winstonLogger(verbosity: keyof typeof levels, context: ExtensionContext): Logger { - const level = !!process.env.CI ? 'error' : verbosity; - - if (!process.env.CI && !process.env.EXT_DEBUG) { - const channel = window.createOutputChannel('TypeScript Hero'); - context.subscriptions.push(channel); - - const fileHandler = new transports.File({ - level: ['info', 'debug'].indexOf(level) >= 0 ? level : 'info', - exitOnError: false, - filename: 'typescript-hero.log', - dirname: context.extensionPath, - maxsize: 1024 * 1024, - maxFiles: 1, - tailable: true, - }); - const outputHandler = new OutputWindowTransport({ exitOnError: false }, channel); - - loggerTransports.push(fileHandler); - loggerTransports.push(outputHandler); - - exceptions.handle(fileHandler); - // exceptions.handle(outputHandler); - // exceptions.handle(new HandleUncatchedException(context.extensionPath)); - } - - const logger = createLogger({ - level, - levels, - format: combine( - format.splat(), - timestamp(), - printf((info) => { - const message = `${info.timestamp} - ${info.level}: ${info.message}`; - const data = { - ...info, - level: undefined, - message: undefined, - splat: undefined, - timestamp: undefined, - }; - if (Object.keys(data).filter(key => !!data[key]).length > 0) { - return `${message} ${JSON.stringify(data)}`; - } - return message; - }), - ), - transports: loggerTransports, - }); - - logger.exitOnError = false; - - return logger; -} diff --git a/src/import-organizer/import-grouping/ImportGroup.ts b/src/import-organizer/import-grouping/ImportGroup.ts new file mode 100644 index 0000000..afd9b6b --- /dev/null +++ b/src/import-organizer/import-grouping/ImportGroup.ts @@ -0,0 +1,56 @@ +import { Import } from 'typescript-parser'; + +import { ImportGroupOrder } from './ImportGroupOrder'; + +/** + * Interface for an import group. A group contains a list of imports that are grouped and sorted + * together on organizing all imports and inserting new imports. + * + * @export + * @interface ImportGroup + * @extends {Generatable} + */ +export interface ImportGroup { + /** + * The readonly list of imports for this group. + * + * @type {Import[]} + * @memberof ImportGroup + */ + readonly imports: Import[]; + + /** + * A sorted list of the imports of this group. + * + * @type {Import[]} + * @memberof ImportGroup + */ + readonly sortedImports: Import[]; + + /** + * The order of the imports (asc / desc). + * + * @type {ImportGroupOrder} + * @memberof ImportGroup + */ + order: ImportGroupOrder; + + /** + * Adds the given import to itself if it is the correct group for the import. Does return true if the import is + * handled, otherwise it must return false. + * + * @param {Import} tsImport + * @returns {boolean} + * + * @memberof ImportGroup + */ + processImport(tsImport: Import): boolean; + + /** + * Resets the import group (clears the imports). + * + * + * @memberof ImportGroup + */ + reset(): void; +} diff --git a/src/extension/import-grouping/ImportGroupIdentifierInvalidError.ts b/src/import-organizer/import-grouping/ImportGroupIdentifierInvalidError.ts similarity index 57% rename from src/extension/import-grouping/ImportGroupIdentifierInvalidError.ts rename to src/import-organizer/import-grouping/ImportGroupIdentifierInvalidError.ts index 1173671..0cbf4ef 100644 --- a/src/extension/import-grouping/ImportGroupIdentifierInvalidError.ts +++ b/src/import-organizer/import-grouping/ImportGroupIdentifierInvalidError.ts @@ -1,13 +1,13 @@ /** * Thrown when a import group identifier neither does match a keyword nor a regex pattern. - * + * * @export * @class ImportGroupIdentifierInvalidError * @extends {Error} */ export class ImportGroupIdentifierInvalidError extends Error { - constructor(identifier: string) { - super(); - this.message = `The identifier "${identifier}" does not match a keyword or a regex pattern (/ .. /).`; - } + constructor(identifier: string) { + super(); + this.message = `The identifier "${identifier}" does not match a keyword or a regex pattern (/ .. /).`; + } } diff --git a/src/extension/import-grouping/ImportGroupKeyword.ts b/src/import-organizer/import-grouping/ImportGroupKeyword.ts similarity index 70% rename from src/extension/import-grouping/ImportGroupKeyword.ts rename to src/import-organizer/import-grouping/ImportGroupKeyword.ts index 23ea620..02d79c6 100644 --- a/src/extension/import-grouping/ImportGroupKeyword.ts +++ b/src/import-organizer/import-grouping/ImportGroupKeyword.ts @@ -1,12 +1,12 @@ /** * Enum for the different special keywords of the KeywordImportGroup. - * + * * @export * @enum {number} */ export enum ImportGroupKeyword { - Modules, - Plains, - Workspace, - Remaining, + Modules, + Plains, + Workspace, + Remaining, } diff --git a/src/extension/import-grouping/ImportGroupOrder.ts b/src/import-organizer/import-grouping/ImportGroupOrder.ts similarity index 100% rename from src/extension/import-grouping/ImportGroupOrder.ts rename to src/import-organizer/import-grouping/ImportGroupOrder.ts diff --git a/src/import-organizer/import-grouping/ImportGroupSettingParser.ts b/src/import-organizer/import-grouping/ImportGroupSettingParser.ts new file mode 100644 index 0000000..5ed4b5d --- /dev/null +++ b/src/import-organizer/import-grouping/ImportGroupSettingParser.ts @@ -0,0 +1,80 @@ +import { ImportGroup } from './ImportGroup'; +import { ImportGroupIdentifierInvalidError } from './ImportGroupIdentifierInvalidError'; +import { ImportGroupKeyword } from './ImportGroupKeyword'; +import { ImportGroupOrder } from './ImportGroupOrder'; +import { KeywordImportGroup } from './KeywordImportGroup'; +import { RegexImportGroup } from './RegexImportGroup'; +import { RemainImportGroup } from './RemainImportGroup'; + +/** + * Inserted setting that is contained in the settings.json of .vscode. + */ +export type ImportGroupSetting = string | { identifier: string, order: ImportGroupOrder }; + +const REGEX_REGEX_GROUP = /^\/.+\/$/; + +/** + * Parser that takes the vscode - setting and creates import groups out of it. + * Contains a default if the parsing fails. + * + * @export + * @class ImportGroupSettingParser + */ +export class ImportGroupSettingParser { + /** + * Default value for the import groups. + * Contains the following: + * - Plain imports + * - Module imports + * - Workspace imports + * + * @readonly + * @static + * @type {ImportGroup[]} + * @memberof ImportGroupSettingParser + */ + public static get default(): ImportGroup[] { + return [ + new KeywordImportGroup(ImportGroupKeyword.Plains), + new KeywordImportGroup(ImportGroupKeyword.Modules), + new KeywordImportGroup(ImportGroupKeyword.Workspace), + new RemainImportGroup(), + ]; + } + + /** + * Function that takes a string or object ({@link ImportGroupSetting}) and parses an import group out of it. + * + * @static + * @param {ImportGroupSetting} setting + * @returns {ImportGroup} + * @throws {ImportGroupIdentifierInvalidError} When the identifier is invalid (neither keyword nor valid regex) + * + * @memberof ImportGroupSettingParser + */ + public static parseSetting(setting: ImportGroupSetting): ImportGroup { + let identifier: string; + let order: ImportGroupOrder = 'asc'; + + if (typeof setting === 'string') { + identifier = setting; + } else { + identifier = setting.identifier; + order = setting.order; + } + + if (REGEX_REGEX_GROUP.test(identifier)) { + return new RegexImportGroup(identifier, order); + } + + if (ImportGroupKeyword[identifier] === ImportGroupKeyword.Remaining) { + return new RemainImportGroup(order); + } + + if (ImportGroupKeyword[identifier] !== undefined) { + return new KeywordImportGroup(ImportGroupKeyword[identifier], order); + } + + throw new ImportGroupIdentifierInvalidError(identifier); + } +} diff --git a/src/import-organizer/import-grouping/KeywordImportGroup.ts b/src/import-organizer/import-grouping/KeywordImportGroup.ts new file mode 100644 index 0000000..a575c36 --- /dev/null +++ b/src/import-organizer/import-grouping/KeywordImportGroup.ts @@ -0,0 +1,104 @@ +import { Import, StringImport } from 'typescript-parser'; + +import { importSort } from '../../utilities/utility-functions'; +import { ImportGroup } from './ImportGroup'; +import { ImportGroupKeyword } from './ImportGroupKeyword'; +import { ImportGroupOrder } from './ImportGroupOrder'; + +/** + * Importgroup for keywords. Uses "Modules", "Plains", "Workspace" as a keyword and processes the corresponding imports. + * + * @export + * @class KeywordImportGroup + * @implements {ImportGroup} + */ +export class KeywordImportGroup implements ImportGroup { + public readonly imports: Import[] = []; + + public get sortedImports(): Import[] { + return this.imports.sort((i1, i2) => importSort(i1, i2, this.order)); + } + + constructor(public readonly keyword: ImportGroupKeyword, public readonly order: ImportGroupOrder = 'asc') { } + + public reset(): void { + this.imports.length = 0; + } + + public processImport(tsImport: Import): boolean { + switch (this.keyword) { + case ImportGroupKeyword.Modules: + return this.processModulesImport(tsImport); + case ImportGroupKeyword.Plains: + return this.processPlainsImport(tsImport); + case ImportGroupKeyword.Workspace: + return this.processWorkspaceImport(tsImport); + default: + return false; + } + } + + /** + * Process a library import. + * @example import ... from 'vscode'; + * + * @private + * @param {Import} tsImport + * @returns {boolean} + * + * @memberof KeywordImportGroup + */ + private processModulesImport(tsImport: Import): boolean { + if ( + tsImport instanceof StringImport || + tsImport.libraryName.startsWith('.') || + tsImport.libraryName.startsWith('/') + ) { + return false; + } + this.imports.push(tsImport); + return true; + } + + /** + * Process a string only import. + * @example import 'reflect-metadata'; + * + * @private + * @param {Import} tsImport + * @returns {boolean} + * + * @memberof KeywordImportGroup + */ + private processPlainsImport(tsImport: Import): boolean { + if (!(tsImport instanceof StringImport)) { + return false; + } + this.imports.push(tsImport); + return true; + } + + /** + * Process a workspace import (not string nor lib import). + * @example import ... from './server'; + * + * @private + * @param {Import} tsImport + * @returns {boolean} + * + * @memberof KeywordImportGroup + */ + private processWorkspaceImport(tsImport: Import): boolean { + if ( + tsImport instanceof StringImport || + ( + !tsImport.libraryName.startsWith('.') && + !tsImport.libraryName.startsWith('/') + ) + ) { + return false; + } + this.imports.push(tsImport); + return true; + } +} diff --git a/src/import-organizer/import-grouping/RegexImportGroup.ts b/src/import-organizer/import-grouping/RegexImportGroup.ts new file mode 100644 index 0000000..e4314e3 --- /dev/null +++ b/src/import-organizer/import-grouping/RegexImportGroup.ts @@ -0,0 +1,51 @@ +import { Import, StringImport } from 'typescript-parser'; + +import { importSort } from '../../utilities/utility-functions'; +import { ImportGroup } from './ImportGroup'; +import { ImportGroupOrder } from './ImportGroupOrder'; + +/** + * Importgroup that processes all imports that match a certain regex (the lib name). + * + * @export + * @class RegexImportGroup + * @implements {ImportGroup} + */ +export class RegexImportGroup implements ImportGroup { + public readonly imports: Import[] = []; + + public get sortedImports(): Import[] { + const sorted = this.imports.sort((i1, i2) => importSort(i1, i2, this.order)); + return [ + ...sorted.filter(i => i instanceof StringImport), + ...sorted.filter(i => !(i instanceof StringImport)), + ]; + } + + /** + * Creates an instance of RegexImportGroup. + * + * @param {string} regex The regex that is matched against the imports library name. + * @param {ImportGroupOrder} [order='asc'] + * + * @memberof RegexImportGroup + */ + constructor(public readonly regex: string, public readonly order: ImportGroupOrder = 'asc') { } + + public reset(): void { + this.imports.length = 0; + } + + public processImport(tsImport: Import): boolean { + let regexString = this.regex; + regexString = regexString.startsWith('/') ? regexString.substring(1) : regexString; + regexString = regexString.endsWith('/') ? regexString.substring(0, regexString.length - 1) : regexString; + const regex = new RegExp(regexString, 'g'); + + if (regex.test(tsImport.libraryName)) { + this.imports.push(tsImport); + return true; + } + return false; + } +} diff --git a/src/import-organizer/import-grouping/RemainImportGroup.ts b/src/import-organizer/import-grouping/RemainImportGroup.ts new file mode 100644 index 0000000..3c3fc85 --- /dev/null +++ b/src/import-organizer/import-grouping/RemainImportGroup.ts @@ -0,0 +1,35 @@ +import { Import, StringImport } from 'typescript-parser'; + +import { importSort } from '../../utilities/utility-functions'; +import { ImportGroup } from './ImportGroup'; +import { ImportGroupOrder } from './ImportGroupOrder'; + +/** + * Importgroup that processes all imports. Should be used if other groups don't process the import. + * + * @export + * @class RemainImportGroup + * @implements {ImportGroup} + */ +export class RemainImportGroup implements ImportGroup { + public readonly imports: Import[] = []; + + public get sortedImports(): Import[] { + const sorted = this.imports.sort((i1, i2) => importSort(i1, i2, this.order)); + return [ + ...sorted.filter(i => i instanceof StringImport), + ...sorted.filter(i => !(i instanceof StringImport)), + ]; + } + + constructor(public readonly order: ImportGroupOrder = 'asc') { } + + public reset(): void { + this.imports.length = 0; + } + + public processImport(tsImport: Import): boolean { + this.imports.push(tsImport); + return true; + } +} diff --git a/src/extension/import-grouping/index.ts b/src/import-organizer/import-grouping/index.ts similarity index 100% rename from src/extension/import-grouping/index.ts rename to src/import-organizer/import-grouping/index.ts diff --git a/src/import-organizer/import-manager.ts b/src/import-organizer/import-manager.ts new file mode 100644 index 0000000..8bcaa07 --- /dev/null +++ b/src/import-organizer/import-manager.ts @@ -0,0 +1,317 @@ +import { + ExternalModuleImport, + File, + Import, + NamedImport, + NamespaceImport, + StringImport, + SymbolSpecifier, + TypescriptCodeGenerator, + TypescriptParser, +} from 'typescript-parser'; +import { Position, Range, TextDocument, TextEdit, window, workspace, WorkspaceEdit } from 'vscode'; + +import Configuration from '../configuration/index'; +import { TypescriptCodeGeneratorFactory } from '../ioc-symbols'; +import { Logger } from '../utilities/logger'; +import { + getImportInsertPosition, + getScriptKind, + importGroupSortForPrecedence, + importSort, + importSortByFirstSpecifier, + specifierSort, +} from '../utilities/utility-functions'; +import { ImportGroup } from './import-grouping'; + +function sameSpecifiers(specs1: SymbolSpecifier[], specs2: SymbolSpecifier[]): boolean { + for (const spec of specs1) { + const spec2 = specs2[specs1.indexOf(spec)]; + if (!spec2 || + spec.specifier !== spec2.specifier || + spec.alias !== spec2.alias) { + return false; + } + } + return true; +} + +/** + * Function that calculates the range object for an import. + * + * @export + * @param {TextDocument} document + * @param {number} [start] + * @param {number} [end] + * @returns {Range} + */ +export function importRange(document: TextDocument, start?: number, end?: number): Range { + return start !== undefined && end !== undefined ? + new Range( + document.lineAt(document.positionAt(start).line).rangeIncludingLineBreak.start, + document.lineAt(document.positionAt(end).line).rangeIncludingLineBreak.end, + ) : + new Range(new Position(0, 0), new Position(0, 0)); +} + +/** + * Management class for the imports of a document. Can add and remove imports to the document + * and commit the virtual document to the TextEditor. + * + * @export + * @class ImportManager + */ +export default class ImportManager { + private importGroups: ImportGroup[]; + private imports: Import[] = []; + private organize: boolean; + + private get rootPath(): string | undefined { + const rootFolder = workspace.getWorkspaceFolder(this.document.uri); + return rootFolder ? rootFolder.uri.fsPath : undefined; + } + + private get generator(): TypescriptCodeGenerator { + return this.generatorFactory(this.document.uri); + } + + /** + * Document resource for this controller. Contains the parsed document. + * + * @readonly + * @type {File} + * @memberof ImportManager + */ + public get parsedDocument(): File { + return this._parsedDocument; + } + + public constructor( + public readonly document: TextDocument, + private _parsedDocument: File, + private readonly parser: TypescriptParser, + private readonly config: Configuration, + private readonly logger: Logger, + private readonly generatorFactory: TypescriptCodeGeneratorFactory, + ) { + this.logger.debug( + `[ImportManager] create import manager`, + { file: document.fileName }, + ); + this.reset(); + } + + /** + * Resets the imports and the import groups back to the initial state of the parsed document. + * + * @memberof ImportManager + */ + public reset(): void { + this.imports = this._parsedDocument.imports.map(o => o.clone()); + this.importGroups = this.config.imports.grouping(this.document.uri); + this.addImportsToGroups(this.imports); + } + + /** + * Organizes the imports of the document. Orders all imports and removes unused imports. + * Order: + * 1. string-only imports (e.g. import 'reflect-metadata') + * 2. rest, but in alphabetical order + * + * @returns {ImportManager} + * + * @memberof ImportManager + */ + public organizeImports(): this { + this.logger.debug( + '[ImportManager] organize the imports', + { file: this.document.fileName }, + ); + this.organize = true; + let keep: Import[] = []; + + if (this.config.imports.disableImportRemovalOnOrganize(this.document.uri)) { + keep = this.imports; + } else { + for (const actImport of this.imports) { + if (this.config.imports.ignoredFromRemoval(this.document.uri).indexOf(actImport.libraryName) >= 0) { + keep.push(actImport); + continue; + } + if (actImport instanceof NamespaceImport || + actImport instanceof ExternalModuleImport) { + if (this._parsedDocument.nonLocalUsages.indexOf(actImport.alias) > -1) { + keep.push(actImport); + } + } else if (actImport instanceof NamedImport) { + actImport.specifiers = actImport.specifiers + .filter(o => this._parsedDocument.nonLocalUsages.indexOf(o.alias || o.specifier) > -1) + .sort(specifierSort); + const defaultSpec = actImport.defaultAlias; + if (actImport.specifiers.length || + (!!defaultSpec && this._parsedDocument.nonLocalUsages.indexOf(defaultSpec) >= 0)) { + keep.push(actImport); + } + } else if (actImport instanceof StringImport) { + keep.push(actImport); + } + } + } + + if (!this.config.imports.disableImportsSorting(this.document.uri)) { + const sorter = this.config.imports.organizeSortsByFirstSpecifier(this.document.uri) + ? importSortByFirstSpecifier + : importSort; + + keep = [ + ...keep.filter(o => o instanceof StringImport).sort(sorter), + ...keep.filter(o => !(o instanceof StringImport)).sort(sorter), + ]; + } + + if (this.config.imports.removeTrailingIndex(this.document.uri)) { + for (const imp of keep.filter(lib => lib.libraryName.endsWith('/index'))) { + imp.libraryName = imp.libraryName.replace(/\/index$/, ''); + } + } + + for (const group of this.importGroups) { + group.reset(); + } + this.imports = keep; + this.addImportsToGroups(this.imports); + + return this; + } + + /** + * Does commit the currently virtual document to the TextEditor. + * Returns a promise that resolves to a boolean if all changes + * could be applied. + * + * @returns {Promise} + * + * @memberof ImportManager + */ + public async commit(): Promise { + const edits: TextEdit[] = this.calculateTextEdits(); + const workspaceEdit = new WorkspaceEdit(); + + workspaceEdit.set(this.document.uri, edits); + + this.logger.debug( + '[ImportManager] commit the file', + { file: this.document.fileName }, + ); + + const result = await workspace.applyEdit(workspaceEdit); + + if (result) { + delete this.organize; + this._parsedDocument = await this.parser.parseSource( + this.document.getText(), + getScriptKind(this.document.fileName), + ); + this.imports = this._parsedDocument.imports.map(o => o.clone()); + for (const group of this.importGroups) { + group.reset(); + } + this.addImportsToGroups(this.imports); + } + + return result; + } + + /** + * Calculate the needed {@link TextEdit} array for the actual changes in the imports. + * + * @returns {TextEdit[]} + * + * @memberof ImportManager + */ + public calculateTextEdits(): TextEdit[] { + const edits: TextEdit[] = []; + + if (this.organize) { + // since the imports should be organized: + // delete all imports and the following lines (if empty) + // newly generate all groups. + for (const imp of this._parsedDocument.imports) { + edits.push(TextEdit.delete(importRange(this.document, imp.start, imp.end))); + if (imp.end !== undefined) { + const nextLine = this.document.lineAt(this.document.positionAt(imp.end).line + 1); + if (nextLine.text === '') { + edits.push(TextEdit.delete(nextLine.rangeIncludingLineBreak)); + } + } + } + const imports = this.importGroups + .map(group => this.generator.generate(group as any)) + .filter(Boolean) + .join('\n'); + if (!!imports) { + edits.push(TextEdit.insert( + getImportInsertPosition(window.activeTextEditor), + `${imports}\n`, + )); + } + } else { + // Commit the documents imports: + // 1. Remove imports that are in the document, but not anymore + // 2. Update existing / insert new ones + for (const imp of this._parsedDocument.imports) { + if (!this.imports.some(o => o.libraryName === imp.libraryName)) { + edits.push(TextEdit.delete(importRange(this.document, imp.start, imp.end))); + } + } + const actualDocumentsNamed = this._parsedDocument.imports.filter(o => o instanceof NamedImport); + for (const imp of this.imports) { + if (imp instanceof NamedImport && + actualDocumentsNamed.some((o: NamedImport) => + o.libraryName === imp.libraryName && + o.defaultAlias === imp.defaultAlias && + o.specifiers.length === imp.specifiers.length && + sameSpecifiers(o.specifiers, imp.specifiers))) { + continue; + } + if (imp.isNew) { + edits.push(TextEdit.insert( + getImportInsertPosition( + window.activeTextEditor, + ), + this.generator.generate(imp) + '\n', + )); + } else { + edits.push(TextEdit.replace( + new Range( + this.document.positionAt(imp.start!), + this.document.positionAt(imp.end!), + ), + this.generator.generate(imp), + )); + } + } + } + + return edits; + } + + /** + * Add a list of imports to the groups of the ImportManager. + * + * @private + * @param {Import[]} imports + * + * @memberof ImportManager + */ + private addImportsToGroups(imports: Import[]): void { + const importGroupsWithPrecedence = importGroupSortForPrecedence(this.importGroups); + for (const tsImport of imports) { + for (const group of importGroupsWithPrecedence) { + if (group.processImport(tsImport)) { + break; + } + } + } + } +} diff --git a/src/import-organizer/index.ts b/src/import-organizer/index.ts new file mode 100644 index 0000000..3eb6c4f --- /dev/null +++ b/src/import-organizer/index.ts @@ -0,0 +1,81 @@ +import { inject, injectable } from 'inversify'; +import { commands, ExtensionContext, window, workspace } from 'vscode'; + +import Activatable from '../activatable'; +import Configuration from '../configuration'; +import iocSymbols, { ImportManagerProvider } from '../ioc-symbols'; +import { Logger } from '../utilities/logger'; + +@injectable() +export default class ImportOrganizer implements Activatable { + constructor( + @inject(iocSymbols.extensionContext) private context: ExtensionContext, + @inject(iocSymbols.logger) private logger: Logger, + @inject(iocSymbols.configuration) private config: Configuration, + @inject(iocSymbols.importManager) private importManagerProvider: ImportManagerProvider, + ) { } + + public setup(): void { + this.logger.debug('Setting up ImportOrganizer.'); + this.context.subscriptions.push( + commands.registerTextEditorCommand('typescriptHero.imports.organize', () => this.organizeImports()), + ); + this.context.subscriptions.push( + workspace.onWillSaveTextDocument((event) => { + if (!this.config.imports.organizeOnSave(event.document.uri)) { + this.logger.debug( + '[ImportOrganizer] organizeOnSave is deactivated through config', + ); + return; + } + if (this.config.parseableLanguages().indexOf(event.document.languageId) < 0) { + this.logger.debug( + '[ImportOrganizer] organizeOnSave not possible for given language', + { language: event.document.languageId }, + ); + return; + } + + this.logger.info( + '[ImportOrganizer] organizeOnSave for file', + { file: event.document.fileName }, + ); + event.waitUntil( + this.importManagerProvider(event.document).then(manager => manager.organizeImports().calculateTextEdits()), + ); + }), + ); + } + + public start(): void { + this.logger.info('Starting up ImportOrganizer.'); + } + + public stop(): void { + this.logger.info('Stopping ImportOrganizer.'); + } + + public dispose(): void { + this.logger.debug('Disposing ImportOrganizer.'); + } + + private async organizeImports(): Promise { + if (!window.activeTextEditor) { + return; + } + try { + this.logger.debug( + '[ImportOrganizer] organize the imports in the document', + { file: window.activeTextEditor.document.fileName }, + ); + const ctrl = await this.importManagerProvider(window.activeTextEditor.document); + await ctrl.organizeImports().commit(); + } catch (e) { + this.logger.error( + '[ImportOrganizer] imports could not be organized, error: %s', + e, + { file: window.activeTextEditor.document.fileName }, + ); + } + } +} diff --git a/src/ioc-symbols.ts b/src/ioc-symbols.ts new file mode 100644 index 0000000..a28c66f --- /dev/null +++ b/src/ioc-symbols.ts @@ -0,0 +1,17 @@ +import { TypescriptCodeGenerator } from 'typescript-parser'; +import { TextDocument, Uri } from 'vscode'; + +import ImportManager from './import-organizer/import-manager'; + +export default { + activatables: Symbol('activatables'), + configuration: Symbol('configuration'), + extensionContext: Symbol('extensionContext'), + generatorFactory: Symbol('generatorFactory'), + importManager: Symbol('importManager'), + logger: Symbol('logger'), + parser: Symbol('parser'), +}; + +export type ImportManagerProvider = (document: TextDocument) => Promise; +export type TypescriptCodeGeneratorFactory = (resource: Uri) => TypescriptCodeGenerator; diff --git a/src/ioc.ts b/src/ioc.ts new file mode 100644 index 0000000..dd5691a --- /dev/null +++ b/src/ioc.ts @@ -0,0 +1,62 @@ +import 'reflect-metadata'; + +import { Container, interfaces } from 'inversify'; +import { TypescriptCodeGenerator, TypescriptParser } from 'typescript-parser'; +import { ExtensionContext, TextDocument, Uri } from 'vscode'; + +import Activatable from './activatable'; +import CodeOutline from './code-outline'; +import Configuration from './configuration'; +import ImportOrganizer from './import-organizer'; +import ImportManager from './import-organizer/import-manager'; +import iocSymbols, { ImportManagerProvider, TypescriptCodeGeneratorFactory } from './ioc-symbols'; +import TypescriptHero from './typescript-hero'; +import winstonLogger, { Logger } from './utilities/logger'; +import { getScriptKind } from './utilities/utility-functions'; + +const ioc = new Container(); + +// Entry point +ioc.bind(TypescriptHero).to(TypescriptHero).inSingletonScope(); + +// Activatables +ioc.bind(iocSymbols.activatables).to(CodeOutline).inSingletonScope(); +ioc.bind(iocSymbols.activatables).to(ImportOrganizer).inSingletonScope(); + +// Configuration +ioc.bind(iocSymbols.configuration).to(Configuration).inSingletonScope(); + +// Logging +ioc + .bind(iocSymbols.logger) + .toDynamicValue((context: interfaces.Context) => { + const extContext = context.container.get(iocSymbols.extensionContext); + const config = context.container.get(iocSymbols.configuration); + return winstonLogger(config.verbosity(), extContext); + }) + .inSingletonScope(); + +// Managers +ioc.bind(iocSymbols.importManager).toProvider( + context => async (document: TextDocument) => { + const parser = context.container.get(iocSymbols.parser); + const config = context.container.get(iocSymbols.configuration); + const logger = context.container.get(iocSymbols.logger); + const generatorFactory = context.container.get(iocSymbols.generatorFactory); + const source = await parser.parseSource(document.getText(), getScriptKind(document.fileName)); + return new ImportManager(document, source, parser, config, logger, generatorFactory); + }, +); + +// Typescript +ioc.bind(iocSymbols.parser).toConstantValue(new TypescriptParser()); +ioc + .bind(iocSymbols.generatorFactory) + .toFactory((context: interfaces.Context) => { + return (resource: Uri) => { + const config = context.container.get(iocSymbols.configuration); + return new TypescriptCodeGenerator(config.typescriptGeneratorOptions(resource)); + }; + }); + +export default ioc; diff --git a/src/typescript-hero.ts b/src/typescript-hero.ts new file mode 100644 index 0000000..b284621 --- /dev/null +++ b/src/typescript-hero.ts @@ -0,0 +1,61 @@ +import { inject, injectable, multiInject } from 'inversify'; +import { Generatable, GENERATORS, TypescriptCodeGenerator, TypescriptGenerationOptions } from 'typescript-parser'; + +import Activatable from './activatable'; +import { KeywordImportGroup, RegexImportGroup, RemainImportGroup } from './import-organizer/import-grouping'; +import iocSymbols from './ioc-symbols'; +import { Logger } from './utilities/logger'; + +@injectable() +export default class TypescriptHero implements Activatable { + constructor( + @inject(iocSymbols.logger) private logger: Logger, + @multiInject(iocSymbols.activatables) private activatables: Activatable[], + ) { } + + public setup(): void { + this.logger.debug('Setting up extension and activatables.'); + this.extendCodeGenerator(); + for (const activatable of this.activatables) { + activatable.setup(); + } + } + + public start(): void { + this.logger.debug('Starting up extension and activatables.'); + for (const activatable of this.activatables) { + activatable.start(); + } + } + + public stop(): void { + this.logger.debug('Stopping extension and activatables.'); + for (const activatable of this.activatables) { + activatable.stop(); + } + } + + public dispose(): void { + this.logger.debug('Disposing extension and activatables.'); + for (const activatable of this.activatables) { + activatable.dispose(); + } + } + + private extendCodeGenerator(): void { + function simpleGenerator(generatable: Generatable, options: TypescriptGenerationOptions): string { + const gen = new TypescriptCodeGenerator(options); + const group = generatable as KeywordImportGroup; + if (!group.imports.length) { + return ''; + } + return group.sortedImports + .map(imp => gen.generate(imp)) + .join('\n') + '\n'; + } + + GENERATORS[KeywordImportGroup.name] = simpleGenerator; + GENERATORS[RegexImportGroup.name] = simpleGenerator; + GENERATORS[RemainImportGroup.name] = simpleGenerator; + } +} diff --git a/src/utilities/logger.ts b/src/utilities/logger.ts new file mode 100644 index 0000000..d05d8fc --- /dev/null +++ b/src/utilities/logger.ts @@ -0,0 +1,125 @@ +import { ExtensionContext, OutputChannel, window } from 'vscode'; + +const { createLogger, exceptions, format, transports } = require('winston'); +const transportClass = require('winston-transport'); +const { LEVEL, MESSAGE } = require('triple-beam'); + +const { combine, timestamp, printf } = format; +const transport = transportClass as { new(...args: any[]): any; }; + +const levels = { + error: 0, + warn: 1, + info: 2, + debug: 3, +}; + +class OutputWindowTransport extends transport { + constructor(opts: any, private channel: OutputChannel) { + super(opts); + } + + public log(info: any, callback: any): void { + setImmediate(() => { + this.emit('logged', info); + }); + this.channel.appendLine(info[MESSAGE]); + callback(); + } +} + +class ConsoleLogTransport extends transport { + constructor(opts?: any) { + super(opts); + } + + public log(info: any, callback: any): void { + setImmediate(() => { + this.emit('logged', info); + }); + const level = info[LEVEL]; + + switch (level) { + case 'error': + console.error(info[MESSAGE]); + break; + case 'warn': + console.warn(info[MESSAGE]); + break; + default: + console.log(info[MESSAGE]); + break; + } + callback(); + } +} + +export interface Logger { + error: (message: string, ...data: any[]) => void; + warn: (message: string, ...data: any[]) => void; + info: (message: string, ...data: any[]) => void; + debug: (message: string, ...data: any[]) => void; + profile: (name: string) => void; + startTimer(): { done: (info: { message: string }) => void; }; +} + +const loggerTransports = [ + new ConsoleLogTransport({ + level: !!process.env.CI ? 'error' : 'debug', + }), +]; + +export default function winstonLogger(verbosity: keyof typeof levels, context: ExtensionContext): Logger { + const level = !!process.env.CI ? 'error' : verbosity; + + if (!process.env.CI && !process.env.EXT_DEBUG) { + const channel = window.createOutputChannel('TypeScript Hero'); + context.subscriptions.push(channel); + + const fileHandler = new transports.File({ + level: ['info', 'debug'].indexOf(level) >= 0 ? level : 'info', + exitOnError: false, + filename: 'typescript-hero.log', + dirname: context.extensionPath, + maxsize: 1024 * 1024, + maxFiles: 1, + tailable: true, + }); + const outputHandler = new OutputWindowTransport({ exitOnError: false }, channel); + + loggerTransports.push(fileHandler); + loggerTransports.push(outputHandler); + + exceptions.handle(fileHandler); + // exceptions.handle(outputHandler); + // exceptions.handle(new HandleUncatchedException(context.extensionPath)); + } + + const logger = createLogger({ + level, + levels, + format: combine( + format.splat(), + timestamp(), + printf((info) => { + const message = `${info.timestamp} - ${info.level}: ${info.message}`; + const data = { + ...info, + level: undefined, + message: undefined, + splat: undefined, + timestamp: undefined, + }; + if (Object.keys(data).filter(key => !!data[key]).length > 0) { + return `${message} ${JSON.stringify(data)}`; + } + return message; + }), + ), + transports: loggerTransports, + }); + + logger.exitOnError = false; + + return logger; +} diff --git a/src/utilities/utility-functions.ts b/src/utilities/utility-functions.ts new file mode 100644 index 0000000..502df54 --- /dev/null +++ b/src/utilities/utility-functions.ts @@ -0,0 +1,340 @@ +import { basename, join, normalize, parse, relative } from 'path'; +import { ScriptKind } from 'typescript'; +import { + ClassDeclaration, + ConstructorDeclaration, + Declaration, + DeclarationInfo, + DefaultDeclaration, + EnumDeclaration, + ExternalModuleImport, + FunctionDeclaration, + GetterDeclaration, + Import, + InterfaceDeclaration, + MethodDeclaration, + ModuleDeclaration, + NamedImport, + NamespaceImport, + ParameterDeclaration, + PropertyDeclaration, + SetterDeclaration, + StringImport, + SymbolSpecifier, + TypeAliasDeclaration, + VariableDeclaration, +} from 'typescript-parser'; +import { toPosix } from 'typescript-parser/utilities/PathHelpers'; +import { CompletionItemKind, Position, TextEditor } from 'vscode'; + +import { ImportGroup, RegexImportGroup } from '../import-organizer/import-grouping'; + +/** + * String-Sort function. + * + * @export + * @param {string} strA + * @param {string} strB + * @param {('asc' | 'desc')} [order='asc'] + * @returns {number} + */ +export function stringSort(strA: string, strB: string, order: 'asc' | 'desc' = 'asc'): number { + let result: number = 0; + if (strA < strB) { + result = -1; + } else if (strA > strB) { + result = 1; + } + if (order === 'desc') { + result *= -1; + } + return result; +} + +/** +* Orders import groups by matching precedence (regex first). This is used internally by +* `ImportManager` when assigning imports to groups, so regex groups can appear later than +* keyword groups yet capture relevant imports nonetheless. +* +* @export +* @param {ImportGroup[]} importGroups The original import groups (as per extension configuration) +* @returns {ImportGroup[]} The same list, with Regex import groups appearing first. +*/ +export function importGroupSortForPrecedence(importGroups: ImportGroup[]): ImportGroup[] { + const regexGroups: ImportGroup[] = []; + const otherGroups: ImportGroup[] = []; + for (const ig of importGroups) { + (ig instanceof RegexImportGroup ? regexGroups : otherGroups).push(ig); + } + return regexGroups.concat(otherGroups); +} + +/** +* Locale-sensitive ("Human-compatible") String-Sort function. +* +* @param {string} strA +* @param {string} strB +* @param {('asc' | 'desc')} [order='asc'] +* @returns {number} +*/ +function localeStringSort(strA: string, strB: string, order: 'asc' | 'desc' = 'asc'): number { + let result: number = strA.localeCompare(strB); + if (order === 'desc') { + result *= -1; + } + return result; +} + +/** +* Order imports by library name. +* +* @export +* @param {Import} i1 +* @param {Import} i2 +* @param {('asc' | 'desc')} [order='asc'] +* @returns {number} +*/ +export function importSort(i1: Import, i2: Import, order: 'asc' | 'desc' = 'asc'): number { + const strA = i1.libraryName.toLowerCase(); + const strB = i2.libraryName.toLowerCase(); + + return stringSort(strA, strB, order); +} + +/** +* Order imports by first specifier name. Does not re-sort specifiers internally: +* assumes they were sorted AOT (which happens in `ImportManager#organizeImports`, +* indeed). +* +* @export +* @param {Import} i1 +* @param {Import} i2 +* @param {('asc' | 'desc')} [order='asc'] +* @returns {number} +*/ +export function importSortByFirstSpecifier(i1: Import, i2: Import, order: 'asc' | 'desc' = 'asc'): number { + const strA = getImportFirstSpecifier(i1); + const strB = getImportFirstSpecifier(i2); + + return localeStringSort(strA, strB, order); +} + +/** +* Computes the first specifier/alias of an import, falling back ot its +* module path (for StringImports, basically). Does not re-sort specifiers +* internally: assumes they were sorted AOT (which happens in +* `ImportManager#organizeImports`, indeed). +* +* @param {Import} imp +* @returns {String} +*/ +function getImportFirstSpecifier(imp: Import): string { + if (imp instanceof NamespaceImport || imp instanceof ExternalModuleImport) { + return imp.alias; + } + + if (imp instanceof StringImport) { + return basename(imp.libraryName); + } + + if (imp instanceof NamedImport) { + const namedSpecifiers = (imp as NamedImport).specifiers + .map(s => s.alias || s.specifier) + .filter(Boolean); + const marker = namedSpecifiers[0] || imp.defaultAlias; + if (marker) { + return marker; + } + } + + return basename(imp.libraryName); +} + +/** +* Order specifiers by name. +* +* @export +* @param {SymbolSpecifier} i1 +* @param {SymbolSpecifier} i2 +* @returns {number} +*/ +export function specifierSort(i1: SymbolSpecifier, i2: SymbolSpecifier): number { + return stringSort(i1.specifier, i2.specifier); +} + +/** + * Returns the item kind for a given declaration. + * + * @export + * @param {Declaration} declaration + * @returns {CompletionItemKind} + */ +export function getItemKind(declaration: Declaration): CompletionItemKind { + switch (true) { + case declaration instanceof ClassDeclaration: + return CompletionItemKind.Class; + case declaration instanceof ConstructorDeclaration: + return CompletionItemKind.Constructor; + case declaration instanceof DefaultDeclaration: + return CompletionItemKind.File; + case declaration instanceof EnumDeclaration: + return CompletionItemKind.Enum; + case declaration instanceof FunctionDeclaration: + return CompletionItemKind.Function; + case declaration instanceof InterfaceDeclaration: + return CompletionItemKind.Interface; + case declaration instanceof MethodDeclaration: + return CompletionItemKind.Method; + case declaration instanceof ModuleDeclaration: + return CompletionItemKind.Module; + case declaration instanceof ParameterDeclaration: + return CompletionItemKind.Variable; + case declaration instanceof PropertyDeclaration: + return CompletionItemKind.Property; + case declaration instanceof TypeAliasDeclaration: + return CompletionItemKind.TypeParameter; + case declaration instanceof VariableDeclaration: + const variable = declaration as VariableDeclaration; + return variable.isConst ? + CompletionItemKind.Constant : + CompletionItemKind.Variable; + case declaration instanceof GetterDeclaration: + case declaration instanceof SetterDeclaration: + return CompletionItemKind.Method; + default: + return CompletionItemKind.Reference; + } +} + +/** + * Calculates the scriptkind for the typescript parser based on filepath. + * + * @export + * @param {string} filePath + * @returns {ScriptKind} + */ +export function getScriptKind(filePath: string | undefined): ScriptKind { + if (!filePath) { + return ScriptKind.TS; + } + const parsed = parse(filePath); + switch (parsed.ext) { + case '.ts': + return ScriptKind.TS; + case '.tsx': + return ScriptKind.TSX; + case '.js': + return ScriptKind.JS; + case '.jsx': + return ScriptKind.JSX; + default: + return ScriptKind.Unknown; + } +} + +/** + * Calculates a list of declarationInfos filtered by the already imported ones in the given document. + * The result is a list of declarations that are not already imported by the document. + * + * @export + * @param {ResolveIndex} resolveIndex + * @param {string} documentPath + * @param {TsImport[]} imports + * @param {string} [rootPath] + * @returns {DeclarationInfo[]} + */ +export function getDeclarationsFilteredByImports( + declarationInfos: DeclarationInfo[], + documentPath: string, + imports: Import[], + rootPath?: string, +): DeclarationInfo[] { + let declarations = declarationInfos; + + for (const tsImport of imports) { + const importedLib = getAbsolutLibraryName(tsImport.libraryName, documentPath, rootPath); + + if (tsImport instanceof NamedImport) { + declarations = declarations.filter( + d => d.from !== importedLib || + !tsImport.specifiers.some(s => s.specifier === d.declaration.name), + ); + if (tsImport.defaultAlias) { + declarations = declarations.filter( + d => !(tsImport.defaultAlias && d.declaration instanceof DefaultDeclaration && d.from === importedLib), + ); + } + } else if (tsImport instanceof NamespaceImport || tsImport instanceof ExternalModuleImport) { + declarations = declarations.filter(o => o.from !== tsImport.libraryName); + } + } + + return declarations; +} + +/** +* Returns the absolut workspace specific library path. +* If the library is a node module or a typings module, the name +* is returned. If the "lib" is in the local workspace, then the +* absolut path from the workspace root is returned. +* +* @param {string} library Name of the library +* @param {string} actualFilePath Filepath of the actually open file +* @param {string} [rootPath] Root path of the workspace +* @returns {string} Absolut path from the workspace root to the desired library +*/ +export function getAbsolutLibraryName(library: string, actualFilePath: string, rootPath?: string): string { + if (!library.startsWith('.') || !rootPath) { + return library; + } + return '/' + toPosix(relative( + rootPath, + normalize(join(parse(actualFilePath).dir, library)), + )).replace(/\/$/, ''); +} + +/** +* Returns the relative path to a specific library. +* If the library is a node module or a typings module, the name +* is returned. If the "lib" is in the local workspace, then the +* relative path from the actual file is returned. +* +* @param {string} library Name of the library +* @param {string} actualFilePath Filepath of the actually open file +* @param {string} [rootPath] Root path of the workspace +* @returns {string} Relative path from the actual file to the library +*/ +export function getRelativeLibraryName(library: string, actualFilePath: string, rootPath?: string): string { + if (!library.startsWith('/') || !rootPath) { + return library; + } + + const actualDir = parse('/' + relative(rootPath, actualFilePath)).dir; + let relativePath = relative(actualDir, library); + + if (!relativePath.startsWith('.')) { + relativePath = './' + relativePath; + } else if (relativePath === '..') { + relativePath += '/'; + } + return toPosix(relativePath); +} + +const REGEX_IGNORED_LINE = /^\s*(?:\/\/|\/\*\*|\*\/|\*|(['"])use strict\1)/; + +/** + * Calculate the position, where a new import should be inserted. + * Does respect the "use strict" string as first line of a document. + * + * @export + * @param {TextEditor | undefined} editor + * @returns {Position} + */ +export function getImportInsertPosition(editor: TextEditor | undefined): Position { + if (!editor) { + return new Position(0, 0); + } + const lines = editor.document.getText().split('\n'); + const index = lines.findIndex(line => !REGEX_IGNORED_LINE.test(line)); + return new Position(Math.max(0, index), 0); +} diff --git a/test/_workspace/.gitignore b/test/_old/_workspace/.gitignore old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/.gitignore rename to test/_old/_workspace/.gitignore diff --git a/test/_workspace/.vscode/settings.json b/test/_old/_workspace/.vscode/settings.json old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/.vscode/settings.json rename to test/_old/_workspace/.vscode/settings.json diff --git a/test/_workspace/build/app.d.ts b/test/_old/_workspace/build/app.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/build/app.d.ts rename to test/_old/_workspace/build/app.d.ts diff --git a/test/_workspace/build/app.js b/test/_old/_workspace/build/app.js old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/build/app.js rename to test/_old/_workspace/build/app.js diff --git a/test/_workspace/common/helpers/importHelperFile.ts b/test/_old/_workspace/common/helpers/importHelperFile.ts similarity index 100% rename from test/_workspace/common/helpers/importHelperFile.ts rename to test/_old/_workspace/common/helpers/importHelperFile.ts diff --git a/test/_workspace/common/ts-parsing/class.ts b/test/_old/_workspace/common/ts-parsing/class.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/class.ts rename to test/_old/_workspace/common/ts-parsing/class.ts diff --git a/test/_workspace/common/ts-parsing/enum.ts b/test/_old/_workspace/common/ts-parsing/enum.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/enum.ts rename to test/_old/_workspace/common/ts-parsing/enum.ts diff --git a/test/_workspace/common/ts-parsing/exportsOnly.ts b/test/_old/_workspace/common/ts-parsing/exportsOnly.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/exportsOnly.ts rename to test/_old/_workspace/common/ts-parsing/exportsOnly.ts diff --git a/test/_workspace/common/ts-parsing/function.ts b/test/_old/_workspace/common/ts-parsing/function.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/function.ts rename to test/_old/_workspace/common/ts-parsing/function.ts diff --git a/test/_workspace/common/ts-parsing/importsOnly.ts b/test/_old/_workspace/common/ts-parsing/importsOnly.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/importsOnly.ts rename to test/_old/_workspace/common/ts-parsing/importsOnly.ts diff --git a/test/_workspace/common/ts-parsing/interface.ts b/test/_old/_workspace/common/ts-parsing/interface.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/interface.ts rename to test/_old/_workspace/common/ts-parsing/interface.ts diff --git a/test/_workspace/common/ts-parsing/module.ts b/test/_old/_workspace/common/ts-parsing/module.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/module.ts rename to test/_old/_workspace/common/ts-parsing/module.ts diff --git a/test/_workspace/common/ts-parsing/typeAlias.ts b/test/_old/_workspace/common/ts-parsing/typeAlias.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/typeAlias.ts rename to test/_old/_workspace/common/ts-parsing/typeAlias.ts diff --git a/test/_workspace/common/ts-parsing/usagesOnly.ts b/test/_old/_workspace/common/ts-parsing/usagesOnly.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/usagesOnly.ts rename to test/_old/_workspace/common/ts-parsing/usagesOnly.ts diff --git a/test/_workspace/common/ts-parsing/variable.ts b/test/_old/_workspace/common/ts-parsing/variable.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/common/ts-parsing/variable.ts rename to test/_old/_workspace/common/ts-parsing/variable.ts diff --git a/test/_workspace/extension/extensions/codeActionExtension/empty.ts b/test/_old/_workspace/extension/extensions/codeActionExtension/empty.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/codeActionExtension/empty.ts rename to test/_old/_workspace/extension/extensions/codeActionExtension/empty.ts diff --git a/test/_workspace/extension/extensions/codeActionExtension/exportedObjects.ts b/test/_old/_workspace/extension/extensions/codeActionExtension/exportedObjects.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/codeActionExtension/exportedObjects.ts rename to test/_old/_workspace/extension/extensions/codeActionExtension/exportedObjects.ts diff --git a/test/_workspace/extension/extensions/codeActionExtension/implementInterfaceOrAbstract.ts b/test/_old/_workspace/extension/extensions/codeActionExtension/implementInterfaceOrAbstract.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/codeActionExtension/implementInterfaceOrAbstract.ts rename to test/_old/_workspace/extension/extensions/codeActionExtension/implementInterfaceOrAbstract.ts diff --git a/test/_workspace/extension/extensions/codeCompletionExtension/codeCompletionFile.ts b/test/_old/_workspace/extension/extensions/codeCompletionExtension/codeCompletionFile.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/codeCompletionExtension/codeCompletionFile.ts rename to test/_old/_workspace/extension/extensions/codeCompletionExtension/codeCompletionFile.ts diff --git a/test/_workspace/extension/extensions/codeCompletionExtension/codeCompletionImports.ts b/test/_old/_workspace/extension/extensions/codeCompletionExtension/codeCompletionImports.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/codeCompletionExtension/codeCompletionImports.ts rename to test/_old/_workspace/extension/extensions/codeCompletionExtension/codeCompletionImports.ts diff --git a/test/_workspace/extension/extensions/documentSymbolStructureExtension/documentSymbolFile.ts b/test/_old/_workspace/extension/extensions/documentSymbolStructureExtension/documentSymbolFile.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/documentSymbolStructureExtension/documentSymbolFile.ts rename to test/_old/_workspace/extension/extensions/documentSymbolStructureExtension/documentSymbolFile.ts diff --git a/test/_workspace/extension/extensions/documentSymbolStructureExtension/notParsable.txt b/test/_old/_workspace/extension/extensions/documentSymbolStructureExtension/notParsable.txt old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/documentSymbolStructureExtension/notParsable.txt rename to test/_old/_workspace/extension/extensions/documentSymbolStructureExtension/notParsable.txt diff --git a/test/_workspace/extension/extensions/importResolveExtension/addImportToDocument.js b/test/_old/_workspace/extension/extensions/importResolveExtension/addImportToDocument.js similarity index 100% rename from test/_workspace/extension/extensions/importResolveExtension/addImportToDocument.js rename to test/_old/_workspace/extension/extensions/importResolveExtension/addImportToDocument.js diff --git a/test/_workspace/extension/extensions/importResolveExtension/addImportToDocument.ts b/test/_old/_workspace/extension/extensions/importResolveExtension/addImportToDocument.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/importResolveExtension/addImportToDocument.ts rename to test/_old/_workspace/extension/extensions/importResolveExtension/addImportToDocument.ts diff --git a/test/_workspace/extension/extensions/importResolveExtension/jsfile.js b/test/_old/_workspace/extension/extensions/importResolveExtension/jsfile.js similarity index 100% rename from test/_workspace/extension/extensions/importResolveExtension/jsfile.js rename to test/_old/_workspace/extension/extensions/importResolveExtension/jsfile.js diff --git a/test/_workspace/extension/extensions/importResolveExtension/jsxfile.jsx b/test/_old/_workspace/extension/extensions/importResolveExtension/jsxfile.jsx similarity index 100% rename from test/_workspace/extension/extensions/importResolveExtension/jsxfile.jsx rename to test/_old/_workspace/extension/extensions/importResolveExtension/jsxfile.jsx diff --git a/test/_workspace/extension/extensions/importResolveExtension/organizeImports.ts b/test/_old/_workspace/extension/extensions/importResolveExtension/organizeImports.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/importResolveExtension/organizeImports.ts rename to test/_old/_workspace/extension/extensions/importResolveExtension/organizeImports.ts diff --git a/test/_workspace/extension/extensions/importResolveExtension/organizeImportsWithExports.ts b/test/_old/_workspace/extension/extensions/importResolveExtension/organizeImportsWithExports.ts similarity index 100% rename from test/_workspace/extension/extensions/importResolveExtension/organizeImportsWithExports.ts rename to test/_old/_workspace/extension/extensions/importResolveExtension/organizeImportsWithExports.ts diff --git a/test/_workspace/extension/extensions/importResolveExtension/sameDirectory.ts b/test/_old/_workspace/extension/extensions/importResolveExtension/sameDirectory.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/importResolveExtension/sameDirectory.ts rename to test/_old/_workspace/extension/extensions/importResolveExtension/sameDirectory.ts diff --git a/test/_workspace/extension/extensions/importResolveExtension/sub1/sub2/sub3/subFile.ts b/test/_old/_workspace/extension/extensions/importResolveExtension/sub1/sub2/sub3/subFile.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/extensions/importResolveExtension/sub1/sub2/sub3/subFile.ts rename to test/_old/_workspace/extension/extensions/importResolveExtension/sub1/sub2/sub3/subFile.ts diff --git a/test/_workspace/extension/extensions/organizeImportsOnSaveExtension/organizeFile.ts b/test/_old/_workspace/extension/extensions/organizeImportsOnSaveExtension/organizeFile.ts similarity index 100% rename from test/_workspace/extension/extensions/organizeImportsOnSaveExtension/organizeFile.ts rename to test/_old/_workspace/extension/extensions/organizeImportsOnSaveExtension/organizeFile.ts diff --git a/test/_workspace/extension/import-grouping/imports.ts b/test/_old/_workspace/extension/import-grouping/imports.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/import-grouping/imports.ts rename to test/_old/_workspace/extension/import-grouping/imports.ts diff --git a/test/_workspace/extension/managers/ClassManagerFile.ts b/test/_old/_workspace/extension/managers/ClassManagerFile.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/managers/ClassManagerFile.ts rename to test/_old/_workspace/extension/managers/ClassManagerFile.ts diff --git a/test/_workspace/extension/managers/ImportManagerFile.ts b/test/_old/_workspace/extension/managers/ImportManagerFile.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/extension/managers/ImportManagerFile.ts rename to test/_old/_workspace/extension/managers/ImportManagerFile.ts diff --git a/test/_workspace/extension/managers/ImportManagerFile.tsx b/test/_old/_workspace/extension/managers/ImportManagerFile.tsx similarity index 100% rename from test/_workspace/extension/managers/ImportManagerFile.tsx rename to test/_old/_workspace/extension/managers/ImportManagerFile.tsx diff --git a/test/_workspace/extension/utilities/importsForSpecifierSort.ts b/test/_old/_workspace/extension/utilities/importsForSpecifierSort.ts similarity index 100% rename from test/_workspace/extension/utilities/importsForSpecifierSort.ts rename to test/_old/_workspace/extension/utilities/importsForSpecifierSort.ts diff --git a/test/_workspace/foobar.ts b/test/_old/_workspace/foobar.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/foobar.ts rename to test/_old/_workspace/foobar.ts diff --git a/test/_workspace/node_modules/@types/node/README.md b/test/_old/_workspace/node_modules/@types/node/README.md old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/@types/node/README.md rename to test/_old/_workspace/node_modules/@types/node/README.md diff --git a/test/_workspace/node_modules/@types/node/index.d.ts b/test/_old/_workspace/node_modules/@types/node/index.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/@types/node/index.d.ts rename to test/_old/_workspace/node_modules/@types/node/index.d.ts diff --git a/test/_workspace/node_modules/@types/node/package.json b/test/_old/_workspace/node_modules/@types/node/package.json old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/@types/node/package.json rename to test/_old/_workspace/node_modules/@types/node/package.json diff --git a/test/_workspace/node_modules/@types/node/types-metadata.json b/test/_old/_workspace/node_modules/@types/node/types-metadata.json old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/@types/node/types-metadata.json rename to test/_old/_workspace/node_modules/@types/node/types-metadata.json diff --git a/test/_workspace/node_modules/fancy-library/FancierLibraryClass.d.ts b/test/_old/_workspace/node_modules/fancy-library/FancierLibraryClass.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/fancy-library/FancierLibraryClass.d.ts rename to test/_old/_workspace/node_modules/fancy-library/FancierLibraryClass.d.ts diff --git a/test/_workspace/node_modules/fancy-library/FancyLibraryClass.d.ts b/test/_old/_workspace/node_modules/fancy-library/FancyLibraryClass.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/fancy-library/FancyLibraryClass.d.ts rename to test/_old/_workspace/node_modules/fancy-library/FancyLibraryClass.d.ts diff --git a/test/_workspace/node_modules/fancy-library/controllers/MyController.d.ts b/test/_old/_workspace/node_modules/fancy-library/controllers/MyController.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/fancy-library/controllers/MyController.d.ts rename to test/_old/_workspace/node_modules/fancy-library/controllers/MyController.d.ts diff --git a/test/_workspace/node_modules/fancy-library/index.d.ts b/test/_old/_workspace/node_modules/fancy-library/index.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/fancy-library/index.d.ts rename to test/_old/_workspace/node_modules/fancy-library/index.d.ts diff --git a/test/_workspace/node_modules/some-lib/dist/SomeDeclaration.d.ts b/test/_old/_workspace/node_modules/some-lib/dist/SomeDeclaration.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/node_modules/some-lib/dist/SomeDeclaration.d.ts rename to test/_old/_workspace/node_modules/some-lib/dist/SomeDeclaration.d.ts diff --git a/test/_workspace/out/out.d.ts b/test/_old/_workspace/out/out.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/out/out.d.ts rename to test/_old/_workspace/out/out.d.ts diff --git a/test/_workspace/out/out.js b/test/_old/_workspace/out/out.js old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/out/out.js rename to test/_old/_workspace/out/out.js diff --git a/test/_workspace/package.json b/test/_old/_workspace/package.json similarity index 100% rename from test/_workspace/package.json rename to test/_old/_workspace/package.json diff --git a/test/_workspace/server/indices/HelperFunctions.ts b/test/_old/_workspace/server/indices/HelperFunctions.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/HelperFunctions.ts rename to test/_old/_workspace/server/indices/HelperFunctions.ts diff --git a/test/_workspace/server/indices/MyClass.ts b/test/_old/_workspace/server/indices/MyClass.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/MyClass.ts rename to test/_old/_workspace/server/indices/MyClass.ts diff --git a/test/_workspace/server/indices/MyReactTemplate.tsx b/test/_old/_workspace/server/indices/MyReactTemplate.tsx old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/MyReactTemplate.tsx rename to test/_old/_workspace/server/indices/MyReactTemplate.tsx diff --git a/test/_workspace/server/indices/NotBarelExported.ts b/test/_old/_workspace/server/indices/NotBarelExported.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/NotBarelExported.ts rename to test/_old/_workspace/server/indices/NotBarelExported.ts diff --git a/test/_workspace/server/indices/SpecialExports.ts b/test/_old/_workspace/server/indices/SpecialExports.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/SpecialExports.ts rename to test/_old/_workspace/server/indices/SpecialExports.ts diff --git a/test/_workspace/server/indices/circularExport/circularExport1.ts b/test/_old/_workspace/server/indices/circularExport/circularExport1.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/circularExport/circularExport1.ts rename to test/_old/_workspace/server/indices/circularExport/circularExport1.ts diff --git a/test/_workspace/server/indices/circularExport/circularExport2.ts b/test/_old/_workspace/server/indices/circularExport/circularExport2.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/circularExport/circularExport2.ts rename to test/_old/_workspace/server/indices/circularExport/circularExport2.ts diff --git a/test/_workspace/server/indices/defaultExport/codefile.ts b/test/_old/_workspace/server/indices/defaultExport/codefile.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/defaultExport/codefile.ts rename to test/_old/_workspace/server/indices/defaultExport/codefile.ts diff --git a/test/_workspace/server/indices/defaultExport/lateDefaultExportedElement.ts b/test/_old/_workspace/server/indices/defaultExport/lateDefaultExportedElement.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/defaultExport/lateDefaultExportedElement.ts rename to test/_old/_workspace/server/indices/defaultExport/lateDefaultExportedElement.ts diff --git a/test/_workspace/server/indices/defaultExport/multiExport.ts b/test/_old/_workspace/server/indices/defaultExport/multiExport.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/defaultExport/multiExport.ts rename to test/_old/_workspace/server/indices/defaultExport/multiExport.ts diff --git a/test/_workspace/server/indices/defaultExport/namelessClass.ts b/test/_old/_workspace/server/indices/defaultExport/namelessClass.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/defaultExport/namelessClass.ts rename to test/_old/_workspace/server/indices/defaultExport/namelessClass.ts diff --git a/test/_workspace/server/indices/defaultExport/namelessFunction.ts b/test/_old/_workspace/server/indices/defaultExport/namelessFunction.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/defaultExport/namelessFunction.ts rename to test/_old/_workspace/server/indices/defaultExport/namelessFunction.ts diff --git a/test/_workspace/server/indices/defaultExport/namelessVariable.ts b/test/_old/_workspace/server/indices/defaultExport/namelessVariable.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/defaultExport/namelessVariable.ts rename to test/_old/_workspace/server/indices/defaultExport/namelessVariable.ts diff --git a/test/_workspace/server/indices/index.ts b/test/_old/_workspace/server/indices/index.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/index.ts rename to test/_old/_workspace/server/indices/index.ts diff --git a/test/_workspace/server/indices/proto.ts b/test/_old/_workspace/server/indices/proto.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/server/indices/proto.ts rename to test/_old/_workspace/server/indices/proto.ts diff --git a/test/_workspace/typings/globals/body-parser/index.d.ts b/test/_old/_workspace/typings/globals/body-parser/index.d.ts old mode 100755 new mode 100644 similarity index 100% rename from test/_workspace/typings/globals/body-parser/index.d.ts rename to test/_old/_workspace/typings/globals/body-parser/index.d.ts diff --git a/test/_workspace_2/file1.ts b/test/_old/_workspace_2/file1.ts similarity index 100% rename from test/_workspace_2/file1.ts rename to test/_old/_workspace_2/file1.ts diff --git a/test/_workspace_2/file2.ts b/test/_old/_workspace_2/file2.ts similarity index 100% rename from test/_workspace_2/file2.ts rename to test/_old/_workspace_2/file2.ts diff --git a/test/multi-root-workspace-tests/MultiRootIndices.test.ts b/test/_old/multi-root-workspace-tests/MultiRootIndices.test.ts similarity index 100% rename from test/multi-root-workspace-tests/MultiRootIndices.test.ts rename to test/_old/multi-root-workspace-tests/MultiRootIndices.test.ts diff --git a/test/multi-root-workspace-tests/index.ts b/test/_old/multi-root-workspace-tests/index.ts similarity index 100% rename from test/multi-root-workspace-tests/index.ts rename to test/_old/multi-root-workspace-tests/index.ts diff --git a/test/multi-root.code-workspace b/test/_old/multi-root.code-workspace similarity index 100% rename from test/multi-root.code-workspace rename to test/_old/multi-root.code-workspace diff --git a/test/single-workspace-tests/common/helpers/DeclarationIndexHelpers.test.ts b/test/_old/single-workspace-tests/common/helpers/DeclarationIndexHelpers.test.ts similarity index 100% rename from test/single-workspace-tests/common/helpers/DeclarationIndexHelpers.test.ts rename to test/_old/single-workspace-tests/common/helpers/DeclarationIndexHelpers.test.ts diff --git a/test/single-workspace-tests/common/helpers/ImportHelpers.test.ts b/test/_old/single-workspace-tests/common/helpers/ImportHelpers.test.ts similarity index 100% rename from test/single-workspace-tests/common/helpers/ImportHelpers.test.ts rename to test/_old/single-workspace-tests/common/helpers/ImportHelpers.test.ts diff --git a/test/single-workspace-tests/extension/extensions/CodeActionExtension.test.ts b/test/_old/single-workspace-tests/extension/extensions/CodeActionExtension.test.ts similarity index 100% rename from test/single-workspace-tests/extension/extensions/CodeActionExtension.test.ts rename to test/_old/single-workspace-tests/extension/extensions/CodeActionExtension.test.ts diff --git a/test/single-workspace-tests/extension/extensions/CodeCompletionExtension.test.ts b/test/_old/single-workspace-tests/extension/extensions/CodeCompletionExtension.test.ts similarity index 100% rename from test/single-workspace-tests/extension/extensions/CodeCompletionExtension.test.ts rename to test/_old/single-workspace-tests/extension/extensions/CodeCompletionExtension.test.ts diff --git a/test/single-workspace-tests/extension/extensions/DocumentSymbolStructureExtension.test.ts b/test/_old/single-workspace-tests/extension/extensions/DocumentSymbolStructureExtension.test.ts similarity index 100% rename from test/single-workspace-tests/extension/extensions/DocumentSymbolStructureExtension.test.ts rename to test/_old/single-workspace-tests/extension/extensions/DocumentSymbolStructureExtension.test.ts diff --git a/test/single-workspace-tests/extension/extensions/ImportResolveExtension.test.ts b/test/_old/single-workspace-tests/extension/extensions/ImportResolveExtension.test.ts similarity index 100% rename from test/single-workspace-tests/extension/extensions/ImportResolveExtension.test.ts rename to test/_old/single-workspace-tests/extension/extensions/ImportResolveExtension.test.ts diff --git a/test/single-workspace-tests/extension/extensions/OrganizeImportsOnSaveExtension.test.ts b/test/_old/single-workspace-tests/extension/extensions/OrganizeImportsOnSaveExtension.test.ts similarity index 100% rename from test/single-workspace-tests/extension/extensions/OrganizeImportsOnSaveExtension.test.ts rename to test/_old/single-workspace-tests/extension/extensions/OrganizeImportsOnSaveExtension.test.ts diff --git a/test/single-workspace-tests/extension/import-grouping/ImportGroupSettingParser.test.ts b/test/_old/single-workspace-tests/extension/import-grouping/ImportGroupSettingParser.test.ts similarity index 100% rename from test/single-workspace-tests/extension/import-grouping/ImportGroupSettingParser.test.ts rename to test/_old/single-workspace-tests/extension/import-grouping/ImportGroupSettingParser.test.ts diff --git a/test/single-workspace-tests/extension/import-grouping/KeywordImportGroup.test.ts b/test/_old/single-workspace-tests/extension/import-grouping/KeywordImportGroup.test.ts similarity index 100% rename from test/single-workspace-tests/extension/import-grouping/KeywordImportGroup.test.ts rename to test/_old/single-workspace-tests/extension/import-grouping/KeywordImportGroup.test.ts diff --git a/test/single-workspace-tests/extension/import-grouping/RegexImportGroup.test.ts b/test/_old/single-workspace-tests/extension/import-grouping/RegexImportGroup.test.ts similarity index 100% rename from test/single-workspace-tests/extension/import-grouping/RegexImportGroup.test.ts rename to test/_old/single-workspace-tests/extension/import-grouping/RegexImportGroup.test.ts diff --git a/test/single-workspace-tests/extension/import-grouping/RemainImportGroup.test.ts b/test/_old/single-workspace-tests/extension/import-grouping/RemainImportGroup.test.ts similarity index 100% rename from test/single-workspace-tests/extension/import-grouping/RemainImportGroup.test.ts rename to test/_old/single-workspace-tests/extension/import-grouping/RemainImportGroup.test.ts diff --git a/test/single-workspace-tests/extension/managers/ClassManager.test.ts b/test/_old/single-workspace-tests/extension/managers/ClassManager.test.ts similarity index 100% rename from test/single-workspace-tests/extension/managers/ClassManager.test.ts rename to test/_old/single-workspace-tests/extension/managers/ClassManager.test.ts diff --git a/test/single-workspace-tests/extension/managers/ImportManager.test.ts b/test/_old/single-workspace-tests/extension/managers/ImportManager.test.ts similarity index 100% rename from test/single-workspace-tests/extension/managers/ImportManager.test.ts rename to test/_old/single-workspace-tests/extension/managers/ImportManager.test.ts diff --git a/test/single-workspace-tests/extension/utilities/utilityFunctions.test.ts b/test/_old/single-workspace-tests/extension/utilities/utilityFunctions.test.ts similarity index 100% rename from test/single-workspace-tests/extension/utilities/utilityFunctions.test.ts rename to test/_old/single-workspace-tests/extension/utilities/utilityFunctions.test.ts diff --git a/test/single-workspace-tests/index.ts b/test/_old/single-workspace-tests/index.ts similarity index 100% rename from test/single-workspace-tests/index.ts rename to test/_old/single-workspace-tests/index.ts diff --git a/test/_workspace/main.ts b/test/_workspace/main.ts new file mode 100644 index 0000000..19995c5 --- /dev/null +++ b/test/_workspace/main.ts @@ -0,0 +1,9 @@ +import ImportOrganizer from './import-organizer'; +import ImportManager from './import-organizer/ImportManager'; +import iocSymbols, { ImportManagerProvider } from './ioc-symbols/index'; +import TypescriptHero from './typescript-hero'; +import winstonLogger, { Logger } from './utilities/Logger'; + +function foo() { + console.log(winstonLogger, Logger, iocSymbols); +} diff --git a/test/demo.spec.ts b/test/demo.spec.ts new file mode 100644 index 0000000..5bc5c85 --- /dev/null +++ b/test/demo.spec.ts @@ -0,0 +1,5 @@ +describe('Demo test', () => { + it('should be tested', () => { + expect(true).toBe(true); + }); +}); diff --git a/tslint.json b/tslint.json index bd1ced0..a5335ed 100644 --- a/tslint.json +++ b/tslint.json @@ -1,53 +1,6 @@ { - "extends": [ - "tslint-config-airbnb" - ], - "rules": { - "max-line-length": [ - true, - 125 - ], - "member-ordering": [ - true, - { - "order": [ - "public-static-field", - "protected-static-field", - "private-static-field", - "public-instance-field", - "protected-instance-field", - "private-instance-field", - "public-constructor", - "protected-constructor", - "private-constructor", - "public-static-method", - "protected-static-method", - "private-static-method", - "public-instance-method", - "protected-instance-method", - "private-instance-method" - ] - } - ], - "strict-boolean-expressions": false, - "indent": [ - true, - "spaces", - 4 - ], - "ter-indent": false, - "typedef": [ - true, - "call-signature", - "parameter", - "property-declaration", - "member-variable-declaration" - ], - "variable-name": [ - true, - "check-format", - "allow-leading-underscore", - "allow-pascal-case" - ] - } + "extends": "@smartive/tslint-config", + "rules": { + "import-name": false + } } diff --git a/yarn.lock b/yarn.lock index 13504e7..617d773 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,48 +2,195 @@ # yarn lockfile v1 -"@types/chai@*", "@types/chai@^4.0.8": - version "4.0.8" - resolved "https://registry.yarnpkg.com/@types/chai/-/chai-4.0.8.tgz#d27600e9ba2f371e08695d90a0fe0408d89c7be7" +"@babel/code-frame@^7.0.0-beta.35": + version "7.0.0-beta.38" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.38.tgz#c0af5930617e55e050336838e3a3670983b0b2b2" + dependencies: + chalk "^2.0.0" + esutils "^2.0.2" + js-tokens "^3.0.0" -"@types/mocha@^2.2.44": - version "2.2.44" - resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-2.2.44.tgz#1d4a798e53f35212fd5ad4d04050620171cd5b5e" +"@semantic-release/commit-analyzer@^5.0.0": + version "5.0.0" + resolved "https://registry.yarnpkg.com/@semantic-release/commit-analyzer/-/commit-analyzer-5.0.0.tgz#767a2055b5cd0a67421b1d504f3ca7db97055c42" + dependencies: + conventional-changelog-angular "^1.4.0" + conventional-commits-parser "^2.0.0" + debug "^3.1.0" + import-from "^2.1.0" + lodash "^4.17.4" -"@types/node@^8.0.57": - version "8.0.57" - resolved "https://registry.yarnpkg.com/@types/node/-/node-8.0.57.tgz#e5d8b4dc112763e35cfc51988f4f38da3c486d99" +"@semantic-release/error@^2.1.0": + version "2.1.0" + resolved "https://registry.yarnpkg.com/@semantic-release/error/-/error-2.1.0.tgz#44771f676f5b148da309111285a97901aa95a6e0" -"@types/reflect-metadata@0.0.5": - version "0.0.5" - resolved "https://registry.yarnpkg.com/@types/reflect-metadata/-/reflect-metadata-0.0.5.tgz#9c042bfa9803d577aad4f57dfbca4b7cae4286fe" +"@semantic-release/github@^3.0.1": + version "3.0.2" + resolved "https://registry.yarnpkg.com/@semantic-release/github/-/github-3.0.2.tgz#753ae3d6a225877d50928a5240cf1f1009a0482b" + dependencies: + "@semantic-release/error" "^2.1.0" + debug "^3.1.0" + fs-extra "^5.0.0" + github "^13.0.0" + globby "^7.1.1" + lodash "^4.17.4" + mime "^2.0.3" + p-reduce "^1.0.0" + parse-github-url "^1.0.1" + url-join "^3.0.0" + +"@semantic-release/npm@^2.0.0": + version "2.6.4" + resolved "https://registry.yarnpkg.com/@semantic-release/npm/-/npm-2.6.4.tgz#0343816d94f3d1d6539c216c2886391647e3f9b7" + dependencies: + "@semantic-release/error" "^2.1.0" + debug "^3.1.0" + execa "^0.9.0" + fs-extra "^5.0.0" + lodash "^4.17.4" + nerf-dart "^1.0.0" + normalize-url "^2.0.1" + npm-conf "^1.1.3" + npm-registry-client "^8.5.0" + read-pkg "^3.0.0" + registry-auth-token "^3.3.1" + +"@semantic-release/release-notes-generator@^6.0.0": + version "6.0.3" + resolved "https://registry.yarnpkg.com/@semantic-release/release-notes-generator/-/release-notes-generator-6.0.3.tgz#c52bea12479a648bcb585d95940b4d72e57c5b71" + dependencies: + conventional-changelog-angular "^1.4.0" + conventional-changelog-writer "^2.0.1" + conventional-commits-parser "^2.0.0" + debug "^3.1.0" + get-stream "^3.0.0" + git-url-parse "^7.0.1" + import-from "^2.1.0" + into-stream "^3.1.0" + lodash "^4.17.4" + +"@smartive/tslint-config@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@smartive/tslint-config/-/tslint-config-2.0.0.tgz#51ff4d91c87ced8c03729502e63f3d3a0acec378" + dependencies: + tslint-config-airbnb "~5.4.2" + tslint-react "^3.2.0" + +"@types/jest@^22.0.1": + version "22.0.1" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-22.0.1.tgz#6370a6d60cce3845e4cd5d00bf65f654264685bc" + +"@types/node@*", "@types/node@^9.3.0": + version "9.3.0" + resolved "https://registry.yarnpkg.com/@types/node/-/node-9.3.0.tgz#3a129cda7c4e5df2409702626892cb4b96546dd5" + +"@types/reflect-metadata@0.1.0": + version "0.1.0" + resolved "https://registry.yarnpkg.com/@types/reflect-metadata/-/reflect-metadata-0.1.0.tgz#592805bdf6d63dd7229773218afeba37ac2eab16" + dependencies: + reflect-metadata "*" -"@types/sinon-chai@^2.7.29": - version "2.7.29" - resolved "https://registry.yarnpkg.com/@types/sinon-chai/-/sinon-chai-2.7.29.tgz#4db01497e2dd1908b2bd30d1782f456353f5f723" +JSONStream@^1.0.4: + version "1.3.2" + resolved "https://registry.yarnpkg.com/JSONStream/-/JSONStream-1.3.2.tgz#c102371b6ec3a7cf3b847ca00c20bb0fce4c6dea" dependencies: - "@types/chai" "*" - "@types/sinon" "*" + jsonparse "^1.2.0" + through ">=2.2.7 <3" + +abab@^1.0.3: + version "1.0.4" + resolved "https://registry.yarnpkg.com/abab/-/abab-1.0.4.tgz#5faad9c2c07f60dd76770f71cf025b62a63cfd4e" -"@types/sinon@*", "@types/sinon@^4.1.0": +abbrev@1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" + +acorn-globals@^4.0.0: version "4.1.0" - resolved "https://registry.yarnpkg.com/@types/sinon/-/sinon-4.1.0.tgz#cdfb934d656b2c888e51f53e95900c7bbca11c08" + resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-4.1.0.tgz#ab716025dbe17c54d3ef81d32ece2b2d99fe2538" + dependencies: + acorn "^5.0.0" + +acorn-jsx@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-3.0.1.tgz#afdf9488fb1ecefc8348f6fb22f464e32a58b36b" + dependencies: + acorn "^3.0.4" + +acorn@^3.0.4: + version "3.3.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" -ajv@^5.1.0: - version "5.5.1" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.1.tgz#b38bb8876d9e86bee994956a04e721e88b248eb2" +acorn@^5.0.0, acorn@^5.1.2, acorn@^5.2.1: + version "5.3.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.3.0.tgz#7446d39459c54fb49a80e6ee6478149b940ec822" + +agent-base@^4.1.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-4.2.0.tgz#9838b5c3392b962bad031e6a4c5e1024abec45ce" + dependencies: + es6-promisify "^5.0.0" + +ajv-keywords@^2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" + +ajv@^4.9.1: + version "4.11.8" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-4.11.8.tgz#82ffb02b29e662ae53bdc20af15947706739c536" + dependencies: + co "^4.6.0" + json-stable-stringify "^1.0.1" + +ajv@^5.1.0, ajv@^5.2.3, ajv@^5.3.0: + version "5.5.2" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" dependencies: co "^4.6.0" fast-deep-equal "^1.0.0" fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.3.0" +align-text@^0.1.1, align-text@^0.1.3: + version "0.1.4" + resolved "https://registry.yarnpkg.com/align-text/-/align-text-0.1.4.tgz#0cd90a561093f35d0a99256c22b7069433fad117" + dependencies: + kind-of "^3.0.2" + longest "^1.0.1" + repeat-string "^1.5.2" + +amdefine@>=0.0.4: + version "1.0.1" + resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" + ansi-align@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ansi-align/-/ansi-align-2.0.0.tgz#c36aeccba563b89ceb556f3690f0b1d9e3547f7f" dependencies: string-width "^2.0.0" +ansi-cyan@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/ansi-cyan/-/ansi-cyan-0.1.1.tgz#538ae528af8982f28ae30d86f2f17456d2609873" + dependencies: + ansi-wrap "0.1.0" + +ansi-escapes@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.0.0.tgz#ec3e8b4e9f8064fc02c3ac9b65f1c275bda8ef92" + +ansi-gray@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/ansi-gray/-/ansi-gray-0.1.1.tgz#2962cf54ec9792c48510a3deb524436861ef7251" + dependencies: + ansi-wrap "0.1.0" + +ansi-red@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/ansi-red/-/ansi-red-0.1.1.tgz#8c638f9d1080800a353c9c28c8a81ca4705d946c" + dependencies: + ansi-wrap "0.1.0" + ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" @@ -56,18 +203,61 @@ ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" -ansi-styles@^3.1.0: +ansi-styles@^3.1.0, ansi-styles@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.0.tgz#c159b8d5be0f9e5a6f346dab94f16ce022161b88" dependencies: color-convert "^1.9.0" +ansi-wrap@0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" + +ansicolors@~0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/ansicolors/-/ansicolors-0.2.1.tgz#be089599097b74a5c9c4a84a0cdbcdb62bd87aef" + +anymatch@^1.3.0: + version "1.3.2" + resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-1.3.2.tgz#553dcb8f91e3c889845dfdba34c77721b90b9d7a" + dependencies: + micromatch "^2.1.5" + normalize-path "^2.0.0" + +append-transform@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/append-transform/-/append-transform-0.4.0.tgz#d76ebf8ca94d276e247a36bad44a4b74ab611991" + dependencies: + default-require-extensions "^1.0.0" + +aproba@^1.0.3: + version "1.2.0" + resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" + +are-we-there-yet@~1.1.2: + version "1.1.4" + resolved "https://registry.yarnpkg.com/are-we-there-yet/-/are-we-there-yet-1.1.4.tgz#bb5dca382bb94f05e15194373d16fd3ba1ca110d" + dependencies: + delegates "^1.0.0" + readable-stream "^2.0.6" + argparse@^1.0.7: version "1.0.9" resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.9.tgz#73d83bc263f86e97f8cc4f6bae1b0e90a7d22c86" dependencies: sprintf-js "~1.0.2" +argv-formatter@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/argv-formatter/-/argv-formatter-1.0.0.tgz#a0ca0cbc29a5b73e836eebe1cbf6c5e0e4eb82f9" + +arr-diff@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-1.1.0.tgz#687c32758163588fef7de7b36fabe495eb1a399a" + dependencies: + arr-flatten "^1.0.1" + array-slice "^0.2.3" + arr-diff@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-2.0.0.tgz#8f3b827f955a8bd669697e4a4256ac3ceae356cf" @@ -78,14 +268,42 @@ arr-flatten@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/arr-flatten/-/arr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" +arr-union@^2.0.1: + version "2.1.0" + resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-2.1.0.tgz#20f9eab5ec70f5c7d215b1077b1c39161d292c7d" + array-differ@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-1.0.0.tgz#eff52e3758249d33be402b8bb8e564bb2b5d4031" +array-equal@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/array-equal/-/array-equal-1.0.0.tgz#8c2a5ef2472fd9ea742b04c77a75093ba2757c93" + +array-filter@~0.0.0: + version "0.0.1" + resolved "https://registry.yarnpkg.com/array-filter/-/array-filter-0.0.1.tgz#7da8cf2e26628ed732803581fd21f67cacd2eeec" + array-find-index@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/array-find-index/-/array-find-index-1.0.2.tgz#df010aa1287e164bbda6f9723b0a96a1ec4187a1" +array-ify@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/array-ify/-/array-ify-1.0.0.tgz#9e528762b4a9066ad163a6962a364418e9626ece" + +array-map@~0.0.0: + version "0.0.0" + resolved "https://registry.yarnpkg.com/array-map/-/array-map-0.0.0.tgz#88a2bab73d1cf7bcd5c1b118a003f66f665fa662" + +array-reduce@~0.0.0: + version "0.0.0" + resolved "https://registry.yarnpkg.com/array-reduce/-/array-reduce-0.0.0.tgz#173899d3ffd1c7d9383e4479525dbe278cab5f2b" + +array-slice@^0.2.3: + version "0.2.3" + resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-0.2.3.tgz#dd3cfb80ed7973a75117cdac69b0b99ec86186f5" + array-union@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/array-union/-/array-union-1.0.2.tgz#9a34410e4f4e3da23dea375be5be70f24778ec39" @@ -100,7 +318,7 @@ array-unique@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.2.1.tgz#a1d97ccafcbc2625cc70fadceb36a50c58b01a53" -arrify@^1.0.0: +arrify@^1.0.0, arrify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" @@ -116,14 +334,24 @@ assert-plus@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-0.2.0.tgz#d74e1b87e7affc0db8aadb7021f3fe48101ab234" -assertion-error@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.0.2.tgz#13ca515d86206da0bac66e834dd397d87581094c" +astral-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" + +async-each@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.1.tgz#19d386a1d9edc6e7c1c85d388aedbcc56d33602d" -async@^1.0.0: +async@^1.0.0, async@^1.4.0: version "1.5.2" resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" +async@^2.1.4: + version "2.6.0" + resolved "https://registry.yarnpkg.com/async/-/async-2.6.0.tgz#61a29abb6fcc026fea77e56d1c6ec53a795951f4" + dependencies: + lodash "^4.14.0" + asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" @@ -140,7 +368,7 @@ aws4@^1.2.1, aws4@^1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e" -babel-code-frame@^6.22.0: +babel-code-frame@^6.22.0, babel-code-frame@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" dependencies: @@ -148,6 +376,158 @@ babel-code-frame@^6.22.0: esutils "^2.0.2" js-tokens "^3.0.2" +babel-core@^6.0.0, babel-core@^6.24.1, babel-core@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.0.tgz#af32f78b31a6fcef119c87b0fd8d9753f03a0bb8" + dependencies: + babel-code-frame "^6.26.0" + babel-generator "^6.26.0" + babel-helpers "^6.24.1" + babel-messages "^6.23.0" + babel-register "^6.26.0" + babel-runtime "^6.26.0" + babel-template "^6.26.0" + babel-traverse "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + convert-source-map "^1.5.0" + debug "^2.6.8" + json5 "^0.5.1" + lodash "^4.17.4" + minimatch "^3.0.4" + path-is-absolute "^1.0.1" + private "^0.1.7" + slash "^1.0.0" + source-map "^0.5.6" + +babel-generator@^6.18.0, babel-generator@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.0.tgz#ac1ae20070b79f6e3ca1d3269613053774f20dc5" + dependencies: + babel-messages "^6.23.0" + babel-runtime "^6.26.0" + babel-types "^6.26.0" + detect-indent "^4.0.0" + jsesc "^1.3.0" + lodash "^4.17.4" + source-map "^0.5.6" + trim-right "^1.0.1" + +babel-helpers@^6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-helpers/-/babel-helpers-6.24.1.tgz#3471de9caec388e5c850e597e58a26ddf37602b2" + dependencies: + babel-runtime "^6.22.0" + babel-template "^6.24.1" + +babel-jest@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-22.1.0.tgz#7fae6f655fffe77e818a8c2868c754a42463fdfd" + dependencies: + babel-plugin-istanbul "^4.1.5" + babel-preset-jest "^22.1.0" + +babel-messages@^6.23.0: + version "6.23.0" + resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz#f3cdf4703858035b2a2951c6ec5edf6c62f2630e" + dependencies: + babel-runtime "^6.22.0" + +babel-plugin-istanbul@^4.1.4, babel-plugin-istanbul@^4.1.5: + version "4.1.5" + resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-4.1.5.tgz#6760cdd977f411d3e175bb064f2bc327d99b2b6e" + dependencies: + find-up "^2.1.0" + istanbul-lib-instrument "^1.7.5" + test-exclude "^4.1.1" + +babel-plugin-jest-hoist@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-22.1.0.tgz#c1281dd7887d77a1711dc760468c3b8285dde9ee" + +babel-plugin-syntax-object-rest-spread@^6.13.0: + version "6.13.0" + resolved "https://registry.yarnpkg.com/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz#fd6536f2bce13836ffa3a5458c4903a597bb3bf5" + +babel-plugin-transform-es2015-modules-commonjs@^6.24.1: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-commonjs/-/babel-plugin-transform-es2015-modules-commonjs-6.26.0.tgz#0d8394029b7dc6abe1a97ef181e00758dd2e5d8a" + dependencies: + babel-plugin-transform-strict-mode "^6.24.1" + babel-runtime "^6.26.0" + babel-template "^6.26.0" + babel-types "^6.26.0" + +babel-plugin-transform-strict-mode@^6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-strict-mode/-/babel-plugin-transform-strict-mode-6.24.1.tgz#d5faf7aa578a65bbe591cf5edae04a0c67020758" + dependencies: + babel-runtime "^6.22.0" + babel-types "^6.24.1" + +babel-preset-jest@^22.0.1, babel-preset-jest@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-22.1.0.tgz#ff4e704102f9642765e2254226050561d8942ec9" + dependencies: + babel-plugin-jest-hoist "^22.1.0" + babel-plugin-syntax-object-rest-spread "^6.13.0" + +babel-register@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-register/-/babel-register-6.26.0.tgz#6ed021173e2fcb486d7acb45c6009a856f647071" + dependencies: + babel-core "^6.26.0" + babel-runtime "^6.26.0" + core-js "^2.5.0" + home-or-tmp "^2.0.0" + lodash "^4.17.4" + mkdirp "^0.5.1" + source-map-support "^0.4.15" + +babel-runtime@^6.22.0, babel-runtime@^6.26.0, babel-runtime@^6.9.2: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe" + dependencies: + core-js "^2.4.0" + regenerator-runtime "^0.11.0" + +babel-template@^6.16.0, babel-template@^6.24.1, babel-template@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-template/-/babel-template-6.26.0.tgz#de03e2d16396b069f46dd9fff8521fb1a0e35e02" + dependencies: + babel-runtime "^6.26.0" + babel-traverse "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + lodash "^4.17.4" + +babel-traverse@^6.18.0, babel-traverse@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-6.26.0.tgz#46a9cbd7edcc62c8e5c064e2d2d8d0f4035766ee" + dependencies: + babel-code-frame "^6.26.0" + babel-messages "^6.23.0" + babel-runtime "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + debug "^2.6.8" + globals "^9.18.0" + invariant "^2.2.2" + lodash "^4.17.4" + +babel-types@^6.18.0, babel-types@^6.24.1, babel-types@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-types/-/babel-types-6.26.0.tgz#a3b073f94ab49eb6fa55cd65227a334380632497" + dependencies: + babel-runtime "^6.26.0" + esutils "^2.0.2" + lodash "^4.17.4" + to-fast-properties "^1.0.3" + +babylon@^6.18.0: + version "6.18.0" + resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz#af2f3b88fa6f5c1e4c634d1a0f8eac4f55b395e3" + balanced-match@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" @@ -162,12 +542,20 @@ beeper@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/beeper/-/beeper-1.1.1.tgz#e6d5ea8c5dad001304a70b22638447f69cb2f809" +binary-extensions@^1.0.0: + version "1.11.0" + resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.11.0.tgz#46aa1751fb6a2f93ee5e689bb1087d4b14c6c205" + block-stream@*: version "0.0.9" resolved "https://registry.yarnpkg.com/block-stream/-/block-stream-0.0.9.tgz#13ebfe778a03205cfe03751481ebb4b3300c126a" dependencies: inherits "~2.0.0" +boolbase@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/boolbase/-/boolbase-1.0.0.tgz#68dff5fbe60c51eb37725ea9e3ed310dcc1e776e" + boom@2.x.x: version "2.10.1" resolved "https://registry.yarnpkg.com/boom/-/boom-2.10.1.tgz#39c8918ceff5799f83f9492a848f625add0c766f" @@ -213,10 +601,26 @@ braces@^1.8.2: preserve "^0.2.0" repeat-element "^1.1.2" +browser-process-hrtime@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/browser-process-hrtime/-/browser-process-hrtime-0.1.2.tgz#425d68a58d3447f02a04aa894187fce8af8b7b8e" + +browser-resolve@^1.11.2: + version "1.11.2" + resolved "https://registry.yarnpkg.com/browser-resolve/-/browser-resolve-1.11.2.tgz#8ff09b0a2c421718a1051c260b32e48f442938ce" + dependencies: + resolve "1.1.7" + browser-stdout@1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/browser-stdout/-/browser-stdout-1.3.0.tgz#f351d32969d32fa5d7a5567154263d928ae3bd1f" +bser@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/bser/-/bser-2.0.0.tgz#9ac78d3ed5d915804fd87acb158bc797147a1719" + dependencies: + node-int64 "^0.4.0" + buffer-crc32@~0.2.3: version "0.2.13" resolved "https://registry.yarnpkg.com/buffer-crc32/-/buffer-crc32-0.2.13.tgz#0d333e3f00eac50aa1454abd30ef8c2a5d9a7242" @@ -225,6 +629,24 @@ builtin-modules@^1.0.0, builtin-modules@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-1.1.1.tgz#270f076c5a72c02f5b65a47df94c5fe3a278892f" +builtins@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/builtins/-/builtins-1.0.3.tgz#cb94faeb61c8696451db36534e1422f94f0aee88" + +caller-path@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-0.1.0.tgz#94085ef63581ecd3daa92444a8fe94e82577751f" + dependencies: + callsites "^0.2.0" + +callsites@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-0.2.0.tgz#afab96262910a7f33c19a5775825c69f34e350ca" + +callsites@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-2.0.0.tgz#06eb84f00eea413da86affefacbffb36093b3c50" + camelcase-keys@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/camelcase-keys/-/camelcase-keys-2.1.0.tgz#308beeaffdf28119051efa1d932213c91b8f92e7" @@ -232,11 +654,15 @@ camelcase-keys@^2.0.0: camelcase "^2.0.0" map-obj "^1.0.0" +camelcase@^1.0.2: + version "1.2.1" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-1.2.1.tgz#9bb5304d2e0b56698b2c758b08a3eaa9daa58a39" + camelcase@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-2.1.1.tgz#7c1d16d679a1bbe59ca02cacecfb011e201f5a1f" -camelcase@^4.0.0: +camelcase@^4.0.0, camelcase@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-4.1.0.tgz#d545635be1e33c542649c69173e5de6acfae34dd" @@ -244,6 +670,13 @@ capture-stack-trace@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/capture-stack-trace/-/capture-stack-trace-1.0.0.tgz#4a6fa07399c26bba47f0b2496b4d0fb408c5550d" +cardinal@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/cardinal/-/cardinal-1.0.0.tgz#50e21c1b0aa37729f9377def196b5a9cec932ee9" + dependencies: + ansicolors "~0.2.1" + redeyed "~1.0.0" + caseless@~0.11.0: version "0.11.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.11.0.tgz#715b96ea9841593cc33067923f5ec60ebda4f7d7" @@ -252,16 +685,12 @@ caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" -chai@^4.1.2: - version "4.1.2" - resolved "https://registry.yarnpkg.com/chai/-/chai-4.1.2.tgz#0f64584ba642f0f2ace2806279f4f06ca23ad73c" +center-align@^0.1.1: + version "0.1.3" + resolved "https://registry.yarnpkg.com/center-align/-/center-align-0.1.3.tgz#aa0d32629b6ee972200411cbd4461c907bc2b7ad" dependencies: - assertion-error "^1.0.1" - check-error "^1.0.1" - deep-eql "^3.0.0" - get-func-name "^2.0.0" - pathval "^1.0.0" - type-detect "^4.0.0" + align-text "^0.1.3" + lazy-cache "^1.0.3" chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: version "1.1.3" @@ -273,7 +702,7 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" -chalk@^2.0.1, chalk@^2.1.0: +chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.0.tgz#b5ea48efc9c1793dccc9b4767c93914d3f2d52ba" dependencies: @@ -281,14 +710,80 @@ chalk@^2.0.1, chalk@^2.1.0: escape-string-regexp "^1.0.5" supports-color "^4.0.0" -check-error@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/check-error/-/check-error-1.0.2.tgz#574d312edd88bb5dd8912e9286dd6c0aed4aac82" +chardet@^0.4.0: + version "0.4.2" + resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" + +cheerio@^1.0.0-rc.1: + version "1.0.0-rc.2" + resolved "https://registry.yarnpkg.com/cheerio/-/cheerio-1.0.0-rc.2.tgz#4b9f53a81b27e4d5dac31c0ffd0cfa03cc6830db" + dependencies: + css-select "~1.2.0" + dom-serializer "~0.1.0" + entities "~1.1.1" + htmlparser2 "^3.9.1" + lodash "^4.15.0" + parse5 "^3.0.1" + +chokidar@^1.6.0: + version "1.7.0" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-1.7.0.tgz#798e689778151c8076b4b360e5edd28cda2bb468" + dependencies: + anymatch "^1.3.0" + async-each "^1.0.0" + glob-parent "^2.0.0" + inherits "^2.0.1" + is-binary-path "^1.0.0" + is-glob "^2.0.0" + path-is-absolute "^1.0.0" + readdirp "^2.0.0" + optionalDependencies: + fsevents "^1.0.0" + +ci-info@^1.0.0: + version "1.1.2" + resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-1.1.2.tgz#03561259db48d0474c8bdc90f5b47b068b6bbfb4" + +circular-json@^0.3.1: + version "0.3.3" + resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" cli-boxes@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/cli-boxes/-/cli-boxes-1.0.0.tgz#4fa917c3e59c94a004cd61f8ee509da651687143" +cli-cursor@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" + dependencies: + restore-cursor "^2.0.0" + +cli-table@^0.3.1: + version "0.3.1" + resolved "https://registry.yarnpkg.com/cli-table/-/cli-table-0.3.1.tgz#f53b05266a8b1a0b934b3d0821e6e2dc5914ae23" + dependencies: + colors "1.0.3" + +cli-width@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" + +cliui@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-2.1.0.tgz#4b475760ff80264c762c3a1719032e91c7fea0d1" + dependencies: + center-align "^0.1.1" + right-align "^0.1.1" + wordwrap "0.0.2" + +cliui@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-4.0.0.tgz#743d4650e05f36d1ed2575b59638d87322bfbbcc" + dependencies: + string-width "^2.1.1" + strip-ansi "^4.0.0" + wrap-ansi "^2.0.0" + clone-buffer@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" @@ -325,6 +820,10 @@ co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" +code-point-at@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" + color-convert@^0.5.0: version "0.5.3" resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-0.5.3.tgz#bdb6c69ce660fadffe0b0007cc447e1b9f7282bd" @@ -345,6 +844,10 @@ color-string@^0.3.0: dependencies: color-name "^1.0.0" +color-support@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" + color@0.8.x: version "0.8.0" resolved "https://registry.yarnpkg.com/color/-/color-0.8.0.tgz#890c07c3fd4e649537638911cf691e5458b6fca5" @@ -356,6 +859,10 @@ colornames@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/colornames/-/colornames-0.0.2.tgz#d811fd6c84f59029499a8ac4436202935b92be31" +colors@1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/colors/-/colors-1.0.3.tgz#0433f44d809680fdeb60ed260f1b0c262e82a40b" + colors@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/colors/-/colors-1.1.2.tgz#168a4701756b6a7f51a12ce0c97bfa28c084ed63" @@ -377,14 +884,36 @@ commander@2.11.0: version "2.11.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.11.0.tgz#157152fd1e7a6c8d98a5b715cf376df928004563" -commander@^2.9.0: - version "2.12.2" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.12.2.tgz#0f5946c427ed9ec0d91a46bb9def53e54650e555" +commander@^2.11.0, commander@^2.12.1, commander@^2.8.1, commander@^2.9.0: + version "2.13.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.13.0.tgz#6964bca67685df7c1f1430c584f07d7597885b9c" + +compare-func@^1.3.1: + version "1.3.2" + resolved "https://registry.yarnpkg.com/compare-func/-/compare-func-1.3.2.tgz#99dd0ba457e1f9bc722b12c08ec33eeab31fa648" + dependencies: + array-ify "^1.0.0" + dot-prop "^3.0.0" concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" +concat-stream@^1.5.2, concat-stream@^1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.0.tgz#0aac662fd52be78964d5532f694784e70110acf7" + dependencies: + inherits "^2.0.3" + readable-stream "^2.2.2" + typedarray "^0.0.6" + +config-chain@^1.1.11: + version "1.1.11" + resolved "https://registry.yarnpkg.com/config-chain/-/config-chain-1.1.11.tgz#aba09747dfbe4c3e70e766a6e41586e1859fc6f2" + dependencies: + ini "^1.3.4" + proto-list "~1.2.1" + configstore@^3.0.0: version "3.1.1" resolved "https://registry.yarnpkg.com/configstore/-/configstore-3.1.1.tgz#094ee662ab83fad9917678de114faaea8fcdca90" @@ -396,14 +925,80 @@ configstore@^3.0.0: write-file-atomic "^2.0.0" xdg-basedir "^3.0.0" -convert-source-map@^1.1.1: +console-control-strings@^1.0.0, console-control-strings@~1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" + +contains-path@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/contains-path/-/contains-path-0.1.0.tgz#fe8cf184ff6670b6baef01a9d4861a5cbec4120a" + +content-type-parser@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/content-type-parser/-/content-type-parser-1.0.2.tgz#caabe80623e63638b2502fd4c7f12ff4ce2352e7" + +conventional-changelog-angular@^1.4.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/conventional-changelog-angular/-/conventional-changelog-angular-1.6.0.tgz#0a26a071f2c9fcfcf2b86ba0cfbf6e6301b75bfa" + dependencies: + compare-func "^1.3.1" + q "^1.4.1" + +conventional-changelog-writer@^2.0.1: + version "2.0.3" + resolved "https://registry.yarnpkg.com/conventional-changelog-writer/-/conventional-changelog-writer-2.0.3.tgz#073b0c39f1cc8fc0fd9b1566e93833f51489c81c" + dependencies: + compare-func "^1.3.1" + conventional-commits-filter "^1.1.1" + dateformat "^1.0.11" + handlebars "^4.0.2" + json-stringify-safe "^5.0.1" + lodash "^4.0.0" + meow "^3.3.0" + semver "^5.0.1" + split "^1.0.0" + through2 "^2.0.0" + +conventional-commits-filter@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/conventional-commits-filter/-/conventional-commits-filter-1.1.1.tgz#72172319c0c88328a015b30686b55527b3a5e54a" + dependencies: + is-subset "^0.1.1" + modify-values "^1.0.0" + +conventional-commits-parser@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/conventional-commits-parser/-/conventional-commits-parser-2.1.0.tgz#9b4b7c91124bf2a1a9a2cc1c72760d382cbbb229" + dependencies: + JSONStream "^1.0.4" + is-text-path "^1.0.0" + lodash "^4.2.1" + meow "^3.3.0" + split2 "^2.0.0" + through2 "^2.0.0" + trim-off-newlines "^1.0.0" + +convert-source-map@^1.1.1, convert-source-map@^1.4.0, convert-source-map@^1.5.0: version "1.5.1" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.1.tgz#b8278097b9bc229365de5c62cf5fcaed8b5599e5" +core-js@^2.4.0, core-js@^2.5.0: + version "2.5.3" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.3.tgz#8acc38345824f16d8365b7c9b4259168e8ed603e" + core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" +cosmiconfig@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-3.1.0.tgz#640a94bf9847f321800403cd273af60665c73397" + dependencies: + is-directory "^0.3.1" + js-yaml "^3.9.0" + parse-json "^3.0.0" + require-from-string "^2.0.1" + coveralls@^2.13.3: version "2.13.3" resolved "https://registry.yarnpkg.com/coveralls/-/coveralls-2.13.3.tgz#9ad7c2ae527417f361e8b626483f48ee92dd2bc7" @@ -414,15 +1009,31 @@ coveralls@^2.13.3: minimist "1.2.0" request "2.79.0" +cpx@^1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/cpx/-/cpx-1.5.0.tgz#185be018511d87270dedccc293171e37655ab88f" + dependencies: + babel-runtime "^6.9.2" + chokidar "^1.6.0" + duplexer "^0.1.1" + glob "^7.0.5" + glob2base "^0.0.12" + minimatch "^3.0.2" + mkdirp "^0.5.1" + resolve "^1.1.7" + safe-buffer "^5.0.1" + shell-quote "^1.6.1" + subarg "^1.0.0" + create-error-class@^3.0.0: version "3.0.2" resolved "https://registry.yarnpkg.com/create-error-class/-/create-error-class-3.0.2.tgz#06be7abef947a3f14a30fd610671d401bca8b7b6" dependencies: capture-stack-trace "^1.0.0" -cross-env@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/cross-env/-/cross-env-5.1.1.tgz#b6d8ab97f304c0f71dae7277b75fe424c08dfa74" +cross-env@^5.1.3: + version "5.1.3" + resolved "https://registry.yarnpkg.com/cross-env/-/cross-env-5.1.3.tgz#f8ae18faac87692b0a8b4d2f7000d4ec3a85dfd7" dependencies: cross-spawn "^5.1.0" is-windows "^1.0.0" @@ -451,6 +1062,29 @@ crypto-random-string@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-1.0.0.tgz#a230f64f568310e1498009940790ec99545bca7e" +css-select@~1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/css-select/-/css-select-1.2.0.tgz#2b3a110539c5355f1cd8d314623e870b121ec858" + dependencies: + boolbase "~1.0.0" + css-what "2.1" + domutils "1.5.1" + nth-check "~1.0.1" + +css-what@2.1: + version "2.1.0" + resolved "https://registry.yarnpkg.com/css-what/-/css-what-2.1.0.tgz#9467d032c38cfaefb9f2d79501253062f87fa1bd" + +cssom@0.3.x, "cssom@>= 0.3.2 < 0.4.0": + version "0.3.2" + resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.3.2.tgz#b8036170c79f07a90ff2f16e22284027a243848b" + +"cssstyle@>= 0.2.37 < 0.3.0": + version "0.2.37" + resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-0.2.37.tgz#541097234cb2513c83ceed3acddc27ff27987d54" + dependencies: + cssom "0.3.x" + currently-unhandled@^0.4.1: version "0.4.1" resolved "https://registry.yarnpkg.com/currently-unhandled/-/currently-unhandled-0.4.1.tgz#988df33feab191ef799a61369dd76c17adf957ea" @@ -463,36 +1097,64 @@ dashdash@^1.12.0: dependencies: assert-plus "^1.0.0" +dateformat@^1.0.11: + version "1.0.12" + resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-1.0.12.tgz#9f124b67594c937ff706932e4a642cca8dbbfee9" + dependencies: + get-stdin "^4.0.1" + meow "^3.3.0" + dateformat@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-2.2.0.tgz#4065e2013cf9fb916ddfd82efb506ad4c6769062" -debug@3.1.0: +debug@3.1.0, debug@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" dependencies: ms "2.0.0" -decamelize@^1.1.2: +debug@^2.2.0, debug@^2.6.8, debug@^2.6.9: + version "2.6.9" + resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" + dependencies: + ms "2.0.0" + +decamelize@^1.0.0, decamelize@^1.1.1, decamelize@^1.1.2: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" +decode-uri-component@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" + deep-assign@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/deep-assign/-/deep-assign-1.0.0.tgz#b092743be8427dc621ea0067cdec7e70dd19f37b" dependencies: is-obj "^1.0.0" -deep-eql@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-3.0.1.tgz#dfc9404400ad1c8fe023e7da1df1c147c4b444df" - dependencies: - type-detect "^4.0.0" - deep-extend@~0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.4.2.tgz#48b699c27e334bf89f10892be432f6e4c7d34a7f" +deep-is@~0.1.3: + version "0.1.3" + resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" + +default-require-extensions@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-1.0.0.tgz#f37ea15d3e13ffd9b437d33e1a75b5fb97874cb8" + dependencies: + strip-bom "^2.0.0" + +define-properties@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.2.tgz#83a73f2fea569898fb737193c8f873caf6d45c94" + dependencies: + foreach "^2.0.5" + object-keys "^1.0.8" + del-cli@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/del-cli/-/del-cli-1.1.0.tgz#27557d69a0b7df99dcbaa1e34a09e6ac6591d2c4" @@ -501,6 +1163,18 @@ del-cli@^1.1.0: meow "^3.6.0" update-notifier "^2.1.0" +del@^2.0.2: + version "2.2.2" + resolved "https://registry.yarnpkg.com/del/-/del-2.2.2.tgz#c12c981d067846c84bcaf862cff930d907ffd1a8" + dependencies: + globby "^5.0.0" + is-path-cwd "^1.0.0" + is-path-in-cwd "^1.0.0" + object-assign "^4.0.1" + pify "^2.0.0" + pinkie-promise "^2.0.0" + rimraf "^2.2.8" + del@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/del/-/del-3.0.0.tgz#53ecf699ffcbcb39637691ab13baf160819766e5" @@ -516,6 +1190,28 @@ delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" +delegates@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" + +denodeify@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/denodeify/-/denodeify-1.2.1.tgz#3a36287f5034e699e7577901052c2e6c94251631" + +detect-indent@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-4.0.0.tgz#f76d064352cdf43a1cb6ce619c4ee3a9475de208" + dependencies: + repeating "^2.0.0" + +detect-libc@^1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b" + +detect-newline@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-2.1.0.tgz#f41f1c10be4b00e87b5f13da680759f2c5bfd3e2" + diagnostics@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/diagnostics/-/diagnostics-1.1.0.tgz#e1090900b49523e8527be20f081275205f2ae36a" @@ -528,10 +1224,24 @@ diff@3.3.1: version "3.3.1" resolved "https://registry.yarnpkg.com/diff/-/diff-3.3.1.tgz#aa8567a6eed03c531fc89d3f711cd0e5259dec75" -diff@^3.1.0, diff@^3.2.0: +diff@^3.2.0: version "3.4.0" resolved "https://registry.yarnpkg.com/diff/-/diff-3.4.0.tgz#b1d85507daf3964828de54b37d0d73ba67dda56c" +dir-glob@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/dir-glob/-/dir-glob-2.0.0.tgz#0b205d2b6aef98238ca286598a8204d29d0a0034" + dependencies: + arrify "^1.0.1" + path-type "^3.0.0" + +doctrine@1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-1.5.0.tgz#379dce730f6166f76cefa4e6707a159b02c5a6fa" + dependencies: + esutils "^2.0.2" + isarray "^1.0.0" + doctrine@^0.7.2: version "0.7.2" resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-0.7.2.tgz#7cb860359ba3be90e040b26b729ce4bfa654c523" @@ -539,29 +1249,90 @@ doctrine@^0.7.2: esutils "^1.1.6" isarray "0.0.1" +doctrine@^2.0.2: + version "2.1.0" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" + dependencies: + esutils "^2.0.2" + +dom-serializer@0, dom-serializer@~0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-0.1.0.tgz#073c697546ce0780ce23be4a28e293e40bc30c82" + dependencies: + domelementtype "~1.1.1" + entities "~1.1.1" + +domelementtype@1, domelementtype@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/domelementtype/-/domelementtype-1.3.0.tgz#b17aed82e8ab59e52dd9c19b1756e0fc187204c2" + +domelementtype@~1.1.1: + version "1.1.3" + resolved "https://registry.yarnpkg.com/domelementtype/-/domelementtype-1.1.3.tgz#bd28773e2642881aec51544924299c5cd822185b" + +domexception@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/domexception/-/domexception-1.0.0.tgz#81fe5df81b3f057052cde3a9fa9bf536a85b9ab0" + +domhandler@^2.3.0: + version "2.4.1" + resolved "https://registry.yarnpkg.com/domhandler/-/domhandler-2.4.1.tgz#892e47000a99be55bbf3774ffea0561d8879c259" + dependencies: + domelementtype "1" + +domutils@1.5.1: + version "1.5.1" + resolved "https://registry.yarnpkg.com/domutils/-/domutils-1.5.1.tgz#dcd8488a26f563d61079e48c9f7b7e32373682cf" + dependencies: + dom-serializer "0" + domelementtype "1" + +domutils@^1.5.1: + version "1.6.2" + resolved "https://registry.yarnpkg.com/domutils/-/domutils-1.6.2.tgz#1958cc0b4c9426e9ed367fb1c8e854891b0fa3ff" + dependencies: + dom-serializer "0" + domelementtype "1" + +dot-prop@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/dot-prop/-/dot-prop-3.0.0.tgz#1b708af094a49c9a0e7dbcad790aba539dac1177" + dependencies: + is-obj "^1.0.0" + dot-prop@^4.1.0: version "4.2.0" resolved "https://registry.yarnpkg.com/dot-prop/-/dot-prop-4.2.0.tgz#1f19e0c2e1aa0e32797c49799f2837ac6af69c57" dependencies: is-obj "^1.0.0" +dotenv@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-4.0.0.tgz#864ef1379aced55ce6f95debecdce179f7a0cd1d" + duplexer2@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/duplexer2/-/duplexer2-0.0.2.tgz#c614dcf67e2fb14995a91711e5a617e8a60a31db" dependencies: readable-stream "~1.1.9" +duplexer2@~0.1.0: + version "0.1.4" + resolved "https://registry.yarnpkg.com/duplexer2/-/duplexer2-0.1.4.tgz#8b12dab878c0d69e3e7891051662a32fc6bddcc1" + dependencies: + readable-stream "^2.0.2" + duplexer3@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/duplexer3/-/duplexer3-0.1.4.tgz#ee01dd1cac0ed3cbc7fdbea37dc0a8f1ce002ce2" -duplexer@~0.1.1: +duplexer@^0.1.1, duplexer@~0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/duplexer/-/duplexer-0.1.1.tgz#ace6ff808c1ce66b57d1ebf97977acb02334cfc1" duplexify@^3.2.0: - version "3.5.1" - resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.5.1.tgz#4e1516be68838bc90a49994f0b39a6e5960befcd" + version "3.5.3" + resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.5.3.tgz#8b5818800df92fd0125b27ab896491912858243e" dependencies: end-of-stream "^1.0.0" inherits "^2.0.1" @@ -580,30 +1351,225 @@ enabled@1.0.x: dependencies: env-variable "0.0.x" +encoding@^0.1.11: + version "0.1.12" + resolved "https://registry.yarnpkg.com/encoding/-/encoding-0.1.12.tgz#538b66f3ee62cd1ab51ec323829d1f9480c74beb" + dependencies: + iconv-lite "~0.4.13" + end-of-stream@^1.0.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.0.tgz#7a90d833efda6cfa6eac0f4949dbb0fad3a63206" + version "1.4.1" + resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" dependencies: once "^1.4.0" +entities@^1.1.1, entities@~1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/entities/-/entities-1.1.1.tgz#6e5c2d0a5621b5dadaecef80b90edfb5cd7772f0" + +env-ci@^1.0.0: + version "1.2.1" + resolved "https://registry.yarnpkg.com/env-ci/-/env-ci-1.2.1.tgz#3973dd365289df494fe6fbacbf208486d79c4207" + dependencies: + execa "^0.9.0" + java-properties "^0.2.9" + env-variable@0.0.x: version "0.0.3" resolved "https://registry.yarnpkg.com/env-variable/-/env-variable-0.0.3.tgz#b86c1641be5610267d506f18071ea76d707097cb" -error-ex@^1.2.0: +error-ex@^1.2.0, error-ex@^1.3.1: version "1.3.1" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.1.tgz#f855a86ce61adc4e8621c3cda21e7a7612c3a8dc" dependencies: is-arrayish "^0.2.1" +es-abstract@^1.5.1: + version "1.10.0" + resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.10.0.tgz#1ecb36c197842a00d8ee4c2dfd8646bb97d60864" + dependencies: + es-to-primitive "^1.1.1" + function-bind "^1.1.1" + has "^1.0.1" + is-callable "^1.1.3" + is-regex "^1.0.4" + +es-to-primitive@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.1.1.tgz#45355248a88979034b6792e19bb81f2b7975dd0d" + dependencies: + is-callable "^1.1.1" + is-date-object "^1.0.1" + is-symbol "^1.0.1" + +es6-promise@^4.0.3: + version "4.2.2" + resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.2.tgz#f722d7769af88bd33bc13ec6605e1f92966b82d9" + +es6-promisify@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/es6-promisify/-/es6-promisify-5.0.0.tgz#5109d62f3e56ea967c4b63505aef08291c8a5203" + dependencies: + es6-promise "^4.0.3" + escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" +escodegen@^1.9.0: + version "1.9.0" + resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.9.0.tgz#9811a2f265dc1cd3894420ee3717064b632b8852" + dependencies: + esprima "^3.1.3" + estraverse "^4.2.0" + esutils "^2.0.2" + optionator "^0.8.1" + optionalDependencies: + source-map "~0.5.6" + +eslint-config-standard@^10.2.1: + version "10.2.1" + resolved "https://registry.yarnpkg.com/eslint-config-standard/-/eslint-config-standard-10.2.1.tgz#c061e4d066f379dc17cd562c64e819b4dd454591" + +eslint-import-resolver-node@^0.3.1: + version "0.3.2" + resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.2.tgz#58f15fb839b8d0576ca980413476aab2472db66a" + dependencies: + debug "^2.6.9" + resolve "^1.5.0" + +eslint-module-utils@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/eslint-module-utils/-/eslint-module-utils-2.1.1.tgz#abaec824177613b8a95b299639e1b6facf473449" + dependencies: + debug "^2.6.8" + pkg-dir "^1.0.0" + +eslint-plugin-import@^2.7.0: + version "2.8.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-2.8.0.tgz#fa1b6ef31fcb3c501c09859c1b86f1fc5b986894" + dependencies: + builtin-modules "^1.1.1" + contains-path "^0.1.0" + debug "^2.6.8" + doctrine "1.5.0" + eslint-import-resolver-node "^0.3.1" + eslint-module-utils "^2.1.1" + has "^1.0.1" + lodash.cond "^4.3.0" + minimatch "^3.0.3" + read-pkg-up "^2.0.0" + +eslint-plugin-node@^5.2.0: + version "5.2.1" + resolved "https://registry.yarnpkg.com/eslint-plugin-node/-/eslint-plugin-node-5.2.1.tgz#80df3253c4d7901045ec87fa660a284e32bdca29" + dependencies: + ignore "^3.3.6" + minimatch "^3.0.4" + resolve "^1.3.3" + semver "5.3.0" + +eslint-plugin-promise@^3.5.0: + version "3.6.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-promise/-/eslint-plugin-promise-3.6.0.tgz#54b7658c8f454813dc2a870aff8152ec4969ba75" + +eslint-plugin-standard@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/eslint-plugin-standard/-/eslint-plugin-standard-3.0.1.tgz#34d0c915b45edc6f010393c7eef3823b08565cf2" + +eslint-scope@^3.7.1: + version "3.7.1" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.1.tgz#3d63c3edfda02e06e01a452ad88caacc7cdcb6e8" + dependencies: + esrecurse "^4.1.0" + estraverse "^4.1.1" + +eslint-visitor-keys@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" + +eslint@^4.11.0: + version "4.15.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.15.0.tgz#89ab38c12713eec3d13afac14e4a89e75ef08145" + dependencies: + ajv "^5.3.0" + babel-code-frame "^6.22.0" + chalk "^2.1.0" + concat-stream "^1.6.0" + cross-spawn "^5.1.0" + debug "^3.1.0" + doctrine "^2.0.2" + eslint-scope "^3.7.1" + eslint-visitor-keys "^1.0.0" + espree "^3.5.2" + esquery "^1.0.0" + esutils "^2.0.2" + file-entry-cache "^2.0.0" + functional-red-black-tree "^1.0.1" + glob "^7.1.2" + globals "^11.0.1" + ignore "^3.3.3" + imurmurhash "^0.1.4" + inquirer "^3.0.6" + is-resolvable "^1.0.0" + js-yaml "^3.9.1" + json-stable-stringify-without-jsonify "^1.0.1" + levn "^0.3.0" + lodash "^4.17.4" + minimatch "^3.0.2" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + optionator "^0.8.2" + path-is-inside "^1.0.2" + pluralize "^7.0.0" + progress "^2.0.0" + require-uncached "^1.0.3" + semver "^5.3.0" + strip-ansi "^4.0.0" + strip-json-comments "~2.0.1" + table "^4.0.1" + text-table "~0.2.0" + +espree@^3.5.2: + version "3.5.2" + resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.2.tgz#756ada8b979e9dcfcdb30aad8d1a9304a905e1ca" + dependencies: + acorn "^5.2.1" + acorn-jsx "^3.0.0" + esprima@^2.6.0: version "2.7.3" resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.7.3.tgz#96e3b70d5779f6ad49cd032673d1c312767ba581" +esprima@^3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633" + +esprima@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804" + +esprima@~3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.0.0.tgz#53cf247acda77313e551c3aa2e73342d3fb4f7d9" + +esquery@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.0.tgz#cfba8b57d7fba93f17298a8a006a04cda13d80fa" + dependencies: + estraverse "^4.0.0" + +esrecurse@^4.1.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.0.tgz#fa9568d98d3823f9a41d91e902dcab9ea6e5b163" + dependencies: + estraverse "^4.1.0" + object-assign "^4.0.1" + +estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1, estraverse@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" + esutils@^1.1.6: version "1.1.6" resolved "https://registry.yarnpkg.com/esutils/-/esutils-1.1.6.tgz#c01ccaa9ae4b897c6d0c3e210ae52f3c7a844375" @@ -624,6 +1590,12 @@ event-stream@^3.3.1, event-stream@~3.3.4: stream-combiner "~0.0.4" through "~2.3.1" +exec-sh@^0.2.0: + version "0.2.1" + resolved "https://registry.yarnpkg.com/exec-sh/-/exec-sh-0.2.1.tgz#163b98a6e89e6b65b47c2a28d215bc1f63989c38" + dependencies: + merge "^1.1.3" + execa@^0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/execa/-/execa-0.7.0.tgz#944becd34cc41ee32a63a9faf27ad5a65fc59777" @@ -636,6 +1608,22 @@ execa@^0.7.0: signal-exit "^3.0.0" strip-eof "^1.0.0" +execa@^0.9.0: + version "0.9.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-0.9.0.tgz#adb7ce62cf985071f60580deb4a88b9e34712d01" + dependencies: + cross-spawn "^5.0.1" + get-stream "^3.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" + +exit@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" + expand-brackets@^0.1.4: version "0.1.5" resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-0.1.5.tgz#df07284e342a807cd733ac5af72411e581d1177b" @@ -648,6 +1636,23 @@ expand-range@^1.8.1: dependencies: fill-range "^2.1.0" +expect@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/expect/-/expect-22.1.0.tgz#f8f9b019ab275d859cbefed531fbaefe8972431d" + dependencies: + ansi-styles "^3.2.0" + jest-diff "^22.1.0" + jest-get-type "^22.1.0" + jest-matcher-utils "^22.1.0" + jest-message-util "^22.1.0" + jest-regex-util "^22.1.0" + +extend-shallow@^1.1.2: + version "1.1.4" + resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-1.1.4.tgz#19d6bf94dfc09d76ba711f39b872d21ff4dd9071" + dependencies: + kind-of "^1.1.0" + extend-shallow@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" @@ -658,6 +1663,14 @@ extend@^3.0.0, extend@~3.0.0, extend@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" +external-editor@^2.0.4: + version "2.1.0" + resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.1.0.tgz#3d026a21b7f95b5726387d4200ac160d372c3b48" + dependencies: + chardet "^0.4.0" + iconv-lite "^0.4.17" + tmp "^0.0.33" + extglob@^0.3.1: version "0.3.2" resolved "https://registry.yarnpkg.com/extglob/-/extglob-0.3.2.tgz#2e18ff3d2f49ab2765cec9023f011daa8d8349a1" @@ -673,10 +1686,11 @@ extsprintf@^1.2.0: resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz#e2689f8f356fad62cca65a3a91c5df5f9551692f" fancy-log@^1.1.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.0.tgz#45be17d02bb9917d60ccffd4995c999e6c8c9948" + version "1.3.2" + resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.2.tgz#f41125e3d84f2e7d89a43d06d958c8f78be16be1" dependencies: - chalk "^1.1.1" + ansi-gray "^0.1.1" + color-support "^1.1.3" time-stamp "^1.0.0" fast-deep-equal@^1.0.0: @@ -687,6 +1701,16 @@ fast-json-stable-stringify@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" +fast-levenshtein@~2.0.4: + version "2.0.6" + resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" + +fb-watchman@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.0.tgz#54e9abf7dfa2f26cd9b1636c588c1afc05de5d58" + dependencies: + bser "^2.0.0" + fd-slicer@~1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/fd-slicer/-/fd-slicer-1.0.1.tgz#8b5bcbd9ec327c5041bf9ab023fd6750f1177e65" @@ -697,10 +1721,30 @@ fecha@^2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/fecha/-/fecha-2.3.2.tgz#360f035dd6edd954bc9581f95f2a4a7f2a3505c1" +figures@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" + dependencies: + escape-string-regexp "^1.0.5" + +file-entry-cache@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" + dependencies: + flat-cache "^1.2.1" + object-assign "^4.0.1" + filename-regex@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/filename-regex/-/filename-regex-2.0.1.tgz#c1c4b9bee3e09725ddb106b75c1e301fe2f18b26" +fileset@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/fileset/-/fileset-2.0.3.tgz#8e7548a96d3cc2327ee5e674168723a333bba2a0" + dependencies: + glob "^7.0.3" + minimatch "^3.0.3" + filewalker@^0.1.3: version "0.1.3" resolved "https://registry.yarnpkg.com/filewalker/-/filewalker-0.1.3.tgz#d63bf9d813ba35344b8182747824f6ff754bf4c5" @@ -717,6 +1761,10 @@ fill-range@^2.1.0: repeat-element "^1.1.2" repeat-string "^1.5.2" +find-index@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/find-index/-/find-index-0.1.1.tgz#675d358b2ca3892d795a1ab47232f8b6e2e0dde4" + find-up@^1.0.0: version "1.1.2" resolved "https://registry.yarnpkg.com/find-up/-/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f" @@ -724,10 +1772,25 @@ find-up@^1.0.0: path-exists "^2.0.0" pinkie-promise "^2.0.0" +find-up@^2.0.0, find-up@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-2.1.0.tgz#45d1b7e506c717ddd482775a2b77920a3c0c57a7" + dependencies: + locate-path "^2.0.0" + first-chunk-stream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/first-chunk-stream/-/first-chunk-stream-1.0.0.tgz#59bfb50cd905f60d7c394cd3d9acaab4e6ad934e" +flat-cache@^1.2.1: + version "1.3.0" + resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.3.0.tgz#d3030b32b38154f4e3b7e9c709f490f7ef97c481" + dependencies: + circular-json "^0.3.1" + del "^2.0.2" + graceful-fs "^4.1.2" + write "^0.2.1" + for-in@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" @@ -738,6 +1801,10 @@ for-own@^0.1.4: dependencies: for-in "^1.0.1" +foreach@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99" + forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" @@ -758,25 +1825,57 @@ form-data@~2.3.1: combined-stream "^1.0.5" mime-types "^2.1.12" -formatio@1.2.0, formatio@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/formatio/-/formatio-1.2.0.tgz#f3b2167d9068c4698a8d51f4f760a39a54d818eb" - dependencies: - samsam "1.x" - fqueue@0.0.x: version "0.0.0" resolved "https://registry.yarnpkg.com/fqueue/-/fqueue-0.0.0.tgz#533205a4f9ad21bbaa38fc61cef3a930c2f54836" +from2@^2.1.1: + version "2.3.0" + resolved "https://registry.yarnpkg.com/from2/-/from2-2.3.0.tgz#8bfb5502bde4a4d36cfdeea007fcca21d7e382af" + dependencies: + inherits "^2.0.1" + readable-stream "^2.0.0" + from@~0: version "0.1.7" resolved "https://registry.yarnpkg.com/from/-/from-0.1.7.tgz#83c60afc58b9c56997007ed1a768b3ab303a44fe" +fs-extra@4.0.3: + version "4.0.3" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-4.0.3.tgz#0d852122e5bc5beb453fb028e9c0c9bf36340c94" + dependencies: + graceful-fs "^4.1.2" + jsonfile "^4.0.0" + universalify "^0.1.0" + +fs-extra@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-5.0.0.tgz#414d0110cdd06705734d055652c5411260c31abd" + dependencies: + graceful-fs "^4.1.2" + jsonfile "^4.0.0" + universalify "^0.1.0" + fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" -fstream@^1.0.2: +fsevents@^1.0.0, fsevents@^1.1.1: + version "1.1.3" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.1.3.tgz#11f82318f5fe7bb2cd22965a108e9306208216d8" + dependencies: + nan "^2.3.0" + node-pre-gyp "^0.6.39" + +fstream-ignore@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/fstream-ignore/-/fstream-ignore-1.0.5.tgz#9c31dae34767018fe1d249b24dada67d092da105" + dependencies: + fstream "^1.0.0" + inherits "2" + minimatch "^3.0.0" + +fstream@^1.0.0, fstream@^1.0.10, fstream@^1.0.2: version "1.0.11" resolved "https://registry.yarnpkg.com/fstream/-/fstream-1.0.11.tgz#5c1fb1f117477114f0632a0eb4b71b3cb0fd3171" dependencies: @@ -785,6 +1884,27 @@ fstream@^1.0.2: mkdirp ">=0.5 0" rimraf "2" +function-bind@^1.0.2, function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + +functional-red-black-tree@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" + +gauge@~2.7.3: + version "2.7.4" + resolved "https://registry.yarnpkg.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7" + dependencies: + aproba "^1.0.3" + console-control-strings "^1.0.0" + has-unicode "^2.0.0" + object-assign "^4.1.0" + signal-exit "^3.0.0" + string-width "^1.0.1" + strip-ansi "^3.0.1" + wide-align "^1.1.0" + generate-function@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/generate-function/-/generate-function-2.0.0.tgz#6858fe7c0969b7d4e9093337647ac79f60dfbe74" @@ -795,9 +1915,9 @@ generate-object-property@^1.1.0: dependencies: is-property "^1.0.0" -get-func-name@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/get-func-name/-/get-func-name-2.0.0.tgz#ead774abee72e20409433a066366023dd6887a41" +get-caller-file@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.2.tgz#f702e63127e7e231c160a80c1554acb70d5047e5" get-stdin@^4.0.1: version "4.0.1" @@ -813,6 +1933,42 @@ getpass@^0.1.1: dependencies: assert-plus "^1.0.0" +git-log-parser@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/git-log-parser/-/git-log-parser-1.2.0.tgz#2e6a4c1b13fc00028207ba795a7ac31667b9fd4a" + dependencies: + argv-formatter "~1.0.0" + spawn-error-forwarder "~1.0.0" + split2 "~1.0.0" + stream-combiner2 "~1.1.1" + through2 "~2.0.0" + traverse "~0.6.6" + +git-up@^2.0.0: + version "2.0.10" + resolved "https://registry.yarnpkg.com/git-up/-/git-up-2.0.10.tgz#20fe6bafbef4384cae253dc4f463c49a0c3bd2ec" + dependencies: + is-ssh "^1.3.0" + parse-url "^1.3.0" + +git-url-parse@^7.0.1: + version "7.0.2" + resolved "https://registry.yarnpkg.com/git-url-parse/-/git-url-parse-7.0.2.tgz#75fc7ae08e5daa90edc59043cdfa8da57c5a8715" + dependencies: + git-up "^2.0.0" + +github@^13.0.0: + version "13.1.0" + resolved "https://registry.yarnpkg.com/github/-/github-13.1.0.tgz#fc925950beebdff0cb0583197598b86f41bedaa4" + dependencies: + debug "^3.1.0" + dotenv "^4.0.0" + https-proxy-agent "^2.1.0" + is-stream "^1.1.0" + lodash "^4.17.4" + proxy-from-env "^1.0.0" + url-template "^2.0.8" + glob-base@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/glob-base/-/glob-base-0.3.0.tgz#dbb164f6221b1c0b1ccf82aea328b497df0ea3c4" @@ -846,7 +2002,13 @@ glob-stream@^5.3.2: to-absolute-glob "^0.1.1" unique-stream "^2.0.2" -glob@7.1.2, glob@^7.0.3, glob@^7.0.5, glob@^7.1.1, glob@^7.1.2: +glob2base@^0.0.12: + version "0.0.12" + resolved "https://registry.yarnpkg.com/glob2base/-/glob2base-0.0.12.tgz#9d419b3e28f12e83a362164a277055922c9c0d56" + dependencies: + find-index "^0.1.1" + +glob@7.1.2, glob@^7.0.3, glob@^7.0.5, glob@^7.0.6, glob@^7.1.1, glob@^7.1.2: version "7.1.2" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" dependencies: @@ -873,6 +2035,25 @@ global-dirs@^0.1.0: dependencies: ini "^1.3.4" +globals@^11.0.1: + version "11.1.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.1.0.tgz#632644457f5f0e3ae711807183700ebf2e4633e4" + +globals@^9.18.0: + version "9.18.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-9.18.0.tgz#aa3896b3e69b487f17e31ed2143d69a8e30c2d8a" + +globby@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/globby/-/globby-5.0.0.tgz#ebd84667ca0dbb330b99bcfc68eac2bc54370e0d" + dependencies: + array-union "^1.0.1" + arrify "^1.0.0" + glob "^7.0.3" + object-assign "^4.0.1" + pify "^2.0.0" + pinkie-promise "^2.0.0" + globby@^6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/globby/-/globby-6.1.0.tgz#f5a6d70e8395e21c858fb0489d64df02424d506c" @@ -883,6 +2064,17 @@ globby@^6.1.0: pify "^2.0.0" pinkie-promise "^2.0.0" +globby@^7.1.1: + version "7.1.1" + resolved "https://registry.yarnpkg.com/globby/-/globby-7.1.1.tgz#fb2ccff9401f8600945dfada97440cca972b8680" + dependencies: + array-union "^1.0.1" + dir-glob "^2.0.0" + glob "^7.1.2" + ignore "^3.3.5" + pify "^3.0.0" + slash "^1.0.0" + glogg@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/glogg/-/glogg-1.0.0.tgz#7fe0f199f57ac906cf512feead8f90ee4a284fc5" @@ -905,7 +2097,7 @@ got@^6.7.1: unzip-response "^2.0.1" url-parse-lax "^1.0.0" -graceful-fs@^4.0.0, graceful-fs@^4.1.11, graceful-fs@^4.1.2: +graceful-fs@^4.0.0, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6: version "4.1.11" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658" @@ -913,6 +2105,10 @@ growl@1.10.3: version "1.10.3" resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.3.tgz#1926ba90cf3edfe2adb4927f5880bc22c66c790f" +growly@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/growly/-/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081" + gulp-chmod@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/gulp-chmod/-/gulp-chmod-2.0.0.tgz#00c390b928a0799b251accf631aa09e01cc6299c" @@ -922,11 +2118,11 @@ gulp-chmod@^2.0.0: through2 "^2.0.0" gulp-filter@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/gulp-filter/-/gulp-filter-5.0.1.tgz#5d87f662e317e5839ef7650e620e6c9008ff92d0" + version "5.1.0" + resolved "https://registry.yarnpkg.com/gulp-filter/-/gulp-filter-5.1.0.tgz#a05e11affb07cf7dcf41a7de1cb7b63ac3783e73" dependencies: - gulp-util "^3.0.6" multimatch "^2.0.0" + plugin-error "^0.1.2" streamfilter "^1.0.5" gulp-gunzip@1.0.0: @@ -975,7 +2171,7 @@ gulp-untar@^0.0.6: tar "^2.2.1" through2 "~2.0.3" -gulp-util@^3.0.6, gulp-util@~3.0.8: +gulp-util@~3.0.8: version "3.0.8" resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.8.tgz#0054e1e744502e27c04c187c3ecc505dd54bbb4f" dependencies: @@ -1016,6 +2212,20 @@ gulplog@^1.0.0: dependencies: glogg "^1.0.0" +handlebars@^4.0.2, handlebars@^4.0.3: + version "4.0.11" + resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.0.11.tgz#630a35dfe0294bc281edae6ffc5d329fc7982dcc" + dependencies: + async "^1.4.0" + optimist "^0.6.1" + source-map "^0.4.4" + optionalDependencies: + uglify-js "^2.6" + +har-schema@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-1.0.5.tgz#d263135f43307c02c602afc8fe95970c0151369e" + har-schema@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" @@ -1029,6 +2239,13 @@ har-validator@~2.0.6: is-my-json-valid "^2.12.4" pinkie-promise "^2.0.0" +har-validator@~4.2.1: + version "4.2.1" + resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-4.2.1.tgz#33481d0f1bbff600dd203d75812a6a5fba002e2a" + dependencies: + ajv "^4.9.1" + har-schema "^1.0.5" + har-validator@~5.0.3: version "5.0.3" resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.0.3.tgz#ba402c266194f15956ef15e0fcf242993f6a7dfd" @@ -1042,6 +2259,10 @@ has-ansi@^2.0.0: dependencies: ansi-regex "^2.0.0" +has-flag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa" + has-flag@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-2.0.0.tgz#e8207af1cc7b30d446cc70b734b5e8be18f88d51" @@ -1052,7 +2273,17 @@ has-gulplog@^0.1.0: dependencies: sparkles "^1.0.0" -hawk@~3.1.3: +has-unicode@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" + +has@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.1.tgz#8461733f538b0837c9361e39a9ab9e9704dc2f28" + dependencies: + function-bind "^1.0.2" + +hawk@3.1.3, hawk@~3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/hawk/-/hawk-3.1.3.tgz#078444bd7c1640b0fe540d2c9b73d59678e8e1c4" dependencies: @@ -1082,10 +2313,34 @@ hoek@4.x.x: version "4.2.0" resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.0.tgz#72d9d0754f7fe25ca2d01ad8f8f9a9449a89526d" -hosted-git-info@^2.1.4: +home-or-tmp@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/home-or-tmp/-/home-or-tmp-2.0.0.tgz#e36c3f2d2cae7d746a857e38d18d5f32a7882db8" + dependencies: + os-homedir "^1.0.0" + os-tmpdir "^1.0.1" + +hosted-git-info@^2.1.4, hosted-git-info@^2.4.2: version "2.5.0" resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.5.0.tgz#6d60e34b3abbc8313062c3b798ef8d901a07af3c" +html-encoding-sniffer@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-1.0.2.tgz#e70d84b94da53aa375e11fe3a351be6642ca46f8" + dependencies: + whatwg-encoding "^1.0.1" + +htmlparser2@^3.9.1: + version "3.9.2" + resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-3.9.2.tgz#1bdf87acca0f3f9e53fa4fcceb0f4b4cbb00b338" + dependencies: + domelementtype "^1.3.0" + domhandler "^2.3.0" + domutils "^1.5.1" + entities "^1.1.1" + inherits "^2.0.1" + readable-stream "^2.0.2" + http-signature@~1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.1.1.tgz#df72e267066cd0ac67fb76adf8e134a8fbcf91bf" @@ -1102,10 +2357,38 @@ http-signature@~1.2.0: jsprim "^1.2.2" sshpk "^1.7.0" +https-proxy-agent@^2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-2.1.1.tgz#a7ce4382a1ba8266ee848578778122d491260fd9" + dependencies: + agent-base "^4.1.0" + debug "^3.1.0" + +iconv-lite@0.4.19, iconv-lite@^0.4.17, iconv-lite@~0.4.13: + version "0.4.19" + resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.19.tgz#f7468f60135f5e5dad3399c0a81be9a1603a082b" + +ignore@^3.3.3, ignore@^3.3.5, ignore@^3.3.6: + version "3.3.7" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.7.tgz#612289bfb3c220e186a58118618d5be8c1bab021" + +import-from@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/import-from/-/import-from-2.1.0.tgz#335db7f2a7affd53aaa471d4b8021dee36b7f3b1" + dependencies: + resolve-from "^3.0.0" + import-lazy@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/import-lazy/-/import-lazy-2.1.0.tgz#05698e3d45c88e8d7e9d92cb0584e77f096f3e43" +import-local@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/import-local/-/import-local-1.0.0.tgz#5e4ffdc03f4fe6c009c6729beb29631c2f8227bc" + dependencies: + pkg-dir "^2.0.0" + resolve-cwd "^2.0.0" + imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" @@ -1123,7 +2406,7 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@^2.0.1, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3: +inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" @@ -1131,18 +2414,60 @@ ini@^1.3.4, ini@~1.3.0: version "1.3.5" resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" -inversify-inject-decorators@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/inversify-inject-decorators/-/inversify-inject-decorators-3.0.2.tgz#9817e1f0212b9098d476d502449bd807305ca4e6" +inquirer@^3.0.6: + version "3.3.0" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-3.3.0.tgz#9dd2f2ad765dcab1ff0443b491442a20ba227dc9" + dependencies: + ansi-escapes "^3.0.0" + chalk "^2.0.0" + cli-cursor "^2.1.0" + cli-width "^2.0.0" + external-editor "^2.0.4" + figures "^2.0.0" + lodash "^4.3.0" + mute-stream "0.0.7" + run-async "^2.2.0" + rx-lite "^4.0.8" + rx-lite-aggregates "^4.0.8" + string-width "^2.1.0" + strip-ansi "^4.0.0" + through "^2.3.6" -inversify@^4.6.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/inversify/-/inversify-4.6.0.tgz#49abb2ee8fce3c99e1e94f01f36df77c3bfeba75" +into-stream@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/into-stream/-/into-stream-3.1.0.tgz#96fb0a936c12babd6ff1752a17d05616abd094c6" + dependencies: + from2 "^2.1.1" + p-is-promise "^1.1.0" + +invariant@^2.2.2: + version "2.2.2" + resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.2.tgz#9e1f56ac0acdb6bf303306f338be3b204ae60360" + dependencies: + loose-envify "^1.0.0" + +inversify-inject-decorators@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/inversify-inject-decorators/-/inversify-inject-decorators-3.1.0.tgz#d9941080bad77cec8a65ee29d905e4d5d73e1e95" + +inversify@^4.9.0: + version "4.9.0" + resolved "https://registry.yarnpkg.com/inversify/-/inversify-4.9.0.tgz#caa01f5856cfa0499aaaed9b1a635ef0c4a9f4d3" + +invert-kv@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" is-arrayish@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" +is-binary-path@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-1.0.1.tgz#75f16642b480f187a711c814161fd3a4a7655898" + dependencies: + binary-extensions "^1.0.0" + is-buffer@^1.1.5: version "1.1.6" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" @@ -1153,6 +2478,24 @@ is-builtin-module@^1.0.0: dependencies: builtin-modules "^1.0.0" +is-callable@^1.1.1, is-callable@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2" + +is-ci@^1.0.10: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-1.1.0.tgz#247e4162e7860cebbdaf30b774d6b0ac7dcfe7a5" + dependencies: + ci-info "^1.0.0" + +is-date-object@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16" + +is-directory@^0.3.1: + version "0.3.1" + resolved "https://registry.yarnpkg.com/is-directory/-/is-directory-0.3.1.tgz#61339b6f2475fc772fd9c9d83f5c8575dc154ae1" + is-dotfile@^1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/is-dotfile/-/is-dotfile-1.0.3.tgz#a6a2f32ffd2dfb04f5ca25ecd0f6b83cf798a1e1" @@ -1181,10 +2524,20 @@ is-finite@^1.0.0: dependencies: number-is-nan "^1.0.0" +is-fullwidth-code-point@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" + dependencies: + number-is-nan "^1.0.0" + is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" +is-generator-fn@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-generator-fn/-/is-generator-fn-1.0.0.tgz#969d49e1bb3329f6bb7f09089be26578b2ddd46a" + is-glob@^2.0.0, is-glob@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-2.0.1.tgz#d096f926a3ded5600f3fdfd91198cb0888c2d863" @@ -1205,8 +2558,8 @@ is-installed-globally@^0.1.0: is-path-inside "^1.0.0" is-my-json-valid@^2.12.4: - version "2.16.1" - resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.16.1.tgz#5a846777e2c2620d1e69104e5d3a03b1f6088f11" + version "2.17.1" + resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.17.1.tgz#3da98914a70a22f0a8563ef1511a246c6fc55471" dependencies: generate-function "^2.0.0" generate-object-property "^1.1.0" @@ -1249,6 +2602,10 @@ is-path-inside@^1.0.0: dependencies: path-is-inside "^1.0.1" +is-plain-obj@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-1.1.0.tgz#71a50c8429dfca773c92a390a4a03b39fcd51d3e" + is-posix-bracket@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/is-posix-bracket/-/is-posix-bracket-0.1.1.tgz#3334dc79774368e92f016e6fbc0a88f5cd6e6bc4" @@ -1257,6 +2614,10 @@ is-primitive@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-primitive/-/is-primitive-2.0.0.tgz#207bab91638499c07b2adf240a41a87210034575" +is-promise@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" + is-property@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/is-property/-/is-property-1.0.2.tgz#57fe1c4e48474edd65b09911f26b1cd4095dda84" @@ -1265,14 +2626,44 @@ is-redirect@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-redirect/-/is-redirect-1.0.0.tgz#1d03dded53bd8db0f30c26e4f95d36fc7c87dc24" +is-regex@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.0.4.tgz#5517489b547091b0930e095654ced25ee97e9491" + dependencies: + has "^1.0.1" + +is-resolvable@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.0.1.tgz#acca1cd36dbe44b974b924321555a70ba03b1cf4" + is-retry-allowed@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-retry-allowed/-/is-retry-allowed-1.1.0.tgz#11a060568b67339444033d0125a61a20d564fb34" +is-ssh@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/is-ssh/-/is-ssh-1.3.0.tgz#ebea1169a2614da392a63740366c3ce049d8dff6" + dependencies: + protocols "^1.1.0" + is-stream@^1.0.0, is-stream@^1.0.1, is-stream@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" +is-subset@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/is-subset/-/is-subset-0.1.1.tgz#8a59117d932de1de00f245fcdd39ce43f1e939a6" + +is-symbol@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.1.tgz#3cc59f00025194b6ab2e38dbae6689256b660572" + +is-text-path@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-text-path/-/is-text-path-1.0.1.tgz#4e1aa0fb51bfbcb3e92688001397202c1775b66e" + dependencies: + text-extensions "^1.0.0" + is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" @@ -1297,7 +2688,7 @@ isarray@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" -isarray@1.0.0, isarray@~1.0.0: +isarray@1.0.0, isarray@^1.0.0, isarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" @@ -1315,7 +2706,324 @@ isstream@0.1.x, isstream@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" -js-tokens@^3.0.2: +istanbul-api@^1.1.14: + version "1.2.1" + resolved "https://registry.yarnpkg.com/istanbul-api/-/istanbul-api-1.2.1.tgz#0c60a0515eb11c7d65c6b50bba2c6e999acd8620" + dependencies: + async "^2.1.4" + fileset "^2.0.2" + istanbul-lib-coverage "^1.1.1" + istanbul-lib-hook "^1.1.0" + istanbul-lib-instrument "^1.9.1" + istanbul-lib-report "^1.1.2" + istanbul-lib-source-maps "^1.2.2" + istanbul-reports "^1.1.3" + js-yaml "^3.7.0" + mkdirp "^0.5.1" + once "^1.4.0" + +istanbul-lib-coverage@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-1.1.1.tgz#73bfb998885299415c93d38a3e9adf784a77a9da" + +istanbul-lib-hook@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/istanbul-lib-hook/-/istanbul-lib-hook-1.1.0.tgz#8538d970372cb3716d53e55523dd54b557a8d89b" + dependencies: + append-transform "^0.4.0" + +istanbul-lib-instrument@^1.7.5, istanbul-lib-instrument@^1.8.0, istanbul-lib-instrument@^1.9.1: + version "1.9.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-1.9.1.tgz#250b30b3531e5d3251299fdd64b0b2c9db6b558e" + dependencies: + babel-generator "^6.18.0" + babel-template "^6.16.0" + babel-traverse "^6.18.0" + babel-types "^6.18.0" + babylon "^6.18.0" + istanbul-lib-coverage "^1.1.1" + semver "^5.3.0" + +istanbul-lib-report@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-1.1.2.tgz#922be27c13b9511b979bd1587359f69798c1d425" + dependencies: + istanbul-lib-coverage "^1.1.1" + mkdirp "^0.5.1" + path-parse "^1.0.5" + supports-color "^3.1.2" + +istanbul-lib-source-maps@^1.2.1, istanbul-lib-source-maps@^1.2.2: + version "1.2.2" + resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-1.2.2.tgz#750578602435f28a0c04ee6d7d9e0f2960e62c1c" + dependencies: + debug "^3.1.0" + istanbul-lib-coverage "^1.1.1" + mkdirp "^0.5.1" + rimraf "^2.6.1" + source-map "^0.5.3" + +istanbul-reports@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-1.1.3.tgz#3b9e1e8defb6d18b1d425da8e8b32c5a163f2d10" + dependencies: + handlebars "^4.0.3" + +java-properties@^0.2.9: + version "0.2.9" + resolved "https://registry.yarnpkg.com/java-properties/-/java-properties-0.2.9.tgz#d3de73e73c304f844c9e2a2be0ff24f6f93fda44" + +jest-changed-files@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-22.1.0.tgz#586a6164b87255dbd541a8bab880d98f14c99b7d" + dependencies: + throat "^4.0.0" + +jest-cli@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-22.1.2.tgz#89497932d7befb8a6952f2712473695c4bbef43f" + dependencies: + ansi-escapes "^3.0.0" + chalk "^2.0.1" + exit "^0.1.2" + glob "^7.1.2" + graceful-fs "^4.1.11" + import-local "^1.0.0" + is-ci "^1.0.10" + istanbul-api "^1.1.14" + istanbul-lib-coverage "^1.1.1" + istanbul-lib-instrument "^1.8.0" + istanbul-lib-source-maps "^1.2.1" + jest-changed-files "^22.1.0" + jest-config "^22.1.2" + jest-environment-jsdom "^22.1.2" + jest-get-type "^22.1.0" + jest-haste-map "^22.1.0" + jest-message-util "^22.1.0" + jest-regex-util "^22.1.0" + jest-resolve-dependencies "^22.1.0" + jest-runner "^22.1.2" + jest-runtime "^22.1.2" + jest-snapshot "^22.1.2" + jest-util "^22.1.2" + jest-worker "^22.1.0" + micromatch "^2.3.11" + node-notifier "^5.1.2" + realpath-native "^1.0.0" + rimraf "^2.5.4" + slash "^1.0.0" + string-length "^2.0.0" + strip-ansi "^4.0.0" + which "^1.2.12" + yargs "^10.0.3" + +jest-config@^22.0.1, jest-config@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-22.1.2.tgz#d3aee5c1df0997f0e2ae5c707eee04a7c87f1653" + dependencies: + chalk "^2.0.1" + glob "^7.1.1" + jest-environment-jsdom "^22.1.2" + jest-environment-node "^22.1.2" + jest-get-type "^22.1.0" + jest-jasmine2 "^22.1.2" + jest-regex-util "^22.1.0" + jest-resolve "^22.1.0" + jest-util "^22.1.2" + jest-validate "^22.1.2" + pretty-format "^22.1.0" + +jest-diff@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-22.1.0.tgz#0fad9d96c87b453896bf939df3dc8aac6919ac38" + dependencies: + chalk "^2.0.1" + diff "^3.2.0" + jest-get-type "^22.1.0" + pretty-format "^22.1.0" + +jest-docblock@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-22.1.0.tgz#3fe5986d5444cbcb149746eb4b07c57c5a464dfd" + dependencies: + detect-newline "^2.1.0" + +jest-environment-jsdom@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-22.1.2.tgz#4488c629631dd5de9059ec747fcd358735247f70" + dependencies: + jest-mock "^22.1.0" + jest-util "^22.1.2" + jsdom "^11.5.1" + +jest-environment-node@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-22.1.2.tgz#77dc32fbe08caa03ef2acb0948dce4b25a14633a" + dependencies: + jest-mock "^22.1.0" + jest-util "^22.1.2" + +jest-get-type@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-22.1.0.tgz#4e90af298ed6181edc85d2da500dbd2753e0d5a9" + +jest-haste-map@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-22.1.0.tgz#1174c6ff393f9818ebf1163710d8868b5370da2a" + dependencies: + fb-watchman "^2.0.0" + graceful-fs "^4.1.11" + jest-docblock "^22.1.0" + jest-worker "^22.1.0" + micromatch "^2.3.11" + sane "^2.0.0" + +jest-jasmine2@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-22.1.2.tgz#dee4ba04fb2cf462e4c7cfb499426e82e8fde5ac" + dependencies: + callsites "^2.0.0" + chalk "^2.0.1" + co "^4.6.0" + expect "^22.1.0" + graceful-fs "^4.1.11" + is-generator-fn "^1.0.0" + jest-diff "^22.1.0" + jest-matcher-utils "^22.1.0" + jest-message-util "^22.1.0" + jest-snapshot "^22.1.2" + source-map-support "^0.5.0" + +jest-leak-detector@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-22.1.0.tgz#08376644cee07103da069baac19adb0299b772c2" + dependencies: + pretty-format "^22.1.0" + +jest-matcher-utils@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-22.1.0.tgz#e164665b5d313636ac29f7f6fe9ef0a6ce04febc" + dependencies: + chalk "^2.0.1" + jest-get-type "^22.1.0" + pretty-format "^22.1.0" + +jest-message-util@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-22.1.0.tgz#51ba0794cb6e579bfc4e9adfac452f9f1a0293fc" + dependencies: + "@babel/code-frame" "^7.0.0-beta.35" + chalk "^2.0.1" + micromatch "^2.3.11" + slash "^1.0.0" + stack-utils "^1.0.1" + +jest-mock@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-22.1.0.tgz#87ec21c0599325671c9a23ad0e05c86fb5879b61" + +jest-regex-util@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-22.1.0.tgz#5daf2fe270074b6da63e5d85f1c9acc866768f53" + +jest-resolve-dependencies@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-22.1.0.tgz#340e4139fb13315cd43abc054e6c06136be51e31" + dependencies: + jest-regex-util "^22.1.0" + +jest-resolve@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-22.1.0.tgz#5f4307f48b93c1abdbeacc9ed80642ffcb246294" + dependencies: + browser-resolve "^1.11.2" + chalk "^2.0.1" + +jest-runner@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-22.1.2.tgz#e8565e4eb56c27219352b8486338ced9ceb462da" + dependencies: + exit "^0.1.2" + jest-config "^22.1.2" + jest-docblock "^22.1.0" + jest-haste-map "^22.1.0" + jest-jasmine2 "^22.1.2" + jest-leak-detector "^22.1.0" + jest-message-util "^22.1.0" + jest-runtime "^22.1.2" + jest-util "^22.1.2" + jest-worker "^22.1.0" + throat "^4.0.0" + +jest-runtime@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-22.1.2.tgz#42755d7cea2ffc7cdaa7f2dfa8736264a6057bf9" + dependencies: + babel-core "^6.0.0" + babel-jest "^22.1.0" + babel-plugin-istanbul "^4.1.5" + chalk "^2.0.1" + convert-source-map "^1.4.0" + exit "^0.1.2" + graceful-fs "^4.1.11" + jest-config "^22.1.2" + jest-haste-map "^22.1.0" + jest-regex-util "^22.1.0" + jest-resolve "^22.1.0" + jest-util "^22.1.2" + json-stable-stringify "^1.0.1" + micromatch "^2.3.11" + realpath-native "^1.0.0" + slash "^1.0.0" + strip-bom "3.0.0" + write-file-atomic "^2.1.0" + yargs "^10.0.3" + +jest-snapshot@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-22.1.2.tgz#b270cf6e3098f33aceeafda02b13eb0933dc6139" + dependencies: + chalk "^2.0.1" + jest-diff "^22.1.0" + jest-matcher-utils "^22.1.0" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + pretty-format "^22.1.0" + +jest-util@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-22.1.2.tgz#4bf098f651e8611d744cefa23fa026c97a6a3d5d" + dependencies: + callsites "^2.0.0" + chalk "^2.0.1" + graceful-fs "^4.1.11" + is-ci "^1.0.10" + jest-message-util "^22.1.0" + jest-validate "^22.1.2" + mkdirp "^0.5.1" + +jest-validate@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-22.1.2.tgz#c3b06bcba7bd9a850919fe336b5f2a8c3a239404" + dependencies: + chalk "^2.0.1" + jest-get-type "^22.1.0" + leven "^2.1.0" + pretty-format "^22.1.0" + +jest-worker@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-22.1.0.tgz#0987832fe58fbdc205357f4c19b992446368cafb" + dependencies: + merge-stream "^1.0.1" + +jest@^22.1.2: + version "22.1.2" + resolved "https://registry.yarnpkg.com/jest/-/jest-22.1.2.tgz#54dce0f4946a089a00d5fdac8291d5926e24f6ab" + dependencies: + jest-cli "^22.1.2" + +js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" @@ -1326,10 +3034,54 @@ js-yaml@3.6.1: argparse "^1.0.7" esprima "^2.6.0" +js-yaml@^3.7.0, js-yaml@^3.9.0, js-yaml@^3.9.1: + version "3.10.0" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.10.0.tgz#2e78441646bd4682e963f22b6e92823c309c62dc" + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + jsbn@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" +jsdom@^11.5.1: + version "11.5.1" + resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-11.5.1.tgz#5df753b8d0bca20142ce21f4f6c039f99a992929" + dependencies: + abab "^1.0.3" + acorn "^5.1.2" + acorn-globals "^4.0.0" + array-equal "^1.0.0" + browser-process-hrtime "^0.1.2" + content-type-parser "^1.0.1" + cssom ">= 0.3.2 < 0.4.0" + cssstyle ">= 0.2.37 < 0.3.0" + domexception "^1.0.0" + escodegen "^1.9.0" + html-encoding-sniffer "^1.0.1" + left-pad "^1.2.0" + nwmatcher "^1.4.3" + parse5 "^3.0.2" + pn "^1.0.0" + request "^2.83.0" + request-promise-native "^1.0.3" + sax "^1.2.1" + symbol-tree "^3.2.1" + tough-cookie "^2.3.3" + webidl-conversions "^4.0.2" + whatwg-encoding "^1.0.1" + whatwg-url "^6.3.0" + xml-name-validator "^2.0.1" + +jsesc@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-1.3.0.tgz#46c3fec8c1892b12b0833db9bc7622176dbab34b" + +json-parse-better-errors@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.1.tgz#50183cd1b2d25275de069e9e71b467ac9eab973a" + json-schema-traverse@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" @@ -1338,20 +3090,38 @@ json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" -json-stable-stringify@^1.0.0: +json-stable-stringify-without-jsonify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + +json-stable-stringify@^1.0.0, json-stable-stringify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af" dependencies: jsonify "~0.0.0" -json-stringify-safe@~5.0.1: +json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" +json5@^0.5.1: + version "0.5.1" + resolved "https://registry.yarnpkg.com/json5/-/json5-0.5.1.tgz#1eade7acc012034ad84e2396767ead9fa5495821" + +jsonfile@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-4.0.0.tgz#8771aae0799b64076b76640fca058f9c10e33ecb" + optionalDependencies: + graceful-fs "^4.1.6" + jsonify@~0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" +jsonparse@^1.2.0: + version "1.3.1" + resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280" + jsonpointer@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/jsonpointer/-/jsonpointer-4.0.1.tgz#4fd92cb34e0e9db3c89c8622ecf51f9b978c6cb9" @@ -1365,9 +3135,9 @@ jsprim@^1.2.2: json-schema "0.2.3" verror "1.10.0" -just-extend@^1.1.26: - version "1.1.27" - resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-1.1.27.tgz#ec6e79410ff914e472652abfa0e603c03d60e905" +kind-of@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-1.1.0.tgz#140a3d2d41a36d2efcfa9377b62c24f8495a5c44" kind-of@^3.0.2: version "3.2.2" @@ -1393,25 +3163,81 @@ latest-version@^3.0.0: dependencies: package-json "^4.0.0" +lazy-cache@^1.0.3: + version "1.0.4" + resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-1.0.4.tgz#a1d78fc3a50474cb80845d3b3b6e1da49a446e8e" + lazystream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lazystream/-/lazystream-1.0.0.tgz#f6995fe0f820392f61396be89462407bb77168e4" dependencies: readable-stream "^2.0.5" +lcid@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835" + dependencies: + invert-kv "^1.0.0" + lcov-parse@0.0.10: version "0.0.10" resolved "https://registry.yarnpkg.com/lcov-parse/-/lcov-parse-0.0.10.tgz#1b0b8ff9ac9c7889250582b70b71315d9da6d9a3" +left-pad@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.2.0.tgz#d30a73c6b8201d8f7d8e7956ba9616087a68e0ee" + +leven@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/leven/-/leven-2.1.0.tgz#c2e7a9f772094dee9d34202ae8acce4687875580" + +levn@^0.3.0, levn@~0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" + dependencies: + prelude-ls "~1.1.2" + type-check "~0.3.2" + +linkify-it@^2.0.0: + version "2.0.3" + resolved "https://registry.yarnpkg.com/linkify-it/-/linkify-it-2.0.3.tgz#d94a4648f9b1c179d64fa97291268bdb6ce9434f" + dependencies: + uc.micro "^1.0.1" + load-json-file@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" dependencies: graceful-fs "^4.1.2" - parse-json "^2.2.0" - pify "^2.0.0" - pinkie-promise "^2.0.0" - strip-bom "^2.0.0" + parse-json "^2.2.0" + pify "^2.0.0" + pinkie-promise "^2.0.0" + strip-bom "^2.0.0" + +load-json-file@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-2.0.0.tgz#7947e42149af80d696cbf797bcaabcfe1fe29ca8" + dependencies: + graceful-fs "^4.1.2" + parse-json "^2.2.0" + pify "^2.0.0" + strip-bom "^3.0.0" + +load-json-file@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-4.0.0.tgz#2f5f45ab91e33216234fd53adab668eb4ec0993b" + dependencies: + graceful-fs "^4.1.2" + parse-json "^4.0.0" + pify "^3.0.0" + strip-bom "^3.0.0" + +locate-path@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e" + dependencies: + p-locate "^2.0.0" + path-exists "^3.0.0" lodash._basecopy@^3.0.0: version "3.0.1" @@ -1449,16 +3275,20 @@ lodash._root@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" +lodash.assign@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-4.2.0.tgz#0d99f3ccd7a6d261d19bdaeb9245005d285808e7" + +lodash.cond@^4.3.0: + version "4.5.2" + resolved "https://registry.yarnpkg.com/lodash.cond/-/lodash.cond-4.5.2.tgz#f471a1da486be60f6ab955d17115523dd1d255d5" + lodash.escape@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/lodash.escape/-/lodash.escape-3.2.0.tgz#995ee0dc18c1b48cc92effae71a10aab5b487698" dependencies: lodash._root "^3.0.0" -lodash.get@^4.4.2: - version "4.4.2" - resolved "https://registry.yarnpkg.com/lodash.get/-/lodash.get-4.4.2.tgz#2d177f652fa31e939b4438d5341499dfa3825e99" - lodash.isarguments@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz#2f573d85c6a24289ff00663b491c1d338ff3458a" @@ -1483,6 +3313,10 @@ lodash.restparam@^3.0.0: version "3.6.1" resolved "https://registry.yarnpkg.com/lodash.restparam/-/lodash.restparam-3.6.1.tgz#936a4e309ef330a7645ed4145986c85ae5b20805" +lodash.sortby@^4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/lodash.sortby/-/lodash.sortby-4.7.0.tgz#edd14c824e2cc9c1e0b0a1b42bb5210516a42438" + lodash.template@^3.0.0: version "3.6.2" resolved "https://registry.yarnpkg.com/lodash.template/-/lodash.template-3.6.2.tgz#f8cdecc6169a255be9098ae8b0c53d378931d14f" @@ -1504,7 +3338,11 @@ lodash.templatesettings@^3.0.0: lodash._reinterpolate "^3.0.0" lodash.escape "^3.0.0" -lodash@^4.17.4: +lodash.toarray@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/lodash.toarray/-/lodash.toarray-4.4.0.tgz#24c4bfcd6b2fba38bfd0594db1179d8e9b656561" + +lodash@^4.0.0, lodash@^4.13.1, lodash@^4.14.0, lodash@^4.15.0, lodash@^4.17.4, lodash@^4.2.1, lodash@^4.3.0: version "4.17.4" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae" @@ -1519,13 +3357,15 @@ logform@^1.2.1: colors "^1.1.2" fecha "^2.3.2" -lolex@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-1.6.0.tgz#3a9a0283452a47d7439e72731b9e07d7386e49f6" +longest@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/longest/-/longest-1.0.1.tgz#30a0b2da38f73770e8294a0d22e6625ed77d0097" -lolex@^2.2.0: - version "2.3.1" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.3.1.tgz#3d2319894471ea0950ef64692ead2a5318cff362" +loose-envify@^1.0.0: + version "1.3.1" + resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.3.1.tgz#d1a8ad33fa9ce0e713d65fdd0ac8b748d478c848" + dependencies: + js-tokens "^3.0.0" loud-rejection@^1.0.0: version "1.6.0" @@ -1551,6 +3391,12 @@ make-dir@^1.0.0: dependencies: pify "^3.0.0" +makeerror@1.0.x: + version "1.0.11" + resolved "https://registry.yarnpkg.com/makeerror/-/makeerror-1.0.11.tgz#e01a5c9109f2af79660e4e8b9587790184f5a96c" + dependencies: + tmpl "1.0.x" + map-obj@^1.0.0, map-obj@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-1.0.1.tgz#d933ceb9205d82bdcf4886f6742bdc2b4dea146d" @@ -1559,7 +3405,41 @@ map-stream@~0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/map-stream/-/map-stream-0.1.0.tgz#e56aa94c4c8055a16404a0674b78f215f7c8e194" -meow@^3.6.0: +markdown-it@^8.3.1: + version "8.4.0" + resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-8.4.0.tgz#e2400881bf171f7018ed1bd9da441dac8af6306d" + dependencies: + argparse "^1.0.7" + entities "~1.1.1" + linkify-it "^2.0.0" + mdurl "^1.0.1" + uc.micro "^1.0.3" + +marked-terminal@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/marked-terminal/-/marked-terminal-2.0.0.tgz#5eaf568be66f686541afa52a558280310a31de2d" + dependencies: + cardinal "^1.0.0" + chalk "^1.1.3" + cli-table "^0.3.1" + lodash.assign "^4.2.0" + node-emoji "^1.4.1" + +marked@^0.3.9: + version "0.3.12" + resolved "https://registry.yarnpkg.com/marked/-/marked-0.3.12.tgz#7cf25ff2252632f3fe2406bde258e94eee927519" + +mdurl@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/mdurl/-/mdurl-1.0.1.tgz#fe85b2ec75a59037f2adfec100fd6c601761152e" + +mem@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/mem/-/mem-1.1.0.tgz#5edd52b485ca1d900fe64895505399a0dfa45f76" + dependencies: + mimic-fn "^1.0.0" + +meow@^3.3.0, meow@^3.6.0: version "3.7.0" resolved "https://registry.yarnpkg.com/meow/-/meow-3.7.0.tgz#72cb668b425228290abbfa856892587308a801fb" dependencies: @@ -1574,13 +3454,17 @@ meow@^3.6.0: redent "^1.0.0" trim-newlines "^1.0.0" -merge-stream@^1.0.0: +merge-stream@^1.0.0, merge-stream@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-1.0.1.tgz#4041202d508a342ba00174008df0c251b8c135e1" dependencies: readable-stream "^2.0.1" -micromatch@^2.3.7: +merge@^1.1.3: + version "1.2.0" + resolved "https://registry.yarnpkg.com/merge/-/merge-1.2.0.tgz#7531e39d4949c281a66b8c5a6e0265e8b05894da" + +micromatch@^2.1.5, micromatch@^2.3.11, micromatch@^2.3.7: version "2.3.11" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-2.3.11.tgz#86677c97d1720b363431d04d0d15293bd38c1565" dependencies: @@ -1608,7 +3492,19 @@ mime-types@^2.1.12, mime-types@~2.1.17, mime-types@~2.1.7: dependencies: mime-db "~1.30.0" -"minimatch@2 || 3", minimatch@^3.0.0, minimatch@^3.0.4: +mime@^1.3.4: + version "1.6.0" + resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" + +mime@^2.0.3: + version "2.2.0" + resolved "https://registry.yarnpkg.com/mime/-/mime-2.2.0.tgz#161e541965551d3b549fa1114391e3a3d55b923b" + +mimic-fn@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.1.0.tgz#e667783d92e89dbd342818b5230b9d62a672ad18" + +"minimatch@2 || 3", minimatch@^3.0.0, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" dependencies: @@ -1618,23 +3514,23 @@ minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" -minimist@1.2.0, minimist@^1.1.0, minimist@^1.1.3, minimist@^1.2.0: +minimist@1.2.0, minimist@^1.1.0, minimist@^1.1.1, minimist@^1.1.3, minimist@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" +minimist@~0.0.1: + version "0.0.10" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf" + mkdirp@0.5.1, "mkdirp@>=0.5 0", mkdirp@^0.5.0, mkdirp@^0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" dependencies: minimist "0.0.8" -mocha-testdata@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/mocha-testdata/-/mocha-testdata-1.2.0.tgz#6cc0d41820e9bb66903334524e5ae420de77ecea" - mocha@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/mocha/-/mocha-4.0.1.tgz#0aee5a95cf69a4618820f5e51fa31717117daf1b" + version "4.1.0" + resolved "https://registry.yarnpkg.com/mocha/-/mocha-4.1.0.tgz#7d86cfbcf35cb829e2754c32e17355ec05338794" dependencies: browser-stdout "1.3.0" commander "2.11.0" @@ -1647,6 +3543,10 @@ mocha@^4.0.1: mkdirp "0.5.1" supports-color "4.4.0" +modify-values@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/modify-values/-/modify-values-1.0.0.tgz#e2b6cdeb9ce19f99317a53722f3dbf5df5eaaab2" + ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" @@ -1666,15 +3566,63 @@ multipipe@^0.1.2: dependencies: duplexer2 "0.0.2" -nise@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/nise/-/nise-1.2.0.tgz#079d6cadbbcb12ba30e38f1c999f36ad4d6baa53" +mute-stream@0.0.7, mute-stream@~0.0.4: + version "0.0.7" + resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" + +nan@^2.3.0: + version "2.8.0" + resolved "https://registry.yarnpkg.com/nan/-/nan-2.8.0.tgz#ed715f3fe9de02b57a5e6252d90a96675e1f085a" + +natural-compare@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + +nerf-dart@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/nerf-dart/-/nerf-dart-1.0.0.tgz#e6dab7febf5ad816ea81cf5c629c5a0ebde72c1a" + +node-emoji@^1.4.1: + version "1.8.1" + resolved "https://registry.yarnpkg.com/node-emoji/-/node-emoji-1.8.1.tgz#6eec6bfb07421e2148c75c6bba72421f8530a826" + dependencies: + lodash.toarray "^4.4.0" + +node-fetch@^1.7.3: + version "1.7.3" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-1.7.3.tgz#980f6f72d85211a5347c6b2bc18c5b84c3eb47ef" dependencies: - formatio "^1.2.0" - just-extend "^1.1.26" - lolex "^1.6.0" - path-to-regexp "^1.7.0" - text-encoding "^0.6.4" + encoding "^0.1.11" + is-stream "^1.0.1" + +node-int64@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/node-int64/-/node-int64-0.4.0.tgz#87a9065cdb355d3182d8f94ce11188b825c68a3b" + +node-notifier@^5.1.2: + version "5.2.1" + resolved "https://registry.yarnpkg.com/node-notifier/-/node-notifier-5.2.1.tgz#fa313dd08f5517db0e2502e5758d664ac69f9dea" + dependencies: + growly "^1.3.0" + semver "^5.4.1" + shellwords "^0.1.1" + which "^1.3.0" + +node-pre-gyp@^0.6.39: + version "0.6.39" + resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.6.39.tgz#c00e96860b23c0e1420ac7befc5044e1d78d8649" + dependencies: + detect-libc "^1.0.2" + hawk "3.1.3" + mkdirp "^0.5.1" + nopt "^4.0.1" + npmlog "^4.0.2" + rc "^1.1.7" + request "2.81.0" + rimraf "^2.6.1" + semver "^5.3.0" + tar "^2.2.1" + tar-pack "^3.4.0" node.extend@~1.1.2: version "1.1.6" @@ -1682,7 +3630,14 @@ node.extend@~1.1.2: dependencies: is "^3.1.0" -normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: +nopt@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/nopt/-/nopt-4.0.1.tgz#d0d4685afd5415193c8c7505602d0d17cd64474d" + dependencies: + abbrev "1" + osenv "^0.1.4" + +normalize-package-data@^2.3.2, normalize-package-data@^2.3.4, "normalize-package-data@~1.0.1 || ^2.0.0": version "2.4.0" resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.4.0.tgz#12f95a307d58352075a04907b84ac8be98ac012f" dependencies: @@ -1691,22 +3646,82 @@ normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: semver "2 || 3 || 4 || 5" validate-npm-package-license "^3.0.1" -normalize-path@^2.0.1: +normalize-path@^2.0.0, normalize-path@^2.0.1: version "2.1.1" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" dependencies: remove-trailing-separator "^1.0.1" +normalize-url@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-2.0.1.tgz#835a9da1551fa26f70e92329069a23aa6574d7e6" + dependencies: + prepend-http "^2.0.0" + query-string "^5.0.1" + sort-keys "^2.0.0" + +npm-conf@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/npm-conf/-/npm-conf-1.1.3.tgz#256cc47bd0e218c259c4e9550bf413bc2192aff9" + dependencies: + config-chain "^1.1.11" + pify "^3.0.0" + +"npm-package-arg@^3.0.0 || ^4.0.0 || ^5.0.0": + version "5.1.2" + resolved "https://registry.yarnpkg.com/npm-package-arg/-/npm-package-arg-5.1.2.tgz#fb18d17bb61e60900d6312619919bd753755ab37" + dependencies: + hosted-git-info "^2.4.2" + osenv "^0.1.4" + semver "^5.1.0" + validate-npm-package-name "^3.0.0" + +npm-registry-client@^8.5.0: + version "8.5.0" + resolved "https://registry.yarnpkg.com/npm-registry-client/-/npm-registry-client-8.5.0.tgz#4878fb6fa1f18a5dc08ae83acf94d0d0112d7ed0" + dependencies: + concat-stream "^1.5.2" + graceful-fs "^4.1.6" + normalize-package-data "~1.0.1 || ^2.0.0" + npm-package-arg "^3.0.0 || ^4.0.0 || ^5.0.0" + once "^1.3.3" + request "^2.74.0" + retry "^0.10.0" + semver "2 >=2.2.1 || 3.x || 4 || 5" + slide "^1.1.3" + ssri "^4.1.2" + optionalDependencies: + npmlog "2 || ^3.1.0 || ^4.0.0" + npm-run-path@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" dependencies: path-key "^2.0.0" +"npmlog@2 || ^3.1.0 || ^4.0.0", npmlog@^4.0.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" + dependencies: + are-we-there-yet "~1.1.2" + console-control-strings "~1.1.0" + gauge "~2.7.3" + set-blocking "~2.0.0" + +nth-check@~1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/nth-check/-/nth-check-1.0.1.tgz#9929acdf628fc2c41098deab82ac580cf149aae4" + dependencies: + boolbase "~1.0.0" + number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" +nwmatcher@^1.4.3: + version "1.4.3" + resolved "https://registry.yarnpkg.com/nwmatcher/-/nwmatcher-1.4.3.tgz#64348e3b3d80f035b40ac11563d278f8b72db89c" + oauth-sign@~0.8.1, oauth-sign@~0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43" @@ -1715,10 +3730,21 @@ object-assign@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-3.0.0.tgz#9bedd5ca0897949bca47e7ff408062d549f587f2" -object-assign@^4.0.0, object-assign@^4.0.1: +object-assign@^4.0.0, object-assign@^4.0.1, object-assign@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" +object-keys@^1.0.8: + version "1.0.11" + resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.0.11.tgz#c54601778ad560f1142ce0e01bcca8b56d13426d" + +object.getownpropertydescriptors@^2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.0.3.tgz#8758c846f5b407adab0f236e0986f14b051caa16" + dependencies: + define-properties "^1.1.2" + es-abstract "^1.5.1" + object.omit@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/object.omit/-/object.omit-2.0.1.tgz#1a9c744829f39dbb858c76ca3579ae2a54ebd1fa" @@ -1726,7 +3752,7 @@ object.omit@^2.0.0: for-own "^0.1.4" is-extendable "^0.1.1" -once@^1.3.0, once@^1.4.0: +once@^1.3.0, once@^1.3.3, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" dependencies: @@ -1736,6 +3762,30 @@ one-time@0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/one-time/-/one-time-0.0.4.tgz#f8cdf77884826fe4dff93e3a9cc37b1e4480742e" +onetime@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" + dependencies: + mimic-fn "^1.0.0" + +optimist@^0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz#da3ea74686fa21a19a111c326e90eb15a0196686" + dependencies: + minimist "~0.0.1" + wordwrap "~0.0.2" + +optionator@^0.8.1, optionator@^0.8.2: + version "0.8.2" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" + dependencies: + deep-is "~0.1.3" + fast-levenshtein "~2.0.4" + levn "~0.3.0" + prelude-ls "~1.1.2" + type-check "~0.3.2" + wordwrap "~1.0.0" + ordered-read-streams@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-0.3.0.tgz#7137e69b3298bb342247a1bbee3881c80e2fd78b" @@ -1743,14 +3793,61 @@ ordered-read-streams@^0.3.0: is-stream "^1.0.1" readable-stream "^2.0.1" +os-homedir@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" + +os-locale@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-2.1.0.tgz#42bc2900a6b5b8bd17376c8e882b65afccf24bf2" + dependencies: + execa "^0.7.0" + lcid "^1.0.0" + mem "^1.1.0" + +os-tmpdir@^1.0.0, os-tmpdir@^1.0.1, os-tmpdir@~1.0.1, os-tmpdir@~1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" + +osenv@^0.1.3, osenv@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/osenv/-/osenv-0.1.4.tgz#42fe6d5953df06c8064be6f176c3d05aaaa34644" + dependencies: + os-homedir "^1.0.0" + os-tmpdir "^1.0.0" + p-finally@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" +p-is-promise@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/p-is-promise/-/p-is-promise-1.1.0.tgz#9c9456989e9f6588017b0434d56097675c3da05e" + +p-limit@^1.1.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.2.0.tgz#0e92b6bedcb59f022c13d0f1949dc82d15909f1c" + dependencies: + p-try "^1.0.0" + +p-locate@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-2.0.0.tgz#20a0103b222a70c8fd39cc2e580680f3dde5ec43" + dependencies: + p-limit "^1.1.0" + p-map@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/p-map/-/p-map-1.2.0.tgz#e4e94f311eabbc8633a1e79908165fca26241b6b" +p-reduce@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-reduce/-/p-reduce-1.0.0.tgz#18c2b0dd936a4690a529f8231f58a0fdb6a47dfa" + +p-try@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" + package-json@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/package-json/-/package-json-4.0.1.tgz#8869a0401253661c4c4ca3da6c2121ed555f5eed" @@ -1760,6 +3857,10 @@ package-json@^4.0.0: registry-url "^3.0.3" semver "^5.1.0" +parse-github-url@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/parse-github-url/-/parse-github-url-1.0.2.tgz#242d3b65cbcdda14bb50439e3242acf6971db395" + parse-glob@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/parse-glob/-/parse-glob-3.0.4.tgz#b2c376cfb11f35513badd173ef0bb6e3a388391c" @@ -1775,6 +3876,38 @@ parse-json@^2.2.0: dependencies: error-ex "^1.2.0" +parse-json@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-3.0.0.tgz#fa6f47b18e23826ead32f263e744d0e1e847fb13" + dependencies: + error-ex "^1.3.1" + +parse-json@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0" + dependencies: + error-ex "^1.3.1" + json-parse-better-errors "^1.0.1" + +parse-semver@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/parse-semver/-/parse-semver-1.1.1.tgz#9a4afd6df063dc4826f93fba4a99cf223f666cb8" + dependencies: + semver "^5.1.0" + +parse-url@^1.3.0: + version "1.3.11" + resolved "https://registry.yarnpkg.com/parse-url/-/parse-url-1.3.11.tgz#57c15428ab8a892b1f43869645c711d0e144b554" + dependencies: + is-ssh "^1.3.0" + protocols "^1.4.0" + +parse5@^3.0.1, parse5@^3.0.2: + version "3.0.3" + resolved "https://registry.yarnpkg.com/parse5/-/parse5-3.0.3.tgz#042f792ffdd36851551cf4e9e066b3874ab45b5c" + dependencies: + "@types/node" "*" + path-dirname@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/path-dirname/-/path-dirname-1.0.2.tgz#cc33d24d525e099a5388c0336c6e32b9160609e0" @@ -1785,11 +3918,15 @@ path-exists@^2.0.0: dependencies: pinkie-promise "^2.0.0" -path-is-absolute@^1.0.0: +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" + +path-is-absolute@^1.0.0, path-is-absolute@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" -path-is-inside@^1.0.1: +path-is-inside@^1.0.1, path-is-inside@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" @@ -1801,12 +3938,6 @@ path-parse@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.5.tgz#3c1adf871ea9cd6c9431b6ea2bd74a0ff055c4c1" -path-to-regexp@^1.7.0: - version "1.7.0" - resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.7.0.tgz#59fde0f435badacba103a84e9d3bc64e96b9937d" - dependencies: - isarray "0.0.1" - path-type@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/path-type/-/path-type-1.1.0.tgz#59c44f7ee491da704da415da5a4070ba4f8fe441" @@ -1815,9 +3946,17 @@ path-type@^1.0.0: pify "^2.0.0" pinkie-promise "^2.0.0" -pathval@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/pathval/-/pathval-1.1.0.tgz#b942e6d4bde653005ef6b71361def8727d0645e0" +path-type@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-2.0.0.tgz#f012ccb8415b7096fc2daa1054c3d72389594c73" + dependencies: + pify "^2.0.0" + +path-type@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-3.0.0.tgz#cef31dc8e0a1a3bb0d105c0cd97cf3bf47f4e36f" + dependencies: + pify "^3.0.0" pause-stream@0.0.11: version "0.0.11" @@ -1829,6 +3968,10 @@ pend@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/pend/-/pend-1.2.0.tgz#7a57eb550a6783f9115331fcf4663d5c8e007a50" +performance-now@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-0.2.0.tgz#33ef30c5c77d4ea21c5a53869d91b56d8f2555e5" + performance-now@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" @@ -1851,18 +3994,83 @@ pinkie@^2.0.0: version "2.0.4" resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" +pkg-dir@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-1.0.0.tgz#7a4b508a8d5bb2d629d447056ff4e9c9314cf3d4" + dependencies: + find-up "^1.0.0" + +pkg-dir@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-2.0.0.tgz#f6d5d1109e19d63edf428e0bd57e12777615334b" + dependencies: + find-up "^2.1.0" + +plugin-error@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-0.1.2.tgz#3b9bb3335ccf00f425e07437e19276967da47ace" + dependencies: + ansi-cyan "^0.1.1" + ansi-red "^0.1.1" + arr-diff "^1.0.1" + arr-union "^2.0.1" + extend-shallow "^1.1.2" + +pluralize@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" + +pn@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/pn/-/pn-1.1.0.tgz#e2f4cef0e219f463c179ab37463e4e1ecdccbafb" + +prelude-ls@~1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" + prepend-http@^1.0.1: version "1.0.4" resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc" +prepend-http@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897" + preserve@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/preserve/-/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b" +pretty-format@^22.1.0: + version "22.1.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-22.1.0.tgz#2277605b40ed4529ae4db51ff62f4be817647914" + dependencies: + ansi-regex "^3.0.0" + ansi-styles "^3.2.0" + +private@^0.1.7: + version "0.1.8" + resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff" + process-nextick-args@^1.0.6, process-nextick-args@~1.0.6: version "1.0.7" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3" +progress@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.0.tgz#8a1be366bf8fc23db2bd23f10c6fe920b4389d1f" + +proto-list@~1.2.1: + version "1.2.4" + resolved "https://registry.yarnpkg.com/proto-list/-/proto-list-1.2.4.tgz#212d5bfe1318306a420f6402b8e26ff39647a849" + +protocols@^1.1.0, protocols@^1.4.0: + version "1.4.6" + resolved "https://registry.yarnpkg.com/protocols/-/protocols-1.4.6.tgz#f8bb263ea1b5fd7a7604d26b8be39bd77678bf8a" + +proxy-from-env@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.0.0.tgz#33c50398f70ea7eb96d21f7b817630a55791c7ee" + pseudomap@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" @@ -1871,14 +4079,34 @@ punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" +punycode@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.0.tgz#5f863edc89b96db09074bad7947bf09056ca4e7d" + +q@^1.0.1, q@^1.4.1: + version "1.5.1" + resolved "https://registry.yarnpkg.com/q/-/q-1.5.1.tgz#7e32f75b41381291d04611f1bf14109ac00651d7" + qs@~6.3.0: version "6.3.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.3.2.tgz#e75bd5f6e268122a2a0e0bda630b2550c166502c" +qs@~6.4.0: + version "6.4.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.4.0.tgz#13e26d28ad6b0ffaa91312cd3bf708ed351e7233" + qs@~6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" +query-string@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/query-string/-/query-string-5.0.1.tgz#6e2b86fe0e08aef682ecbe86e85834765402bd88" + dependencies: + decode-uri-component "^0.2.0" + object-assign "^4.1.0" + strict-uri-encode "^1.0.0" + querystringify@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-1.0.0.tgz#6286242112c5b712fa654e526652bf6a13ff05cb" @@ -1902,9 +4130,9 @@ randomatic@^1.1.3: is-number "^3.0.0" kind-of "^4.0.0" -rc@^1.0.1, rc@^1.1.6: - version "1.2.2" - resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.2.tgz#d8ce9cb57e8d64d9c7badd9876c7c34cbe3c7077" +rc@^1.0.1, rc@^1.1.6, rc@^1.1.7: + version "1.2.4" + resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.4.tgz#a0f606caae2a3b862bbd0ef85482c0125b315fa3" dependencies: deep-extend "~0.4.0" ini "~1.3.0" @@ -1918,6 +4146,20 @@ read-pkg-up@^1.0.1: find-up "^1.0.0" read-pkg "^1.0.0" +read-pkg-up@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-2.0.0.tgz#6b72a8048984e0c41e79510fd5e9fa99b3b549be" + dependencies: + find-up "^2.0.0" + read-pkg "^2.0.0" + +read-pkg-up@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-3.0.0.tgz#3ed496685dba0f8fe118d0691dc51f4a1ff96f07" + dependencies: + find-up "^2.0.0" + read-pkg "^3.0.0" + read-pkg@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-1.1.0.tgz#f5ffaa5ecd29cb31c0474bca7d756b6bb29e3f28" @@ -1926,6 +4168,28 @@ read-pkg@^1.0.0: normalize-package-data "^2.3.2" path-type "^1.0.0" +read-pkg@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-2.0.0.tgz#8ef1c0623c6a6db0dc6713c4bfac46332b2368f8" + dependencies: + load-json-file "^2.0.0" + normalize-package-data "^2.3.2" + path-type "^2.0.0" + +read-pkg@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-3.0.0.tgz#9cbc686978fee65d16c00e2b19c237fcf6e38389" + dependencies: + load-json-file "^4.0.0" + normalize-package-data "^2.3.2" + path-type "^3.0.0" + +read@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/read/-/read-1.0.7.tgz#b3da19bd052431a97671d44a42634adf710b40c4" + dependencies: + mute-stream "~0.0.4" + "readable-stream@>=1.0.33-1 <1.1.0-0": version "1.0.34" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" @@ -1935,7 +4199,7 @@ read-pkg@^1.0.0: isarray "0.0.1" string_decoder "~0.10.x" -readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.4, readable-stream@^2.0.5, readable-stream@^2.1.5: +readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.4, readable-stream@^2.0.5, readable-stream@^2.0.6, readable-stream@^2.1.4, readable-stream@^2.1.5, readable-stream@^2.2.2: version "2.3.3" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.3.tgz#368f2512d79f9d46fdfc71349ae7878bbc1eb95c" dependencies: @@ -1956,6 +4220,21 @@ readable-stream@~1.1.9: isarray "0.0.1" string_decoder "~0.10.x" +readdirp@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-2.1.0.tgz#4ed0ad060df3073300c48440373f72d1cc642d78" + dependencies: + graceful-fs "^4.1.2" + minimatch "^3.0.2" + readable-stream "^2.0.2" + set-immediate-shim "^1.0.1" + +realpath-native@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/realpath-native/-/realpath-native-1.0.0.tgz#7885721a83b43bd5327609f0ddecb2482305fdf0" + dependencies: + util.promisify "^1.0.0" + redent@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/redent/-/redent-1.0.0.tgz#cf916ab1fd5f1f16dfb20822dd6ec7f730c2afde" @@ -1963,9 +4242,19 @@ redent@^1.0.0: indent-string "^2.1.0" strip-indent "^1.0.1" -reflect-metadata@^0.1.10: - version "0.1.10" - resolved "https://registry.yarnpkg.com/reflect-metadata/-/reflect-metadata-0.1.10.tgz#b4f83704416acad89988c9b15635d47e03b9344a" +redeyed@~1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/redeyed/-/redeyed-1.0.1.tgz#e96c193b40c0816b00aec842698e61185e55498a" + dependencies: + esprima "~3.0.0" + +reflect-metadata@*, reflect-metadata@^0.1.12: + version "0.1.12" + resolved "https://registry.yarnpkg.com/reflect-metadata/-/reflect-metadata-0.1.12.tgz#311bf0c6b63cd782f228a81abe146a2bfa9c56f2" + +regenerator-runtime@^0.11.0: + version "0.11.1" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz#be05ad7f9bf7d22e056f9726cee5017fbf19e2e9" regex-cache@^0.4.2: version "0.4.4" @@ -1973,7 +4262,7 @@ regex-cache@^0.4.2: dependencies: is-equal-shallow "^0.1.3" -registry-auth-token@^3.0.1: +registry-auth-token@^3.0.1, registry-auth-token@^3.3.1: version "3.3.1" resolved "https://registry.yarnpkg.com/registry-auth-token/-/registry-auth-token-3.3.1.tgz#fb0d3289ee0d9ada2cbb52af5dfe66cb070d3006" dependencies: @@ -2012,18 +4301,57 @@ replace-ext@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.0.tgz#de63128373fcbf7c3ccfa4de5a480c45a67958eb" +request-promise-core@1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/request-promise-core/-/request-promise-core-1.1.1.tgz#3eee00b2c5aa83239cfb04c5700da36f81cd08b6" + dependencies: + lodash "^4.13.1" + +request-promise-native@^1.0.3: + version "1.0.5" + resolved "https://registry.yarnpkg.com/request-promise-native/-/request-promise-native-1.0.5.tgz#5281770f68e0c9719e5163fd3fab482215f4fda5" + dependencies: + request-promise-core "1.1.1" + stealthy-require "^1.1.0" + tough-cookie ">=2.3.3" + request@2.79.0, request@~2.79.0: version "2.79.0" resolved "https://registry.yarnpkg.com/request/-/request-2.79.0.tgz#4dfe5bf6be8b8cdc37fcf93e04b65577722710de" dependencies: aws-sign2 "~0.6.0" aws4 "^1.2.1" - caseless "~0.11.0" + caseless "~0.11.0" + combined-stream "~1.0.5" + extend "~3.0.0" + forever-agent "~0.6.1" + form-data "~2.1.1" + har-validator "~2.0.6" + hawk "~3.1.3" + http-signature "~1.1.0" + is-typedarray "~1.0.0" + isstream "~0.1.2" + json-stringify-safe "~5.0.1" + mime-types "~2.1.7" + oauth-sign "~0.8.1" + qs "~6.3.0" + stringstream "~0.0.4" + tough-cookie "~2.3.0" + tunnel-agent "~0.4.1" + uuid "^3.0.0" + +request@2.81.0: + version "2.81.0" + resolved "https://registry.yarnpkg.com/request/-/request-2.81.0.tgz#c6928946a0e06c5f8d6f8a9333469ffda46298a0" + dependencies: + aws-sign2 "~0.6.0" + aws4 "^1.2.1" + caseless "~0.12.0" combined-stream "~1.0.5" extend "~3.0.0" forever-agent "~0.6.1" form-data "~2.1.1" - har-validator "~2.0.6" + har-validator "~4.2.1" hawk "~3.1.3" http-signature "~1.1.0" is-typedarray "~1.0.0" @@ -2031,13 +4359,15 @@ request@2.79.0, request@~2.79.0: json-stringify-safe "~5.0.1" mime-types "~2.1.7" oauth-sign "~0.8.1" - qs "~6.3.0" + performance-now "^0.2.0" + qs "~6.4.0" + safe-buffer "^5.0.1" stringstream "~0.0.4" tough-cookie "~2.3.0" - tunnel-agent "~0.4.1" + tunnel-agent "^0.6.0" uuid "^3.0.0" -request@^2.83.0: +request@^2.74.0, request@^2.83.0: version "2.83.0" resolved "https://registry.yarnpkg.com/request/-/request-2.83.0.tgz#ca0b65da02ed62935887808e6f510381034e3356" dependencies: @@ -2064,29 +4394,167 @@ request@^2.83.0: tunnel-agent "^0.6.0" uuid "^3.1.0" +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + +require-from-string@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.1.tgz#c545233e9d7da6616e9d59adfb39fc9f588676ff" + +require-main-filename@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" + +require-uncached@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" + dependencies: + caller-path "^0.1.0" + resolve-from "^1.0.0" + requires-port@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" -resolve@^1.3.2: +resolve-cwd@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-2.0.0.tgz#00a9f7387556e27038eae232caa372a6a59b665a" + dependencies: + resolve-from "^3.0.0" + +resolve-from@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-1.0.1.tgz#26cbfe935d1aeeeabb29bc3fe5aeb01e93d44226" + +resolve-from@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-3.0.0.tgz#b22c7af7d9d6881bc8b6e653335eebcb0a188748" + +resolve-from@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" + +resolve@1.1.7: + version "1.1.7" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" + +resolve@^1.1.7, resolve@^1.3.2, resolve@^1.3.3, resolve@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.5.0.tgz#1f09acce796c9a762579f31b2c1cc4c3cddf9f36" dependencies: path-parse "^1.0.5" -rimraf@2, rimraf@^2.2.8: +restore-cursor@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" + dependencies: + onetime "^2.0.0" + signal-exit "^3.0.2" + +retry@^0.10.0: + version "0.10.1" + resolved "https://registry.yarnpkg.com/retry/-/retry-0.10.1.tgz#e76388d217992c252750241d3d3956fed98d8ff4" + +right-align@^0.1.1: + version "0.1.3" + resolved "https://registry.yarnpkg.com/right-align/-/right-align-0.1.3.tgz#61339b722fe6a3515689210d24e14c96148613ef" + dependencies: + align-text "^0.1.1" + +rimraf@2, rimraf@^2.2.8, rimraf@^2.5.1, rimraf@^2.5.4, rimraf@^2.6.1: version "2.6.2" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.2.tgz#2ed8150d24a16ea8651e6d6ef0f47c4158ce7a36" dependencies: glob "^7.0.5" -safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: +run-async@^2.2.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" + dependencies: + is-promise "^2.1.0" + +rx-lite-aggregates@^4.0.8: + version "4.0.8" + resolved "https://registry.yarnpkg.com/rx-lite-aggregates/-/rx-lite-aggregates-4.0.8.tgz#753b87a89a11c95467c4ac1626c4efc4e05c67be" + dependencies: + rx-lite "*" + +rx-lite@*, rx-lite@^4.0.8: + version "4.0.8" + resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" + +rxjs@^5.5.6: + version "5.5.6" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-5.5.6.tgz#e31fb96d6fd2ff1fd84bcea8ae9c02d007179c02" + dependencies: + symbol-observable "1.0.1" + +safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" -samsam@1.x: - version "1.3.0" - resolved "https://registry.yarnpkg.com/samsam/-/samsam-1.3.0.tgz#8d1d9350e25622da30de3e44ba692b5221ab7c50" +sane@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/sane/-/sane-2.2.0.tgz#d6d2e2fcab00e3d283c93b912b7c3a20846f1d56" + dependencies: + anymatch "^1.3.0" + exec-sh "^0.2.0" + fb-watchman "^2.0.0" + minimatch "^3.0.2" + minimist "^1.1.1" + walker "~1.0.5" + watch "~0.18.0" + optionalDependencies: + fsevents "^1.1.1" + +sax@^1.2.1: + version "1.2.4" + resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" + +semantic-release-vsce@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/semantic-release-vsce/-/semantic-release-vsce-1.0.2.tgz#333fe5121f004dddd1d3eccc79ff0d84cc231175" + dependencies: + "@semantic-release/error" "^2.1.0" + commander "^2.11.0" + eslint "^4.11.0" + eslint-config-standard "^10.2.1" + eslint-plugin-import "^2.7.0" + eslint-plugin-node "^5.2.0" + eslint-plugin-promise "^3.5.0" + eslint-plugin-standard "^3.0.1" + execa "^0.9.0" + fs-extra "^5.0.0" + node-fetch "^1.7.3" + read-pkg-up "^3.0.0" + semver "^5.4.1" + vsce "^1.33.2" + +semantic-release@^12.2.2: + version "12.2.2" + resolved "https://registry.yarnpkg.com/semantic-release/-/semantic-release-12.2.2.tgz#6f114c2e2cb55040b78f985e11b0aa7d8d2ee111" + dependencies: + "@semantic-release/commit-analyzer" "^5.0.0" + "@semantic-release/error" "^2.1.0" + "@semantic-release/github" "^3.0.1" + "@semantic-release/npm" "^2.0.0" + "@semantic-release/release-notes-generator" "^6.0.0" + chalk "^2.3.0" + commander "^2.11.0" + cosmiconfig "^3.1.0" + debug "^3.1.0" + env-ci "^1.0.0" + execa "^0.9.0" + get-stream "^3.0.0" + git-log-parser "^1.2.0" + lodash "^4.0.0" + marked "^0.3.9" + marked-terminal "^2.0.0" + p-reduce "^1.0.0" + read-pkg-up "^3.0.0" + resolve-from "^4.0.0" + semver "^5.4.1" semver-diff@^2.0.0: version "2.1.0" @@ -2094,9 +4562,21 @@ semver-diff@^2.0.0: dependencies: semver "^5.0.3" -"semver@2 || 3 || 4 || 5", semver@^5.0.3, semver@^5.1.0, semver@^5.3.0, semver@^5.4.1: - version "5.4.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.4.1.tgz#e059c09d8571f0540823733433505d3a2f00b18e" +"semver@2 >=2.2.1 || 3.x || 4 || 5", "semver@2 || 3 || 4 || 5", semver@^5.0.1, semver@^5.0.3, semver@^5.1.0, semver@^5.3.0, semver@^5.4.1: + version "5.5.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.5.0.tgz#dc4bbc7a6ca9d916dee5d43516f0092b58f7b8ab" + +semver@5.3.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.3.0.tgz#9b2ce5d3de02d17c6012ad326aa6b4d0cf54f94f" + +set-blocking@^2.0.0, set-blocking@~2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" + +set-immediate-shim@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz#4b2b1b27eb808a9f8dcc481a58e5e56f599f3f61" shebang-command@^1.2.0: version "1.2.0" @@ -2108,25 +4588,36 @@ shebang-regex@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" +shell-quote@^1.6.1: + version "1.6.1" + resolved "https://registry.yarnpkg.com/shell-quote/-/shell-quote-1.6.1.tgz#f4781949cce402697127430ea3b3c5476f481767" + dependencies: + array-filter "~0.0.0" + array-map "~0.0.0" + array-reduce "~0.0.0" + jsonify "~0.0.0" + +shellwords@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b" + signal-exit@^3.0.0, signal-exit@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" -sinon-chai@^2.14.0: - version "2.14.0" - resolved "https://registry.yarnpkg.com/sinon-chai/-/sinon-chai-2.14.0.tgz#da7dd4cc83cd6a260b67cca0f7a9fdae26a1205d" +slash@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz#c41f2f6c39fc16d1cd17ad4b5d896114ae470d55" -sinon@^4.1.3: - version "4.1.3" - resolved "https://registry.yarnpkg.com/sinon/-/sinon-4.1.3.tgz#fc599eda47ed9f1a694ce774b94ab44260bd7ac5" +slice-ansi@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz#044f1a49d8842ff307aad6b505ed178bd950134d" dependencies: - diff "^3.1.0" - formatio "1.2.0" - lodash.get "^4.4.2" - lolex "^2.2.0" - nise "^1.2.0" - supports-color "^4.4.0" - type-detect "^4.0.5" + is-fullwidth-code-point "^2.0.0" + +slide@^1.1.3: + version "1.1.6" + resolved "https://registry.yarnpkg.com/slide/-/slide-1.1.6.tgz#56eb027d65b4d2dce6cb2e2d32c4d4afc9e1d707" sntp@1.x.x: version "1.0.9" @@ -2140,12 +4631,34 @@ sntp@2.x.x: dependencies: hoek "4.x.x" +sort-keys@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/sort-keys/-/sort-keys-2.0.0.tgz#658535584861ec97d730d6cf41822e1f56684128" + dependencies: + is-plain-obj "^1.0.0" + +source-map-support@^0.4.15: + version "0.4.18" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.4.18.tgz#0286a6de8be42641338594e97ccea75f0a2c585f" + dependencies: + source-map "^0.5.6" + source-map-support@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.0.tgz#2018a7ad2bdf8faf2691e5fddab26bed5a2bacab" + version "0.5.1" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.1.tgz#72291517d1fd0cb9542cee6c27520884b5da1a07" dependencies: source-map "^0.6.0" +source-map@^0.4.4: + version "0.4.4" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.4.4.tgz#eba4f5da9c0dc999de68032d8b4f76173652036b" + dependencies: + amdefine ">=0.0.4" + +source-map@^0.5.3, source-map@^0.5.6, source-map@~0.5.1, source-map@~0.5.6: + version "0.5.7" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" + source-map@^0.6.0: version "0.6.1" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" @@ -2154,6 +4667,10 @@ sparkles@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.0.tgz#1acbbfb592436d10bbe8f785b7cc6f82815012c3" +spawn-error-forwarder@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/spawn-error-forwarder/-/spawn-error-forwarder-1.0.0.tgz#1afd94738e999b0346d7b9fc373be55e07577029" + spdx-correct@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-1.0.2.tgz#4b3073d933ff51f3912f03ac5519498a4150db40" @@ -2168,12 +4685,30 @@ spdx-license-ids@^1.0.2: version "1.2.2" resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-1.2.2.tgz#c9df7a3424594ade6bd11900d596696dc06bac57" +split2@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/split2/-/split2-2.2.0.tgz#186b2575bcf83e85b7d18465756238ee4ee42493" + dependencies: + through2 "^2.0.2" + +split2@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/split2/-/split2-1.0.0.tgz#52e2e221d88c75f9a73f90556e263ff96772b314" + dependencies: + through2 "~2.0.0" + split@0.3: version "0.3.3" resolved "https://registry.yarnpkg.com/split/-/split-0.3.3.tgz#cd0eea5e63a211dfff7eb0f091c4133e2d0dd28f" dependencies: through "2" +split@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/split/-/split-1.0.1.tgz#605bd9be303aa59fb35f9229fbea0ddec9ea07d9" + dependencies: + through "2" + sprintf-js@~1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" @@ -2192,14 +4727,35 @@ sshpk@^1.7.0: jsbn "~0.1.0" tweetnacl "~0.14.0" +ssri@^4.1.2: + version "4.1.6" + resolved "https://registry.yarnpkg.com/ssri/-/ssri-4.1.6.tgz#0cb49b6ac84457e7bdd466cb730c3cb623e9a25b" + dependencies: + safe-buffer "^5.1.0" + stack-trace@0.0.x: version "0.0.10" resolved "https://registry.yarnpkg.com/stack-trace/-/stack-trace-0.0.10.tgz#547c70b347e8d32b4e108ea1a2a159e5fdde19c0" +stack-utils@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-1.0.1.tgz#d4f33ab54e8e38778b0ca5cfd3b3afb12db68620" + stat-mode@^0.2.0: version "0.2.2" resolved "https://registry.yarnpkg.com/stat-mode/-/stat-mode-0.2.2.tgz#e6c80b623123d7d80cf132ce538f346289072502" +stealthy-require@^1.1.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/stealthy-require/-/stealthy-require-1.1.1.tgz#35b09875b4ff49f26a777e509b3090a3226bf24b" + +stream-combiner2@~1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/stream-combiner2/-/stream-combiner2-1.1.1.tgz#fb4d8a1420ea362764e21ad4780397bebcb41cbe" + dependencies: + duplexer2 "~0.1.0" + readable-stream "^2.0.2" + stream-combiner@~0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/stream-combiner/-/stream-combiner-0.0.4.tgz#4d5e433c185261dde623ca3f44c586bcf5c4ad14" @@ -2220,7 +4776,26 @@ streamifier@~0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/streamifier/-/streamifier-0.1.1.tgz#97e98d8fa4d105d62a2691d1dc07e820db8dfc4f" -string-width@^2.0.0, string-width@^2.1.1: +strict-uri-encode@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz#279b225df1d582b1f54e65addd4352e18faa0713" + +string-length@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/string-length/-/string-length-2.0.0.tgz#d40dbb686a3ace960c1cffca562bf2c45f8363ed" + dependencies: + astral-regex "^1.0.0" + strip-ansi "^4.0.0" + +string-width@^1.0.1, string-width@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" + dependencies: + code-point-at "^1.0.0" + is-fullwidth-code-point "^1.0.0" + strip-ansi "^3.0.0" + +string-width@^2.0.0, string-width@^2.1.0, string-width@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" dependencies: @@ -2241,7 +4816,7 @@ stringstream@~0.0.4, stringstream@~0.0.5: version "0.0.5" resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.5.tgz#4e484cd4de5a0bbbee18e46307710a8a81621878" -strip-ansi@^3.0.0: +strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" dependencies: @@ -2260,6 +4835,10 @@ strip-bom-stream@^1.0.0: first-chunk-stream "^1.0.0" strip-bom "^2.0.0" +strip-bom@3.0.0, strip-bom@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz#2334c18e9c759f7bdd56fdef7e9ae3d588e68ed3" + strip-bom@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" @@ -2280,6 +4859,12 @@ strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" +subarg@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/subarg/-/subarg-1.0.0.tgz#f62cf17581e996b48fc965699f54c06ae268b8d2" + dependencies: + minimist "^1.1.0" + supports-color@4.4.0: version "4.4.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-4.4.0.tgz#883f7ddabc165142b2a61427f3352ded195d1a3e" @@ -2290,12 +4875,50 @@ supports-color@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" -supports-color@^4.0.0, supports-color@^4.4.0: +supports-color@^3.1.2: + version "3.2.3" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.2.3.tgz#65ac0504b3954171d8a64946b2ae3cbb8a5f54f6" + dependencies: + has-flag "^1.0.0" + +supports-color@^4.0.0: version "4.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-4.5.0.tgz#be7a0de484dec5c5cddf8b3d59125044912f635b" dependencies: has-flag "^2.0.0" +symbol-observable@1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/symbol-observable/-/symbol-observable-1.0.1.tgz#8340fc4702c3122df5d22288f88283f513d3fdd4" + +symbol-tree@^3.2.1: + version "3.2.2" + resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.2.tgz#ae27db38f660a7ae2e1c3b7d1bc290819b8519e6" + +table@^4.0.1: + version "4.0.2" + resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36" + dependencies: + ajv "^5.2.3" + ajv-keywords "^2.1.0" + chalk "^2.1.0" + lodash "^4.17.4" + slice-ansi "1.0.0" + string-width "^2.1.1" + +tar-pack@^3.4.0: + version "3.4.1" + resolved "https://registry.yarnpkg.com/tar-pack/-/tar-pack-3.4.1.tgz#e1dbc03a9b9d3ba07e896ad027317eb679a10a1f" + dependencies: + debug "^2.2.0" + fstream "^1.0.10" + fstream-ignore "^1.0.5" + once "^1.3.3" + readable-stream "^2.1.4" + rimraf "^2.5.1" + tar "^2.2.1" + uid-number "^0.0.6" + tar@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/tar/-/tar-2.2.1.tgz#8e4d2a256c0e2185c6b18ad694aec968b83cb1d1" @@ -2310,14 +4933,32 @@ term-size@^1.2.0: dependencies: execa "^0.7.0" -text-encoding@^0.6.4: - version "0.6.4" - resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" +test-exclude@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-4.1.1.tgz#4d84964b0966b0087ecc334a2ce002d3d9341e26" + dependencies: + arrify "^1.0.1" + micromatch "^2.3.11" + object-assign "^4.1.0" + read-pkg-up "^1.0.1" + require-main-filename "^1.0.1" + +text-extensions@^1.0.0: + version "1.7.0" + resolved "https://registry.yarnpkg.com/text-extensions/-/text-extensions-1.7.0.tgz#faaaba2625ed746d568a23e4d0aacd9bf08a8b39" text-hex@0.0.x: version "0.0.0" resolved "https://registry.yarnpkg.com/text-hex/-/text-hex-0.0.0.tgz#578fbc85a6a92636e42dd17b41d0218cce9eb2b3" +text-table@~0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" + +throat@^4.0.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/throat/-/throat-4.1.0.tgz#89037cbc92c56ab18926e6ba4cbb200e15672a6a" + through2-filter@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-2.0.0.tgz#60bc55a0dacb76085db1f9dae99ab43f83d622ec" @@ -2325,21 +4966,21 @@ through2-filter@^2.0.0: through2 "~2.0.0" xtend "~4.0.0" -through2@^0.6.0, through2@^0.6.1, through2@~0.6.5: +through2@^0.6.0, through2@~0.6.5: version "0.6.5" resolved "https://registry.yarnpkg.com/through2/-/through2-0.6.5.tgz#41ab9c67b29d57209071410e1d7a7a968cd3ad48" dependencies: readable-stream ">=1.0.33-1 <1.1.0-0" xtend ">=4.0.0 <4.1.0-0" -through2@^2.0.0, through2@^2.0.1, through2@^2.0.3, through2@~2.0.0, through2@~2.0.3: +through2@^2.0.0, through2@^2.0.1, through2@^2.0.2, through2@^2.0.3, through2@~2.0.0, through2@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.3.tgz#0004569b37c7c74ba39c43f3ced78d1ad94140be" dependencies: readable-stream "^2.1.5" xtend "~4.0.1" -through@2, through@~2.3, through@~2.3.1: +through@2, "through@>=2.2.7 <3", through@^2.3.6, through@~2.3, through@~2.3.1: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" @@ -2351,31 +4992,84 @@ timed-out@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/timed-out/-/timed-out-4.0.1.tgz#f32eacac5a175bea25d7fab565ab3ed8741ef56f" +tmp@0.0.29: + version "0.0.29" + resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.29.tgz#f25125ff0dd9da3ccb0c2dd371ee1288bb9128c0" + dependencies: + os-tmpdir "~1.0.1" + +tmp@^0.0.33: + version "0.0.33" + resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" + dependencies: + os-tmpdir "~1.0.2" + +tmpl@1.0.x: + version "1.0.4" + resolved "https://registry.yarnpkg.com/tmpl/-/tmpl-1.0.4.tgz#23640dd7b42d00433911140820e5cf440e521dd1" + to-absolute-glob@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/to-absolute-glob/-/to-absolute-glob-0.1.1.tgz#1cdfa472a9ef50c239ee66999b662ca0eb39937f" dependencies: extend-shallow "^2.0.1" -tough-cookie@~2.3.0, tough-cookie@~2.3.3: +to-fast-properties@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-1.0.3.tgz#b83571fa4d8c25b82e231b06e3a3055de4ca1a47" + +tough-cookie@>=2.3.3, tough-cookie@^2.3.3, tough-cookie@~2.3.0, tough-cookie@~2.3.3: version "2.3.3" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.3.tgz#0b618a5565b6dea90bf3425d04d55edc475a7561" dependencies: punycode "^1.4.1" +tr46@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-1.0.1.tgz#a8b13fd6bfd2489519674ccde55ba3693b706d09" + dependencies: + punycode "^2.1.0" + +traverse@~0.6.6: + version "0.6.6" + resolved "https://registry.yarnpkg.com/traverse/-/traverse-0.6.6.tgz#cbdf560fd7b9af632502fed40f918c157ea97137" + trim-newlines@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-1.0.0.tgz#5887966bb582a4503a41eb524f7d35011815a613" +trim-off-newlines@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/trim-off-newlines/-/trim-off-newlines-1.0.1.tgz#9f9ba9d9efa8764c387698bcbfeb2c848f11adb3" + +trim-right@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" + triple-beam@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/triple-beam/-/triple-beam-1.1.0.tgz#2ac387c8c4bd04bd26c61df891a6079f8592fe10" -tslib@^1.0.0, tslib@^1.7.1, tslib@^1.8.1: +ts-jest@^22.0.1: + version "22.0.1" + resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-22.0.1.tgz#48942936a466c2e76e259b02e2f1356f1839afc3" + dependencies: + babel-core "^6.24.1" + babel-plugin-istanbul "^4.1.4" + babel-plugin-transform-es2015-modules-commonjs "^6.24.1" + babel-preset-jest "^22.0.1" + cpx "^1.5.0" + fs-extra "4.0.3" + jest-config "^22.0.1" + pkg-dir "^2.0.0" + source-map-support "^0.5.0" + yargs "^10.0.3" + +tslib@^1.0.0, tslib@^1.7.1, tslib@^1.8.0, tslib@^1.8.1: version "1.8.1" resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.8.1.tgz#6946af2d1d651a7b1863b531d6e5afa41aa44eac" -tslint-config-airbnb@^5.4.2: +tslint-config-airbnb@~5.4.2: version "5.4.2" resolved "https://registry.yarnpkg.com/tslint-config-airbnb/-/tslint-config-airbnb-5.4.2.tgz#18eeff28f697b578731249d9a3ef8955b2f04f44" dependencies: @@ -2399,36 +5093,43 @@ tslint-eslint-rules@^4.1.1: tsutils "^1.4.0" tslint-microsoft-contrib@~5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/tslint-microsoft-contrib/-/tslint-microsoft-contrib-5.0.1.tgz#328ee9c28d07cdf793293204c96e2ffab9221994" + version "5.0.2" + resolved "https://registry.yarnpkg.com/tslint-microsoft-contrib/-/tslint-microsoft-contrib-5.0.2.tgz#ecc2a797f777a12f0066944cec0c81a9e7c59ee9" dependencies: - tsutils "^1.4.0" + tsutils "^2.12.1" + +tslint-react@^3.2.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/tslint-react/-/tslint-react-3.4.0.tgz#12ed3fc7063f3df988370206736b50acbce07e59" + dependencies: + tsutils "^2.13.1" -tslint@^5.8.0: - version "5.8.0" - resolved "https://registry.yarnpkg.com/tslint/-/tslint-5.8.0.tgz#1f49ad5b2e77c76c3af4ddcae552ae4e3612eb13" +tslint@^5.9.1: + version "5.9.1" + resolved "https://registry.yarnpkg.com/tslint/-/tslint-5.9.1.tgz#1255f87a3ff57eb0b0e1f0e610a8b4748046c9ae" dependencies: babel-code-frame "^6.22.0" builtin-modules "^1.1.1" - chalk "^2.1.0" - commander "^2.9.0" + chalk "^2.3.0" + commander "^2.12.1" diff "^3.2.0" glob "^7.1.1" + js-yaml "^3.7.0" minimatch "^3.0.4" resolve "^1.3.2" semver "^5.3.0" - tslib "^1.7.1" + tslib "^1.8.0" tsutils "^2.12.1" tsutils@^1.4.0: version "1.9.1" resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-1.9.1.tgz#b9f9ab44e55af9681831d5f28d0aeeaf5c750cb0" -tsutils@^2.12.1, tsutils@^2.12.2, tsutils@^2.13.0: - version "2.13.0" - resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-2.13.0.tgz#0f52b6aabbc4216e72796b66db028c6cf173e144" +tsutils@^2.12.1, tsutils@^2.12.2, tsutils@^2.13.1, tsutils@^2.19.1: + version "2.19.1" + resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-2.19.1.tgz#76d7ebdea9d7a7bf4a05f50ead3701b0168708d7" dependencies: - tslib "^1.7.1" + tslib "^1.8.1" tunnel-agent@^0.6.0: version "0.6.0" @@ -2440,13 +5141,30 @@ tunnel-agent@~0.4.1: version "0.4.3" resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.4.3.tgz#6373db76909fe570e08d73583365ed828a74eeeb" +tunnel@0.0.4: + version "0.0.4" + resolved "https://registry.yarnpkg.com/tunnel/-/tunnel-0.0.4.tgz#2d3785a158c174c9a16dc2c046ec5fc5f1742213" + tweetnacl@^0.14.3, tweetnacl@~0.14.0: version "0.14.5" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" -type-detect@^4.0.0, type-detect@^4.0.5: - version "4.0.5" - resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.5.tgz#d70e5bc81db6de2a381bcaca0c6e0cbdc7635de2" +type-check@~0.3.2: + version "0.3.2" + resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" + dependencies: + prelude-ls "~1.1.2" + +typed-rest-client@^0.9.0: + version "0.9.0" + resolved "https://registry.yarnpkg.com/typed-rest-client/-/typed-rest-client-0.9.0.tgz#f768cc0dc3f4e950f06e04825c36b3e7834aa1f2" + dependencies: + tunnel "0.0.4" + underscore "1.8.3" + +typedarray@^0.0.6: + version "0.0.6" + resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" typescript-parser@^2.2.2: version "2.2.2" @@ -2461,6 +5179,31 @@ typescript@^2.5.3, typescript@~2.6.2: version "2.6.2" resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.6.2.tgz#3c5b6fd7f6de0914269027f03c0946758f7673a4" +uc.micro@^1.0.1, uc.micro@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/uc.micro/-/uc.micro-1.0.3.tgz#7ed50d5e0f9a9fb0a573379259f2a77458d50192" + +uglify-js@^2.6: + version "2.8.29" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.29.tgz#29c5733148057bb4e1f75df35b7a9cb72e6a59dd" + dependencies: + source-map "~0.5.1" + yargs "~3.10.0" + optionalDependencies: + uglify-to-browserify "~1.0.0" + +uglify-to-browserify@~1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz#6e0924d6bda6b5afe349e39a6d632850a0f882b7" + +uid-number@^0.0.6: + version "0.0.6" + resolved "https://registry.yarnpkg.com/uid-number/-/uid-number-0.0.6.tgz#0ea10e8035e8eb5b8e4449f06da1c730663baa81" + +underscore@1.8.3, underscore@^1.8.3: + version "1.8.3" + resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.8.3.tgz#4f3fb53b106e6097fcf9cb4109f2a5e9bdfa5022" + unique-stream@^2.0.2: version "2.2.1" resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-2.2.1.tgz#5aa003cfbe94c5ff866c4e7d668bb1c4dbadb369" @@ -2474,6 +5217,10 @@ unique-string@^1.0.0: dependencies: crypto-random-string "^1.0.0" +universalify@^0.1.0: + version "0.1.1" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.1.tgz#fa71badd4437af4c148841e3b3b165f9e9e590b7" + unzip-response@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/unzip-response/-/unzip-response-2.0.1.tgz#d2f0f737d16b0615e72a6935ed04214572d56f97" @@ -2492,6 +5239,14 @@ update-notifier@^2.1.0: semver-diff "^2.0.0" xdg-basedir "^3.0.0" +url-join@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/url-join/-/url-join-1.1.0.tgz#741c6c2f4596c4830d6718460920d0c92202dc78" + +url-join@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/url-join/-/url-join-3.0.0.tgz#26e8113ace195ea30d0fc38186e45400f9cea672" + url-parse-lax@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/url-parse-lax/-/url-parse-lax-1.0.0.tgz#7af8f303645e9bd79a272e7a14ac68bc0609da73" @@ -2505,13 +5260,24 @@ url-parse@^1.1.9: querystringify "~1.0.0" requires-port "~1.0.0" +url-template@^2.0.8: + version "2.0.8" + resolved "https://registry.yarnpkg.com/url-template/-/url-template-2.0.8.tgz#fc565a3cccbff7730c775f5641f9555791439f21" + util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" +util.promisify@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/util.promisify/-/util.promisify-1.0.0.tgz#440f7165a459c9a16dc145eb8e72f35687097030" + dependencies: + define-properties "^1.1.2" + object.getownpropertydescriptors "^2.0.3" + uuid@^3.0.0, uuid@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04" + version "3.2.1" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.2.1.tgz#12c528bb9d58d0b9265d9a2f6f0fe8be17ff1f14" vali-date@^1.0.0: version "1.0.0" @@ -2524,6 +5290,12 @@ validate-npm-package-license@^3.0.1: spdx-correct "~1.0.0" spdx-expression-parse "~1.0.0" +validate-npm-package-name@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/validate-npm-package-name/-/validate-npm-package-name-3.0.0.tgz#5fa912d81eb7d0c74afc140de7317f0ca7df437e" + dependencies: + builtins "^1.0.3" + verror@1.10.0: version "1.10.0" resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" @@ -2555,10 +5327,10 @@ vinyl-fs@^2.0.0, vinyl-fs@^2.4.3: vinyl "^1.0.0" vinyl-source-stream@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/vinyl-source-stream/-/vinyl-source-stream-1.1.0.tgz#44cbe5108205279deb0c5653c094a2887938b1ab" + version "1.1.2" + resolved "https://registry.yarnpkg.com/vinyl-source-stream/-/vinyl-source-stream-1.1.2.tgz#62b53a135610a896e98ca96bee3a87f008a8e780" dependencies: - through2 "^0.6.1" + through2 "^2.0.3" vinyl "^0.4.3" vinyl@^0.4.3, vinyl@~0.4.6: @@ -2607,6 +5379,28 @@ vinyl@~2.0.1: remove-trailing-separator "^1.0.1" replace-ext "^1.0.0" +vsce@^1.33.2: + version "1.35.0" + resolved "https://registry.yarnpkg.com/vsce/-/vsce-1.35.0.tgz#cfc00503257f24fd4721ff2e16ab126143b1cd07" + dependencies: + cheerio "^1.0.0-rc.1" + commander "^2.8.1" + denodeify "^1.2.1" + glob "^7.0.6" + lodash "^4.15.0" + markdown-it "^8.3.1" + mime "^1.3.4" + minimatch "^3.0.3" + osenv "^0.1.3" + parse-semver "^1.1.1" + read "^1.0.7" + semver "^5.1.0" + tmp "0.0.29" + url-join "^1.1.0" + vso-node-api "^6.1.2-preview" + yauzl "^2.3.1" + yazl "^2.2.2" + vscode@^1.1.10: version "1.1.10" resolved "https://registry.yarnpkg.com/vscode/-/vscode-1.1.10.tgz#d1cba378ab24f1d3ddf9cd470d242ee1472dd35b" @@ -2626,18 +5420,72 @@ vscode@^1.1.10: url-parse "^1.1.9" vinyl-source-stream "^1.1.0" -which@^1.2.9: +vso-node-api@^6.1.2-preview: + version "6.1.2-preview" + resolved "https://registry.yarnpkg.com/vso-node-api/-/vso-node-api-6.1.2-preview.tgz#aab3546df2451ecd894e071bb99b5df19c5fa78f" + dependencies: + q "^1.0.1" + tunnel "0.0.4" + typed-rest-client "^0.9.0" + underscore "^1.8.3" + +walker@~1.0.5: + version "1.0.7" + resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.7.tgz#2f7f9b8fd10d677262b18a884e28d19618e028fb" + dependencies: + makeerror "1.0.x" + +watch@~0.18.0: + version "0.18.0" + resolved "https://registry.yarnpkg.com/watch/-/watch-0.18.0.tgz#28095476c6df7c90c963138990c0a5423eb4b986" + dependencies: + exec-sh "^0.2.0" + minimist "^1.2.0" + +webidl-conversions@^4.0.1, webidl-conversions@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" + +whatwg-encoding@^1.0.1: + version "1.0.3" + resolved "https://registry.yarnpkg.com/whatwg-encoding/-/whatwg-encoding-1.0.3.tgz#57c235bc8657e914d24e1a397d3c82daee0a6ba3" + dependencies: + iconv-lite "0.4.19" + +whatwg-url@^6.3.0: + version "6.4.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.4.0.tgz#08fdf2b9e872783a7a1f6216260a1d66cc722e08" + dependencies: + lodash.sortby "^4.7.0" + tr46 "^1.0.0" + webidl-conversions "^4.0.1" + +which-module@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz#d9ef07dce77b9902b8a3a8fa4b31c3e3f7e6e87a" + +which@^1.2.12, which@^1.2.9, which@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a" dependencies: isexe "^2.0.0" +wide-align@^1.1.0: + version "1.1.2" + resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.2.tgz#571e0f1b0604636ebc0dfc21b0339bbe31341710" + dependencies: + string-width "^1.0.2" + widest-line@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/widest-line/-/widest-line-2.0.0.tgz#0142a4e8a243f8882c0233aa0e0281aa76152273" dependencies: string-width "^2.1.1" +window-size@0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/window-size/-/window-size-0.1.0.tgz#5438cd2ea93b202efa3a19fe8887aee7c94f9c9d" + winston-transport@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/winston-transport/-/winston-transport-3.0.1.tgz#8008b15eef5660c4fb3fa094d58ccbd08528c58d" @@ -2655,11 +5503,30 @@ winston@^3.0.0-rc1: triple-beam "^1.0.1" winston-transport "^3.0.1" +wordwrap@0.0.2: + version "0.0.2" + resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.2.tgz#b79669bb42ecb409f83d583cad52ca17eaa1643f" + +wordwrap@~0.0.2: + version "0.0.3" + resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" + +wordwrap@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" + +wrap-ansi@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" + dependencies: + string-width "^1.0.1" + strip-ansi "^3.0.1" + wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" -write-file-atomic@^2.0.0: +write-file-atomic@^2.0.0, write-file-atomic@^2.1.0: version "2.3.0" resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-2.3.0.tgz#1ff61575c2e2a4e8e510d6fa4e243cce183999ab" dependencies: @@ -2667,26 +5534,72 @@ write-file-atomic@^2.0.0: imurmurhash "^0.1.4" signal-exit "^3.0.2" +write@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" + dependencies: + mkdirp "^0.5.1" + xdg-basedir@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/xdg-basedir/-/xdg-basedir-3.0.0.tgz#496b2cc109eca8dbacfe2dc72b603c17c5870ad4" +xml-name-validator@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-2.0.1.tgz#4d8b8f1eccd3419aa362061becef515e1e559635" + "xtend@>=4.0.0 <4.1.0-0", xtend@^4.0.0, xtend@~4.0.0, xtend@~4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af" +y18n@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.1.tgz#6d15fba884c08679c0d77e88e7759e811e07fa41" + yallist@^2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" -yauzl@^2.2.1: +yargs-parser@^8.1.0: + version "8.1.0" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-8.1.0.tgz#f1376a33b6629a5d063782944da732631e966950" + dependencies: + camelcase "^4.1.0" + +yargs@^10.0.3: + version "10.1.1" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-10.1.1.tgz#5fe1ea306985a099b33492001fa19a1e61efe285" + dependencies: + cliui "^4.0.0" + decamelize "^1.1.1" + find-up "^2.1.0" + get-caller-file "^1.0.1" + os-locale "^2.0.0" + require-directory "^2.1.1" + require-main-filename "^1.0.1" + set-blocking "^2.0.0" + string-width "^2.0.0" + which-module "^2.0.0" + y18n "^3.2.1" + yargs-parser "^8.1.0" + +yargs@~3.10.0: + version "3.10.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-3.10.0.tgz#f7ee7bd857dd7c1d2d38c0e74efbd681d1431fd1" + dependencies: + camelcase "^1.0.2" + cliui "^2.1.0" + decamelize "^1.0.0" + window-size "0.1.0" + +yauzl@^2.2.1, yauzl@^2.3.1: version "2.9.1" resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.9.1.tgz#a81981ea70a57946133883f029c5821a89359a7f" dependencies: buffer-crc32 "~0.2.3" fd-slicer "~1.0.1" -yazl@^2.2.1: +yazl@^2.2.1, yazl@^2.2.2: version "2.4.3" resolved "https://registry.yarnpkg.com/yazl/-/yazl-2.4.3.tgz#ec26e5cc87d5601b9df8432dbdd3cd2e5173a071" dependencies: