diff --git a/.eslintrc.json b/.eslintrc.json deleted file mode 100644 index 02509e2..0000000 --- a/.eslintrc.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "env": { - "browser": false, - "commonjs": true, - "es6": true, - "node": true - }, - "parserOptions": { - "ecmaFeatures": { - "jsx": true - }, - "sourceType": "module" - }, - "rules": { - "no-const-assign": "warn", - "no-this-before-super": "warn", - "no-undef": "warn", - "no-unreachable": "warn", - "no-unused-vars": "warn", - "constructor-super": "warn", - "valid-typeof": "warn" - } -} \ No newline at end of file diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..13bc9c2 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,3 @@ +# Set default behavior to automatically normalize line endings. +* text=auto + diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 0000000..82a3bcc --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -0,0 +1 @@ +It's recommend to file an issue via the build in tool of vscode witch you can access from `Help-> Report Issue`. diff --git a/.gitignore b/.gitignore index 3c3629e..5fe00fe 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,4 @@ +out node_modules +.vscode-test/ +*.vsix diff --git a/.travis.yml b/.travis.yml index dadba1e..ee389e3 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,6 +11,7 @@ install: before_script: - git config --global user.name 'wayou' - git config --global user.email 'liuwayong@gmail.com' + - git checkout next - rm -f *.vsix script: @@ -19,5 +20,5 @@ script: after_success: - git add -A . - git commit -m "[skip ci]vsix generated via travis-ci at $(date -u +'%Y-%m-%d %H:%M:%S') $TRAVIS_COMMIT" - - git push -q $GH_TOKEN HEAD:master + - git push origin next -q $GH_TOKEN HEAD:master diff --git a/.vscode/extensions.json b/.vscode/extensions.json index 0915202..ee71911 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -1,7 +1,7 @@ { - // See https://go.microsoft.com/fwlink/?LinkId=733558 + // See http://go.microsoft.com/fwlink/?LinkId=827846 // for the documentation about the extensions.json format "recommendations": [ - "dbaeumer.vscode-eslint" + "eg2.tslint" ] } \ No newline at end of file diff --git a/.vscode/launch.json b/.vscode/launch.json index 2131f2c..c174db3 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -1,22 +1,36 @@ -// A launch configuration that launches the extension inside a new window +// A launch configuration that compiles the extension and then opens it inside a new window +// Use IntelliSense to learn about possible attributes. +// Hover to view descriptions of existing attributes. +// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 { - "version": "0.1.0", + "version": "0.2.0", "configurations": [ { - "name": "Launch Extension", + "name": "Extension", "type": "extensionHost", "request": "launch", "runtimeExecutable": "${execPath}", - "args": ["--extensionDevelopmentPath=${workspaceRoot}" ], - "stopOnEntry": false + "args": [ + "--extensionDevelopmentPath=${workspaceFolder}" + ], + "outFiles": [ + "${workspaceFolder}/out/**/*.js" + ], + "preLaunchTask": "npm: watch" }, { - "name": "Launch Tests", + "name": "Extension Tests", "type": "extensionHost", "request": "launch", "runtimeExecutable": "${execPath}", - "args": ["--extensionDevelopmentPath=${workspaceRoot}", "--extensionTestsPath=${workspaceRoot}/test" ], - "stopOnEntry": false + "args": [ + "--extensionDevelopmentPath=${workspaceFolder}", + "--extensionTestsPath=${workspaceFolder}/out/test" + ], + "outFiles": [ + "${workspaceFolder}/out/test/**/*.js" + ], + "preLaunchTask": "npm: watch" } ] -} \ No newline at end of file +} diff --git a/.vscode/settings.json b/.vscode/settings.json index 7088cc8..30bf8c2 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,7 +1,11 @@ // Place your settings in this file to overwrite default and user settings. { - "typescript.tsdk": "./node_modules/typescript/lib", - "editor.formatOnPaste": true, - "editor.minimap.enabled": true, - "editor.snippetSuggestions": "top" // we want to use the TS server from our node_modules folder to control its version + "files.exclude": { + "out": false // set this to true to hide the "out" folder with the compiled JS files + }, + "search.exclude": { + "out": true // set this to false to include "out" folder in search results + }, + // Turn off tsc task auto detection since we have the necessary tasks as npm scripts + "typescript.tsc.autoDetect": "off" } \ No newline at end of file diff --git a/.vscode/tasks.json b/.vscode/tasks.json new file mode 100644 index 0000000..604e38f --- /dev/null +++ b/.vscode/tasks.json @@ -0,0 +1,20 @@ +// See https://go.microsoft.com/fwlink/?LinkId=733558 +// for the documentation about the tasks.json format +{ + "version": "2.0.0", + "tasks": [ + { + "type": "npm", + "script": "watch", + "problemMatcher": "$tsc-watch", + "isBackground": true, + "presentation": { + "reveal": "never" + }, + "group": { + "kind": "build", + "isDefault": true + } + } + ] +} \ No newline at end of file diff --git a/.vscodeignore b/.vscodeignore index 499648c..8557178 100644 --- a/.vscodeignore +++ b/.vscodeignore @@ -1,7 +1,9 @@ .vscode/** .vscode-test/** -test/** +out/test/** +out/**/*.map +src/** .gitignore -jsconfig.json +tsconfig.json vsc-extension-quickstart.md -.eslintrc.json +tslint.json \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 8cc18f0..27646c5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,19 @@ # Change Log +## 1.0.0 - 2018-07-21 +- [new] ability to theme every single regexp match, resolve #42, resolve #88 +- [new] `list annotations` now support multiple select +- [new] autocompletion for annotations based on the config +- [new] tons of predefined annotations: "AVOID:", "BUG:", "CAUTION:", "CONFIGURATION:", "DEBUG:", "DEPRECATED:", "DO_NOT_REMOVE:", "HACK:", "IMPORTANT:", "IMPROVE:", "INFO:", "ISSUE:", "KEEP:", "LEGACY:", "NOTE:", "OPTIMIZE:", "PERFORMANCE:", "PLACEHOLDER:", "PREFER:", "REFACTOR:", "REMOVE:", "REVIEW:", "RFC:", "TEMP:", "WARNING:", resolve #74 +- [new] include all file types by default, the extension will catch the exception when working with binary file. no manual configuration needed. +- [new] list annotations for current file only, fix #74 +- [new] predefined annotations `TODO:` and `FIXME:` now can be override, resolve #87 +- [fix] fix partial match problem. now the end user need to define what should be matched exactlly by custom every annotation with RegExp. resolve #48, resolve #63, resolve #102, resolve #106 +- [fix] by using the built-in `Uri` to get the path of a file, fix #81 +- [fix] update the doc and the reference link for styling the annotations, resolve #97 +- [improve] cancelation support is added as well some improvements for the file searching. possiblely resolve #55, resolve #59. for reason of vscode it's self, `workspace.openTextDocument` will trigger `onDidOpen` events and then other extensions may react with it. this is main reason for the high cpu. see vscode issues for more info: [#15723](https://github.com/Microsoft/vscode/issues/15723), [#33046](https://github.com/Microsoft/vscode/issues/33046) +- [chore] rewrite with TypeScript + ## 0.5.12 - 2018-03-16 - merge #77 - update doc for the refer for DecorationRenderOptions diff --git a/LICENSE.txt b/LICENSE similarity index 96% rename from LICENSE.txt rename to LICENSE index 7db1914..ab45d1f 100644 --- a/LICENSE.txt +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2017 Wayou Liu +Copyright (c) 2016-2018 Wayou Liu Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 156678d..cf26cb5 100644 --- a/README.md +++ b/README.md @@ -1,129 +1,204 @@ -VSCODE-TODO-HIGHLIGHT -=== - +vscode-todo-highlight README +--- [![License: MIT](https://img.shields.io/badge/License-MIT-brightgreen.svg)](https://opensource.org/licenses/MIT) [![Build Status](https://travis-ci.org/wayou/vscode-todo-highlight.svg?branch=master)](https://travis-ci.org/wayou/vscode-todo-highlight) [![Version](https://vsmarketplacebadge.apphb.com/version-short/wayou.vscode-todo-highlight.svg)](https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight) [![Installs](https://vsmarketplacebadge.apphb.com/installs-short/wayou.vscode-todo-highlight.svg)](https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight) [![Ratings](https://vsmarketplacebadge.apphb.com/rating-short/wayou.vscode-todo-highlight.svg)](https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight) -Highlight `TODO`, `FIXME` and other annotations within your code. +Highlight TODO, FIXME, or whatever annotations. + +## Preview + +- with dark theme +![screenshot with dark theme](./assets/screenshot_dark.png) + +- with light theme +![screenshot with light theme](./assets/screenshot_light.png) + + +## Features + +### Predefined Annotations + +Following annotations are out of the box: + +`AVOID:`, +`TODO:`, +`FIXME:`, +`BUG:`, +`CAUTION:`, +`CONFIGURATION:`, +`DEBUG:`, +`DEPRECATED:`, +`DO_NOT_REMOVE:`, +`HACK:`, +`IMPORTANT:`, +`IMPROVE:`, +`INFO:`, +`ISSUE:`, +`KEEP:`, +`LEGACY:`, +`NOTE:`, +`OPTIMIZE:`, +`PERFORMANCE:`, +`PLACEHOLDER:`, +`PREFER:`, +`REFACTOR:`, +`REMOVE:`, +`REVIEW:`, +`RFC:`, +`TEMP:`, +"WARNING:` -Sometimes you forget to review the TODOs you've added while coding before you publish the code to production. -So I've been wanting an extension for a long time that highlights them and reminds me that there are notes or things not done yet. -Hope this extension helps you as well. +### Code completion -*NOTICE* +Code completion for the annotations. -Many report that the `List highlighted annotations` command is not working, make sure you have the file types included via `todohighlight.include`. +[Code completion for the annotations](./assets/code_completion.gif) -### Preview +### Toggle highlight -- with `material night` color theme: -![](https://github.com/wayou/vscode-todo-highlight/raw/master/assets/material-night.png) +Enable/disable the highlight. -- with `material night eighties` color theme: -![](https://github.com/wayou/vscode-todo-highlight/raw/master/assets/material-night-eighties.png) +[toggle highlight](./assets/toggle_highlight.gif) -### Config -`TODO:`,`FIXME:` are built-in keywords. You can override the look by customizing the setting. +### List annotations -To customize the keywords and other stuff, command + , (Windows / Linux: File -> Preferences -> User Settings) open the vscode file `settings.json`. +Supports both for current file and the whole project. -| | type | default | description | -|---|---|---|---| -| todohighlight.isEnable | boolean | true | Toggle the highlight, default is true. | -| todohighlight.isCaseSensitive | boolean | true | Whether the keywords are case sensitive or not. | -| todohighlight.keywords | array | N/A | An array of keywords that will be hilighted. You can also specify the style for each keywords here. See example below for more infomation. | -| todohighlight.keywordsPattern | string | N/A | Specify keywords via RegExp instead of `todohighlight.keywords` one by one. NOTE that if this presents, `todohighlight.keywords` will be ignored. And REMEMBER to escapse the back slash if there's any in your regexp (using \\ instead of signle back slash). | -| todohighlight.defaultStyle | object | N/A | Specify the default style for custom keywords, if not specified, build in default style will be applied. [See all available properties on VSCode doc DecorationRenderOptions section](https://code.visualstudio.com/docs/extensionAPI/vscode-api) | -| todohighlight.include | array | [
`"**/*.js"`,
`"**/*.jsx"`,
`"**/*.ts"`,
`"**/*.tsx",`
`"**/*.html"`,
`"**/*.php"`,
`"**/*.css",`
`"**/*.scss"`
] | Glob patterns that defines the files to search for. Only include files you need, DO NOT USE `{**/*.*}` for both permormance and avoiding binary files reason.
For backwards compatability, a string combine all the patterns is also valid `"{**/*.js,**/*.jsx,**/*.ts,**/*.tsx,**/*.html,**/*.php,**/*.css,**/*.scss}"` | -| todohighlight.exclude | array | [
`"**/node_modules/**"`,
`"**/dist/**",`
`"**/bower_components/**"`,
`"**/build/**",`
`"**/.vscode/**"`,
`"**/.github/**"`,
`"**/_output/**"`,
`"**/*.min.*"`,
`"**/*.map"`
] | Glob pattern that defines files and folders to exclude while listing annotations.
For backwards compatability, a string combine all the patterns is also valid `"{**/node_modules/**,**/bower_components/**,**/dist/**,**/build/**,**/.vscode/**,**/_output/**,**/*.min.*,**/*.map}"` | -| todohighlight.maxFilesForSearch | number | 5120 | Max files for searching, mostly you don't need to configure this. | -| todohighlight.toggleURI | boolean | false | If the file path within the output channel not clickable, set this to true to toggle the path patten between `#` and `::`. | +[list annotations](./assets/list_annotations.gif) -an example of customizing configuration: +## Extension Settings +This extension contributes the following settings: + +- `todohighlight.isEnable`: enable/disable this extension + - type: boolean + - default: `true` +- `todohighlight.isCaseSensitive`: whether the keywords are case sensitive or not. + - type: boolean + - default: `false` +- `todohighlight.toggleURI`: if the file uri within the output channel is not clickable, set this to true to toggle the uri patten between `#` and `::` + - type: boolean + - default: `false` +- `todohighlight.keywords`: annotations that will be highlighted. The pattern is plain string or escaped RegExp string. e.g. `TODO:`, `\\\\bTODO\\\\b`. + - type: Array + - default: ```js +[{ + pattern: "TODO:", + style: { + dark: { + color: "#757575" + }, + light: { + color: "#fff" + }, + backgroundColor: "#ffbd2a", + borderRadius: "2px", + border: "1px solid red" + }, + description: "Things need to be done later." +}, { - "todohighlight.isEnable": true, - "todohighlight.isCaseSensitive": true, - "todohighlight.keywords": [ - "DEBUG:", - "REVIEW:", - { - "text": "NOTE:", - "color": "#ff0000", - "backgroundColor": "yellow", - "overviewRulerColor": "grey" - }, - { - "text": "HACK:", - "color": "#000", - "isWholeLine": false, - }, - { - "text": "TODO:", - "color": "red", - "border": "1px solid red", - "borderRadius": "2px", //NOTE: using borderRadius along with `border` or you will see nothing change - "backgroundColor": "rgba(0,0,0,.2)", - //other styling properties goes here ... - } - ], - "todohighlight.keywordsPattern": "TODO:|FIXME:|\\(([^)]+)\\)", //highlight `TODO:`,`FIXME:` or content between parentheses - "todohighlight.defaultStyle": { - "color": "red", - "backgroundColor": "#ffab00", - "overviewRulerColor": "#ffab00", - "cursor": "pointer", - "border": "1px solid #eee", - "borderRadius": "2px", - "isWholeLine": true, - //other styling properties goes here ... + pattern: "FIXME:", + style: { + dark: { + color: "#eee" + }, + light: { + color: "#fff" }, - "todohighlight.include": [ - "**/*.js", - "**/*.jsx", - "**/*.ts", - "**/*.tsx", - "**/*.html", - "**/*.php", - "**/*.css", - "**/*.scss" - ], - "todohighlight.exclude": [ - "**/node_modules/**", - "**/bower_components/**", - "**/dist/**", - "**/build/**", - "**/.vscode/**", - "**/.github/**", - "**/_output/**", - "**/*.min.*", - "**/*.map", - "**/.next/**" - ], - "todohighlight.maxFilesForSearch": 5120, - "todohighlight.toggleURI": false + backgroundColor: "#f06292", + borderRadius: "2px", + border: "1px solid red" + }, + description: "Things need to be fixed." +}, +"AVOID:", +"BUG:", +"CAUTION:", +"CONFIGURATION:", +"DEBUG:", +"DEPRECATED:", +"DO_NOT_REMOVE:", +"HACK:", +"IMPORTANT:", +"IMPROVE:", +"INFO:", +"ISSUE:", +"KEEP:", +"LEGACY:", +"NOTE:", +"OPTIMIZE:", +"PERFORMANCE:", +"PLACEHOLDER:", +"PREFER:", +"REFACTOR:", +"REMOVE:", +"REVIEW:", +"RFC:", +"TEMP:", +"WARNING:" +] +``` +- `todohighlight.defaultStyle`: default style applied to the annotations. Reference the VS Code extension API to see all available properties https://code.visualstudio.com/docs/extensionAPI/vscode-api#DecorationRenderOptions . + - type: [DecorationRenderOptions](https://code.visualstudio.com/docs/extensionAPI/vscode-api#DecorationRenderOptions) + - default: +```js +{ + "color": "#2196f3", + "backgroundColor": "#fffd38" } ``` - -### Commands - -This extension contributes the following commands to the Command palette. - -- `Toggle highlight` : turn on/off the highlight -![](https://github.com/wayou/vscode-todo-highlight/raw/master/assets/toggle-highlight.gif) -- `List highlighted annotations` : list annotations and reveal from corresponding file -![](https://github.com/wayou/vscode-todo-highlight/raw/master/assets/list-annotations.gif) +- `myExtension.include`: a set of glob patterns that defines the files to search for. Each of the item is a glob pattern to include the files while searching for annotations. e.g. `**/*.jsx`. + - type: string[] + - default: `["**/*"]` +- `myExtension.exclude`: a set of glob patterns that exclude files or directories while searching annotations. Each of the item is a glob pattern to include the files while searching for annotations. e.g. `**/*.jsx` + - type: string[] + - default: `["**/*"]` +```js +[ + "**/.next/**", + "**/.vscode/**", + "**/*.map", + "**/*.min.*", + "**/bower_components/**", + "**/dist/**", + "**/node_modules/**" +] +``` -### Known issue +## Known Issues +### File uri in the output channel The clickable file pattern within the output channel differs from OS platform(`#` for Mac/Windows and `::` for Linux, for details see this [issue](https://github.com/Microsoft/vscode/issues/586) ). Basically the extension auto detects the OS platform. If you find that the file path is not clickable, set `todohighlight.toggleURI` to `true` to toggle the file pattern. + +### Avoid unwanted partial highlight + +Word boundary detect. The hard part is `\b` only work with a [predefined chracter collection](http://www.ecma-international.org/ecma-262/5.1/#sec-15.10.2.6). That means, `\\bTODO:\\b` just won't work as ecpected.As for at present I can not do the boundray detect within the extension internal for the annotaions from user config. The good news is that with todohighlight v1 all patterns are defined with RegExp, so you can decide what is your doundary to match and meet your own requirments. For example, `\\bBUG:` match exactlly `BUG:` and skip `DEBUG:`. Related issues #48. + + +### Code completion not working in comment + +Currently the code completion cannot working in comment. You can first type the annotations out then comment it out. + + +## Release Notes + +See [CHANGELOG](./CHANGELOG.md). + + +## Misc + +- For bugs report and feature request, file an issue on [Github](https://github.com/wayou/vscode-todo-highlight/issues) + + +**Enjoy!** diff --git a/assets/code_completion.gif b/assets/code_completion.gif new file mode 100644 index 0000000..f81af36 Binary files /dev/null and b/assets/code_completion.gif differ diff --git a/assets/list-annotations.gif b/assets/list-annotations.gif deleted file mode 100644 index 5eafb7c..0000000 Binary files a/assets/list-annotations.gif and /dev/null differ diff --git a/assets/list_annotations.gif b/assets/list_annotations.gif new file mode 100644 index 0000000..ce2a4bd Binary files /dev/null and b/assets/list_annotations.gif differ diff --git a/assets/material-night-eighties.png b/assets/material-night-eighties.png deleted file mode 100644 index 3738175..0000000 Binary files a/assets/material-night-eighties.png and /dev/null differ diff --git a/assets/material-night.png b/assets/material-night.png deleted file mode 100644 index c28d881..0000000 Binary files a/assets/material-night.png and /dev/null differ diff --git a/assets/screenshot_dark.png b/assets/screenshot_dark.png new file mode 100644 index 0000000..4cf0a04 Binary files /dev/null and b/assets/screenshot_dark.png differ diff --git a/assets/screenshot_light.png b/assets/screenshot_light.png new file mode 100644 index 0000000..86cf8fc Binary files /dev/null and b/assets/screenshot_light.png differ diff --git a/assets/toggle-highlight.gif b/assets/toggle-highlight.gif deleted file mode 100644 index c6d242b..0000000 Binary files a/assets/toggle-highlight.gif and /dev/null differ diff --git a/assets/toggle_highlight.gif b/assets/toggle_highlight.gif new file mode 100644 index 0000000..240aeb5 Binary files /dev/null and b/assets/toggle_highlight.gif differ diff --git a/jsconfig.json b/jsconfig.json deleted file mode 100644 index 4343fa7..0000000 --- a/jsconfig.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "compilerOptions": { - "module": "commonjs", - "target": "es6", - "lib": [ - "es6" - ] - }, - "exclude": [ - "node_modules" - ] -} diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..425efaf --- /dev/null +++ b/package-lock.json @@ -0,0 +1,2260 @@ +{ + "name": "vscode-todo-highlight", + "version": "1.0.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@types/mocha": { + "version": "2.2.48", + "resolved": "http://registry.npm.taobao.org/@types/mocha/download/@types/mocha-2.2.48.tgz", + "integrity": "sha1-NSOxJqCwSUguHDwRh3Rg92Yi/6s=", + "dev": true + }, + "@types/node": { + "version": "7.0.66", + "resolved": "http://registry.npm.taobao.org/@types/node/download/@types/node-7.0.66.tgz", + "integrity": "sha1-PR3E1vUuSE6EOAb/RWN59+atVVM=", + "dev": true + }, + "ajv": { + "version": "5.5.2", + "resolved": "http://registry.npm.taobao.org/ajv/download/ajv-5.5.2.tgz", + "integrity": "sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU=", + "dev": true, + "requires": { + "co": "^4.6.0", + "fast-deep-equal": "^1.0.0", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.3.0" + } + }, + "ansi-cyan": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/ansi-cyan/download/ansi-cyan-0.1.1.tgz", + "integrity": "sha1-U4rlKK+JgvKK4w2G8vF0VtJgmHM=", + "dev": true, + "requires": { + "ansi-wrap": "0.1.0" + } + }, + "ansi-red": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/ansi-red/download/ansi-red-0.1.1.tgz", + "integrity": "sha1-jGOPnRCAgAo1PJwoyKgcpHBdlGw=", + "dev": true, + "requires": { + "ansi-wrap": "0.1.0" + } + }, + "ansi-regex": { + "version": "2.1.1", + "resolved": "http://registry.npm.taobao.org/ansi-regex/download/ansi-regex-2.1.1.tgz", + "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", + "dev": true + }, + "ansi-styles": { + "version": "2.2.1", + "resolved": "http://registry.npm.taobao.org/ansi-styles/download/ansi-styles-2.2.1.tgz", + "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=", + "dev": true + }, + "ansi-wrap": { + "version": "0.1.0", + "resolved": "http://registry.npm.taobao.org/ansi-wrap/download/ansi-wrap-0.1.0.tgz", + "integrity": "sha1-qCJQ3bABXponyoLoLqYDu/pF768=", + "dev": true + }, + "argparse": { + "version": "1.0.10", + "resolved": "http://registry.npm.taobao.org/argparse/download/argparse-1.0.10.tgz", + "integrity": "sha1-vNZ5HqWuCXJeF+WtmIE0zUCz2RE=", + "dev": true, + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "arr-diff": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/arr-diff/download/arr-diff-1.1.0.tgz", + "integrity": "sha1-aHwydYFjWI/vfeezb6vklesaOZo=", + "dev": true, + "requires": { + "arr-flatten": "^1.0.1", + "array-slice": "^0.2.3" + } + }, + "arr-flatten": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/arr-flatten/download/arr-flatten-1.1.0.tgz", + "integrity": "sha1-NgSLv/TntH4TZkQxbJlmnqWukfE=", + "dev": true + }, + "arr-union": { + "version": "2.1.0", + "resolved": "http://registry.npm.taobao.org/arr-union/download/arr-union-2.1.0.tgz", + "integrity": "sha1-IPnqtexw9cfSFbEHexw5Fh0pLH0=", + "dev": true + }, + "array-differ": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/array-differ/download/array-differ-1.0.0.tgz", + "integrity": "sha1-7/UuN1gknTO+QCuLuOVkuytdQDE=", + "dev": true + }, + "array-slice": { + "version": "0.2.3", + "resolved": "http://registry.npm.taobao.org/array-slice/download/array-slice-0.2.3.tgz", + "integrity": "sha1-3Tz7gO15c6dRF82sabC5nshhhvU=", + "dev": true + }, + "array-union": { + "version": "1.0.2", + "resolved": "http://registry.npm.taobao.org/array-union/download/array-union-1.0.2.tgz", + "integrity": "sha1-mjRBDk9OPaI96jdb5b5w8kd47Dk=", + "dev": true, + "requires": { + "array-uniq": "^1.0.1" + } + }, + "array-uniq": { + "version": "1.0.3", + "resolved": "http://registry.npm.taobao.org/array-uniq/download/array-uniq-1.0.3.tgz", + "integrity": "sha1-r2rId6Jcx/dOBYiUdThY39sk/bY=", + "dev": true + }, + "array-unique": { + "version": "0.2.1", + "resolved": "http://registry.npm.taobao.org/array-unique/download/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=", + "dev": true + }, + "arrify": { + "version": "1.0.1", + "resolved": "http://registry.npm.taobao.org/arrify/download/arrify-1.0.1.tgz", + "integrity": "sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0=", + "dev": true + }, + "asn1": { + "version": "0.2.3", + "resolved": "http://registry.npm.taobao.org/asn1/download/asn1-0.2.3.tgz", + "integrity": "sha1-2sh4dxPJlmhJ/IGAd36+nB3fO4Y=", + "dev": true + }, + "assert-plus": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/assert-plus/download/assert-plus-1.0.0.tgz", + "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", + "dev": true + }, + "asynckit": { + "version": "0.4.0", + "resolved": "http://registry.npm.taobao.org/asynckit/download/asynckit-0.4.0.tgz", + "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", + "dev": true + }, + "aws-sign2": { + "version": "0.7.0", + "resolved": "http://registry.npm.taobao.org/aws-sign2/download/aws-sign2-0.7.0.tgz", + "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=", + "dev": true + }, + "aws4": { + "version": "1.7.0", + "resolved": "http://registry.npm.taobao.org/aws4/download/aws4-1.7.0.tgz", + "integrity": "sha1-1NDpudv8p3vwjusKikcVUP454ok=", + "dev": true + }, + "babel-code-frame": { + "version": "6.26.0", + "resolved": "http://registry.npm.taobao.org/babel-code-frame/download/babel-code-frame-6.26.0.tgz", + "integrity": "sha1-Y/1D99weO7fONZR9uP42mj9Yx0s=", + "dev": true, + "requires": { + "chalk": "^1.1.3", + "esutils": "^2.0.2", + "js-tokens": "^3.0.2" + }, + "dependencies": { + "chalk": { + "version": "1.1.3", + "resolved": "http://registry.npm.taobao.org/chalk/download/chalk-1.1.3.tgz", + "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", + "dev": true, + "requires": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + } + } + } + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/balanced-match/download/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "bcrypt-pbkdf": { + "version": "1.0.2", + "resolved": "http://registry.npm.taobao.org/bcrypt-pbkdf/download/bcrypt-pbkdf-1.0.2.tgz", + "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", + "dev": true, + "optional": true, + "requires": { + "tweetnacl": "^0.14.3" + } + }, + "block-stream": { + "version": "0.0.9", + "resolved": "http://registry.npm.taobao.org/block-stream/download/block-stream-0.0.9.tgz", + "integrity": "sha1-E+v+d4oDIFz+A3UUgeu0szAMEmo=", + "dev": true, + "requires": { + "inherits": "~2.0.0" + } + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "http://registry.npm.taobao.org/brace-expansion/download/brace-expansion-1.1.11.tgz", + "integrity": "sha1-PH/L9SnYcibz0vUrlm/1Jx60Qd0=", + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "1.8.5", + "resolved": "http://registry.npm.taobao.org/braces/download/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "dev": true, + "requires": { + "expand-range": "^1.8.1", + "preserve": "^0.2.0", + "repeat-element": "^1.1.2" + } + }, + "browser-stdout": { + "version": "1.3.0", + "resolved": "http://registry.npm.taobao.org/browser-stdout/download/browser-stdout-1.3.0.tgz", + "integrity": "sha1-81HTKWnTL6XXpVZxVCY9korjvR8=", + "dev": true + }, + "buffer-crc32": { + "version": "0.2.13", + "resolved": "http://registry.npm.taobao.org/buffer-crc32/download/buffer-crc32-0.2.13.tgz", + "integrity": "sha1-DTM+PwDqxQqhRUq9MO+MKl2ackI=", + "dev": true + }, + "buffer-from": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/buffer-from/download/buffer-from-1.1.0.tgz", + "integrity": "sha1-h/yqOimDWOCt5uRCz86EB0DRrQQ=", + "dev": true + }, + "builtin-modules": { + "version": "1.1.1", + "resolved": "http://registry.npm.taobao.org/builtin-modules/download/builtin-modules-1.1.1.tgz", + "integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8=", + "dev": true + }, + "caseless": { + "version": "0.12.0", + "resolved": "http://registry.npm.taobao.org/caseless/download/caseless-0.12.0.tgz", + "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", + "dev": true + }, + "chalk": { + "version": "2.4.1", + "resolved": "http://registry.npm.taobao.org/chalk/download/chalk-2.4.1.tgz", + "integrity": "sha1-GMSasWoDe26wFSzIPjRxM4IVtm4=", + "dev": true, + "requires": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "http://registry.npm.taobao.org/ansi-styles/download/ansi-styles-3.2.1.tgz", + "integrity": "sha1-QfuyAkPlCxK+DwS43tvwdSDOhB0=", + "dev": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "http://registry.npm.taobao.org/supports-color/download/supports-color-5.4.0.tgz", + "integrity": "sha1-HGszdALCE3YF7+GfEP7DkPb6q1Q=", + "dev": true, + "requires": { + "has-flag": "^3.0.0" + } + } + } + }, + "clone": { + "version": "0.2.0", + "resolved": "http://registry.npm.taobao.org/clone/download/clone-0.2.0.tgz", + "integrity": "sha1-xhJqkK1Pctv1rNskPMN3JP6T/B8=", + "dev": true + }, + "clone-buffer": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/clone-buffer/download/clone-buffer-1.0.0.tgz", + "integrity": "sha1-4+JbIHrE5wGvch4staFnksrD3Fg=", + "dev": true + }, + "clone-stats": { + "version": "0.0.1", + "resolved": "http://registry.npm.taobao.org/clone-stats/download/clone-stats-0.0.1.tgz", + "integrity": "sha1-uI+UqCzzi4eR1YBG6kAprYjKmdE=", + "dev": true + }, + "cloneable-readable": { + "version": "1.1.2", + "resolved": "http://registry.npm.taobao.org/cloneable-readable/download/cloneable-readable-1.1.2.tgz", + "integrity": "sha1-1ZHe5Kj4vBXaQ86X3O66E9Q+KmU=", + "dev": true, + "requires": { + "inherits": "^2.0.1", + "process-nextick-args": "^2.0.0", + "readable-stream": "^2.3.5" + } + }, + "co": { + "version": "4.6.0", + "resolved": "http://registry.npm.taobao.org/co/download/co-4.6.0.tgz", + "integrity": "sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ=", + "dev": true + }, + "color-convert": { + "version": "1.9.2", + "resolved": "http://registry.npm.taobao.org/color-convert/download/color-convert-1.9.2.tgz", + "integrity": "sha1-SYgbj7pn3xKpa98/VsCqueeRMUc=", + "dev": true, + "requires": { + "color-name": "1.1.1" + } + }, + "color-name": { + "version": "1.1.1", + "resolved": "http://registry.npm.taobao.org/color-name/download/color-name-1.1.1.tgz", + "integrity": "sha1-SxQVMEz1ACjqgWQ2Q72C6gWANok=", + "dev": true + }, + "combined-stream": { + "version": "1.0.6", + "resolved": "http://registry.npm.taobao.org/combined-stream/download/combined-stream-1.0.6.tgz", + "integrity": "sha1-cj599ugBrFYTETp+RFqbactjKBg=", + "dev": true, + "requires": { + "delayed-stream": "~1.0.0" + } + }, + "commander": { + "version": "2.16.0", + "resolved": "http://registry.npm.taobao.org/commander/download/commander-2.16.0.tgz", + "integrity": "sha1-8WOQWTmWzrTz7rAgsx14Uo9/ilA=", + "dev": true + }, + "concat-map": { + "version": "0.0.1", + "resolved": "http://registry.npm.taobao.org/concat-map/download/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "convert-source-map": { + "version": "1.5.1", + "resolved": "http://registry.npm.taobao.org/convert-source-map/download/convert-source-map-1.5.1.tgz", + "integrity": "sha1-uCeAl7m8IpNl3lxiz1/K7YtVmeU=", + "dev": true + }, + "core-util-is": { + "version": "1.0.2", + "resolved": "http://registry.npm.taobao.org/core-util-is/download/core-util-is-1.0.2.tgz", + "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", + "dev": true + }, + "dashdash": { + "version": "1.14.1", + "resolved": "http://registry.npm.taobao.org/dashdash/download/dashdash-1.14.1.tgz", + "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", + "dev": true, + "requires": { + "assert-plus": "^1.0.0" + } + }, + "debug": { + "version": "3.1.0", + "resolved": "http://registry.npm.taobao.org/debug/download/debug-3.1.0.tgz", + "integrity": "sha1-W7WgZyYotkFJVmuhaBnmFRjGcmE=", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "deep-assign": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/deep-assign/download/deep-assign-1.0.0.tgz", + "integrity": "sha1-sJJ0O+hCfcYh6gBnzex+cN0Z83s=", + "dev": true, + "requires": { + "is-obj": "^1.0.0" + } + }, + "delayed-stream": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/delayed-stream/download/delayed-stream-1.0.0.tgz", + "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", + "dev": true + }, + "diff": { + "version": "3.5.0", + "resolved": "http://registry.npm.taobao.org/diff/download/diff-3.5.0.tgz", + "integrity": "sha1-gAwN0eCov7yVg1wgKtIg/jF+WhI=", + "dev": true + }, + "duplexer": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/duplexer/download/duplexer-0.1.1.tgz", + "integrity": "sha1-rOb/gIwc5mtX0ev5eXessCM0z8E=", + "dev": true + }, + "duplexify": { + "version": "3.6.0", + "resolved": "http://registry.npm.taobao.org/duplexify/download/duplexify-3.6.0.tgz", + "integrity": "sha1-WSkD9dgLONA3IgVBJk1poZj7NBA=", + "dev": true, + "requires": { + "end-of-stream": "^1.0.0", + "inherits": "^2.0.1", + "readable-stream": "^2.0.0", + "stream-shift": "^1.0.0" + } + }, + "ecc-jsbn": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/ecc-jsbn/download/ecc-jsbn-0.1.1.tgz", + "integrity": "sha1-D8c6ntXw1Tw4GTOYUj735UN3dQU=", + "dev": true, + "optional": true, + "requires": { + "jsbn": "~0.1.0" + } + }, + "end-of-stream": { + "version": "1.4.1", + "resolved": "http://registry.npm.taobao.org/end-of-stream/download/end-of-stream-1.4.1.tgz", + "integrity": "sha1-7SljTRm6ukY7bOa4CjchPqtx7EM=", + "dev": true, + "requires": { + "once": "^1.4.0" + } + }, + "escape-string-regexp": { + "version": "1.0.5", + "resolved": "http://registry.npm.taobao.org/escape-string-regexp/download/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", + "dev": true + }, + "esprima": { + "version": "4.0.0", + "resolved": "http://registry.npm.taobao.org/esprima/download/esprima-4.0.0.tgz", + "integrity": "sha1-RJnt3NERDgshi6zy+n9/WfVcqAQ=", + "dev": true + }, + "esutils": { + "version": "2.0.2", + "resolved": "http://registry.npm.taobao.org/esutils/download/esutils-2.0.2.tgz", + "integrity": "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=", + "dev": true + }, + "event-stream": { + "version": "3.3.4", + "resolved": "http://registry.npm.taobao.org/event-stream/download/event-stream-3.3.4.tgz", + "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", + "dev": true, + "requires": { + "duplexer": "~0.1.1", + "from": "~0", + "map-stream": "~0.1.0", + "pause-stream": "0.0.11", + "split": "0.3", + "stream-combiner": "~0.0.4", + "through": "~2.3.1" + } + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "http://registry.npm.taobao.org/expand-brackets/download/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "dev": true, + "requires": { + "is-posix-bracket": "^0.1.0" + } + }, + "expand-range": { + "version": "1.8.2", + "resolved": "http://registry.npm.taobao.org/expand-range/download/expand-range-1.8.2.tgz", + "integrity": "sha1-opnv/TNf4nIeuujiV+x5ZE/IUzc=", + "dev": true, + "requires": { + "fill-range": "^2.1.0" + } + }, + "extend": { + "version": "3.0.1", + "resolved": "http://registry.npm.taobao.org/extend/download/extend-3.0.1.tgz", + "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=", + "dev": true + }, + "extend-shallow": { + "version": "1.1.4", + "resolved": "http://registry.npm.taobao.org/extend-shallow/download/extend-shallow-1.1.4.tgz", + "integrity": "sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE=", + "dev": true, + "requires": { + "kind-of": "^1.1.0" + } + }, + "extglob": { + "version": "0.3.2", + "resolved": "http://registry.npm.taobao.org/extglob/download/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "dev": true, + "requires": { + "is-extglob": "^1.0.0" + }, + "dependencies": { + "is-extglob": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/is-extglob/download/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + } + } + }, + "extsprintf": { + "version": "1.3.0", + "resolved": "http://registry.npm.taobao.org/extsprintf/download/extsprintf-1.3.0.tgz", + "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=", + "dev": true + }, + "fast-deep-equal": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/fast-deep-equal/download/fast-deep-equal-1.1.0.tgz", + "integrity": "sha1-wFNHeBfIa1HaqFPIHgWbcz0CNhQ=", + "dev": true + }, + "fast-json-stable-stringify": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/fast-json-stable-stringify/download/fast-json-stable-stringify-2.0.0.tgz", + "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=", + "dev": true + }, + "fd-slicer": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/fd-slicer/download/fd-slicer-1.1.0.tgz", + "integrity": "sha1-JcfInLH5B3+IkbvmHY85Dq4lbx4=", + "dev": true, + "requires": { + "pend": "~1.2.0" + } + }, + "filename-regex": { + "version": "2.0.1", + "resolved": "http://registry.npm.taobao.org/filename-regex/download/filename-regex-2.0.1.tgz", + "integrity": "sha1-wcS5vuPglyXdsQa3XB4wH+LxiyY=", + "dev": true + }, + "fill-range": { + "version": "2.2.4", + "resolved": "http://registry.npm.taobao.org/fill-range/download/fill-range-2.2.4.tgz", + "integrity": "sha1-6x53OrsFbc2N8r/favWbizqTZWU=", + "dev": true, + "requires": { + "is-number": "^2.1.0", + "isobject": "^2.0.0", + "randomatic": "^3.0.0", + "repeat-element": "^1.1.2", + "repeat-string": "^1.5.2" + } + }, + "first-chunk-stream": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/first-chunk-stream/download/first-chunk-stream-1.0.0.tgz", + "integrity": "sha1-Wb+1DNkF9g18OUzT2ayqtOatk04=", + "dev": true + }, + "for-in": { + "version": "1.0.2", + "resolved": "http://registry.npm.taobao.org/for-in/download/for-in-1.0.2.tgz", + "integrity": "sha1-gQaNKVqBQuwKxybG4iAMMPttXoA=", + "dev": true + }, + "for-own": { + "version": "0.1.5", + "resolved": "http://registry.npm.taobao.org/for-own/download/for-own-0.1.5.tgz", + "integrity": "sha1-UmXGgaTylNq78XyVCbZ2OqhFEM4=", + "dev": true, + "requires": { + "for-in": "^1.0.1" + } + }, + "forever-agent": { + "version": "0.6.1", + "resolved": "http://registry.npm.taobao.org/forever-agent/download/forever-agent-0.6.1.tgz", + "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=", + "dev": true + }, + "form-data": { + "version": "2.3.2", + "resolved": "http://registry.npm.taobao.org/form-data/download/form-data-2.3.2.tgz", + "integrity": "sha1-SXBJi+YEwgwAXU9cI67NIda0kJk=", + "dev": true, + "requires": { + "asynckit": "^0.4.0", + "combined-stream": "1.0.6", + "mime-types": "^2.1.12" + } + }, + "from": { + "version": "0.1.7", + "resolved": "http://registry.npm.taobao.org/from/download/from-0.1.7.tgz", + "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=", + "dev": true + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/fs.realpath/download/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "fstream": { + "version": "1.0.11", + "resolved": "http://registry.npm.taobao.org/fstream/download/fstream-1.0.11.tgz", + "integrity": "sha1-XB+x8RdHcRTwYyoOtLcbPLD9MXE=", + "dev": true, + "requires": { + "graceful-fs": "^4.1.2", + "inherits": "~2.0.0", + "mkdirp": ">=0.5 0", + "rimraf": "2" + } + }, + "getpass": { + "version": "0.1.7", + "resolved": "http://registry.npm.taobao.org/getpass/download/getpass-0.1.7.tgz", + "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", + "dev": true, + "requires": { + "assert-plus": "^1.0.0" + } + }, + "glob": { + "version": "7.1.2", + "resolved": "http://registry.npm.taobao.org/glob/download/glob-7.1.2.tgz", + "integrity": "sha1-wZyd+aAocC1nhhI4SmVSQExjbRU=", + "dev": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "glob-base": { + "version": "0.3.0", + "resolved": "http://registry.npm.taobao.org/glob-base/download/glob-base-0.3.0.tgz", + "integrity": "sha1-27Fk9iIbHAscz4Kuoyi0l98Oo8Q=", + "dev": true, + "requires": { + "glob-parent": "^2.0.0", + "is-glob": "^2.0.0" + }, + "dependencies": { + "glob-parent": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/glob-parent/download/glob-parent-2.0.0.tgz", + "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", + "dev": true, + "requires": { + "is-glob": "^2.0.0" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/is-extglob/download/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + }, + "is-glob": { + "version": "2.0.1", + "resolved": "http://registry.npm.taobao.org/is-glob/download/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "dev": true, + "requires": { + "is-extglob": "^1.0.0" + } + } + } + }, + "glob-parent": { + "version": "3.1.0", + "resolved": "http://registry.npm.taobao.org/glob-parent/download/glob-parent-3.1.0.tgz", + "integrity": "sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4=", + "dev": true, + "requires": { + "is-glob": "^3.1.0", + "path-dirname": "^1.0.0" + } + }, + "glob-stream": { + "version": "5.3.5", + "resolved": "http://registry.npm.taobao.org/glob-stream/download/glob-stream-5.3.5.tgz", + "integrity": "sha1-pVZlqajM3EGRWofHAeMtTgFvrSI=", + "dev": true, + "requires": { + "extend": "^3.0.0", + "glob": "^5.0.3", + "glob-parent": "^3.0.0", + "micromatch": "^2.3.7", + "ordered-read-streams": "^0.3.0", + "through2": "^0.6.0", + "to-absolute-glob": "^0.1.1", + "unique-stream": "^2.0.2" + }, + "dependencies": { + "glob": { + "version": "5.0.15", + "resolved": "http://registry.npm.taobao.org/glob/download/glob-5.0.15.tgz", + "integrity": "sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E=", + "dev": true, + "requires": { + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "2 || 3", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "isarray": { + "version": "0.0.1", + "resolved": "http://registry.npm.taobao.org/isarray/download/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", + "dev": true + }, + "readable-stream": { + "version": "1.0.34", + "resolved": "http://registry.npm.taobao.org/readable-stream/download/readable-stream-1.0.34.tgz", + "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", + "dev": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "0.0.1", + "string_decoder": "~0.10.x" + } + }, + "string_decoder": { + "version": "0.10.31", + "resolved": "http://registry.npm.taobao.org/string_decoder/download/string_decoder-0.10.31.tgz", + "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", + "dev": true + }, + "through2": { + "version": "0.6.5", + "resolved": "http://registry.npm.taobao.org/through2/download/through2-0.6.5.tgz", + "integrity": "sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg=", + "dev": true, + "requires": { + "readable-stream": ">=1.0.33-1 <1.1.0-0", + "xtend": ">=4.0.0 <4.1.0-0" + } + } + } + }, + "graceful-fs": { + "version": "4.1.11", + "resolved": "http://registry.npm.taobao.org/graceful-fs/download/graceful-fs-4.1.11.tgz", + "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=", + "dev": true + }, + "growl": { + "version": "1.10.3", + "resolved": "http://registry.npm.taobao.org/growl/download/growl-1.10.3.tgz", + "integrity": "sha1-GSa6kM8+3+KttJJ/WIC8IsZseQ8=", + "dev": true + }, + "gulp-chmod": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/gulp-chmod/download/gulp-chmod-2.0.0.tgz", + "integrity": "sha1-AMOQuSigeZslGsz2MaoJ4BzGKZw=", + "dev": true, + "requires": { + "deep-assign": "^1.0.0", + "stat-mode": "^0.2.0", + "through2": "^2.0.0" + } + }, + "gulp-filter": { + "version": "5.1.0", + "resolved": "http://registry.npm.taobao.org/gulp-filter/download/gulp-filter-5.1.0.tgz", + "integrity": "sha1-oF4Rr/sHz33PQafeHLe2OsN4PnM=", + "dev": true, + "requires": { + "multimatch": "^2.0.0", + "plugin-error": "^0.1.2", + "streamfilter": "^1.0.5" + } + }, + "gulp-gunzip": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/gulp-gunzip/download/gulp-gunzip-1.0.0.tgz", + "integrity": "sha1-FbdBFF6Dqcb1CIYkG1fMWHHxUak=", + "dev": true, + "requires": { + "through2": "~0.6.5", + "vinyl": "~0.4.6" + }, + "dependencies": { + "isarray": { + "version": "0.0.1", + "resolved": "http://registry.npm.taobao.org/isarray/download/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", + "dev": true + }, + "readable-stream": { + "version": "1.0.34", + "resolved": "http://registry.npm.taobao.org/readable-stream/download/readable-stream-1.0.34.tgz", + "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", + "dev": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "0.0.1", + "string_decoder": "~0.10.x" + } + }, + "string_decoder": { + "version": "0.10.31", + "resolved": "http://registry.npm.taobao.org/string_decoder/download/string_decoder-0.10.31.tgz", + "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", + "dev": true + }, + "through2": { + "version": "0.6.5", + "resolved": "http://registry.npm.taobao.org/through2/download/through2-0.6.5.tgz", + "integrity": "sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg=", + "dev": true, + "requires": { + "readable-stream": ">=1.0.33-1 <1.1.0-0", + "xtend": ">=4.0.0 <4.1.0-0" + } + } + } + }, + "gulp-remote-src-vscode": { + "version": "0.5.0", + "resolved": "http://registry.npm.taobao.org/gulp-remote-src-vscode/download/gulp-remote-src-vscode-0.5.0.tgz", + "integrity": "sha1-cXhVU7xJGIAIitlx+QkQxLLYCpk=", + "dev": true, + "requires": { + "event-stream": "^3.3.4", + "node.extend": "^1.1.2", + "request": "^2.79.0", + "through2": "^2.0.3", + "vinyl": "^2.0.1" + }, + "dependencies": { + "clone": { + "version": "2.1.1", + "resolved": "http://registry.npm.taobao.org/clone/download/clone-2.1.1.tgz", + "integrity": "sha1-0hfR6WERjjrJpLi7oyhVU79kfNs=", + "dev": true + }, + "clone-stats": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/clone-stats/download/clone-stats-1.0.0.tgz", + "integrity": "sha1-s3gt/4u1R04Yuba/D9/ngvh3doA=", + "dev": true + }, + "vinyl": { + "version": "2.2.0", + "resolved": "http://registry.npm.taobao.org/vinyl/download/vinyl-2.2.0.tgz", + "integrity": "sha1-2FsH2pbkWNJbL/4Z/s6fLKoT7YY=", + "dev": true, + "requires": { + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" + } + } + } + }, + "gulp-sourcemaps": { + "version": "1.6.0", + "resolved": "http://registry.npm.taobao.org/gulp-sourcemaps/download/gulp-sourcemaps-1.6.0.tgz", + "integrity": "sha1-uG/zSdgBzrVuHZ59x7vLS33uYAw=", + "dev": true, + "requires": { + "convert-source-map": "^1.1.1", + "graceful-fs": "^4.1.2", + "strip-bom": "^2.0.0", + "through2": "^2.0.0", + "vinyl": "^1.0.0" + }, + "dependencies": { + "clone": { + "version": "1.0.4", + "resolved": "http://registry.npm.taobao.org/clone/download/clone-1.0.4.tgz", + "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", + "dev": true + }, + "replace-ext": { + "version": "0.0.1", + "resolved": "http://registry.npm.taobao.org/replace-ext/download/replace-ext-0.0.1.tgz", + "integrity": "sha1-KbvZIHinOfC8zitO5B6DeVNSKSQ=", + "dev": true + }, + "vinyl": { + "version": "1.2.0", + "resolved": "http://registry.npm.taobao.org/vinyl/download/vinyl-1.2.0.tgz", + "integrity": "sha1-XIgDbPVl5d8FVYv8kR+GVt8hiIQ=", + "dev": true, + "requires": { + "clone": "^1.0.0", + "clone-stats": "^0.0.1", + "replace-ext": "0.0.1" + } + } + } + }, + "gulp-symdest": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/gulp-symdest/download/gulp-symdest-1.1.0.tgz", + "integrity": "sha1-wWUyBzLRks5W/ZQnH/oSMjS/KuA=", + "dev": true, + "requires": { + "event-stream": "^3.3.1", + "mkdirp": "^0.5.1", + "queue": "^3.1.0", + "vinyl-fs": "^2.4.3" + } + }, + "gulp-untar": { + "version": "0.0.7", + "resolved": "http://registry.npm.taobao.org/gulp-untar/download/gulp-untar-0.0.7.tgz", + "integrity": "sha1-kgZ9eeD6HpLWBWKhACM6RKWqCLQ=", + "dev": true, + "requires": { + "event-stream": "~3.3.4", + "streamifier": "~0.1.1", + "tar": "^2.2.1", + "through2": "~2.0.3", + "vinyl": "^1.2.0" + }, + "dependencies": { + "clone": { + "version": "1.0.4", + "resolved": "http://registry.npm.taobao.org/clone/download/clone-1.0.4.tgz", + "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", + "dev": true + }, + "replace-ext": { + "version": "0.0.1", + "resolved": "http://registry.npm.taobao.org/replace-ext/download/replace-ext-0.0.1.tgz", + "integrity": "sha1-KbvZIHinOfC8zitO5B6DeVNSKSQ=", + "dev": true + }, + "vinyl": { + "version": "1.2.0", + "resolved": "http://registry.npm.taobao.org/vinyl/download/vinyl-1.2.0.tgz", + "integrity": "sha1-XIgDbPVl5d8FVYv8kR+GVt8hiIQ=", + "dev": true, + "requires": { + "clone": "^1.0.0", + "clone-stats": "^0.0.1", + "replace-ext": "0.0.1" + } + } + } + }, + "gulp-vinyl-zip": { + "version": "2.1.0", + "resolved": "http://registry.npm.taobao.org/gulp-vinyl-zip/download/gulp-vinyl-zip-2.1.0.tgz", + "integrity": "sha1-JOQGhdwFtxSZlSRQmeBZAmO+ja0=", + "dev": true, + "requires": { + "event-stream": "^3.3.1", + "queue": "^4.2.1", + "through2": "^2.0.3", + "vinyl": "^2.0.2", + "vinyl-fs": "^2.0.0", + "yauzl": "^2.2.1", + "yazl": "^2.2.1" + }, + "dependencies": { + "clone": { + "version": "2.1.1", + "resolved": "http://registry.npm.taobao.org/clone/download/clone-2.1.1.tgz", + "integrity": "sha1-0hfR6WERjjrJpLi7oyhVU79kfNs=", + "dev": true + }, + "clone-stats": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/clone-stats/download/clone-stats-1.0.0.tgz", + "integrity": "sha1-s3gt/4u1R04Yuba/D9/ngvh3doA=", + "dev": true + }, + "queue": { + "version": "4.4.2", + "resolved": "http://registry.npm.taobao.org/queue/download/queue-4.4.2.tgz", + "integrity": "sha1-Wpcz2ai4vRs26TS8nFWribKOKcc=", + "dev": true, + "requires": { + "inherits": "~2.0.0" + } + }, + "vinyl": { + "version": "2.2.0", + "resolved": "http://registry.npm.taobao.org/vinyl/download/vinyl-2.2.0.tgz", + "integrity": "sha1-2FsH2pbkWNJbL/4Z/s6fLKoT7YY=", + "dev": true, + "requires": { + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" + } + } + } + }, + "har-schema": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/har-schema/download/har-schema-2.0.0.tgz", + "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=", + "dev": true + }, + "har-validator": { + "version": "5.0.3", + "resolved": "http://registry.npm.taobao.org/har-validator/download/har-validator-5.0.3.tgz", + "integrity": "sha1-ukAsJmGU8VlW7xXg/PJCmT9qff0=", + "dev": true, + "requires": { + "ajv": "^5.1.0", + "har-schema": "^2.0.0" + } + }, + "has-ansi": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/has-ansi/download/has-ansi-2.0.0.tgz", + "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=", + "dev": true, + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "has-flag": { + "version": "3.0.0", + "resolved": "http://registry.npm.taobao.org/has-flag/download/has-flag-3.0.0.tgz", + "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", + "dev": true + }, + "he": { + "version": "1.1.1", + "resolved": "http://registry.npm.taobao.org/he/download/he-1.1.1.tgz", + "integrity": "sha1-k0EP0hsAlzUVH4howvJx80J+I/0=", + "dev": true + }, + "http-signature": { + "version": "1.2.0", + "resolved": "http://registry.npm.taobao.org/http-signature/download/http-signature-1.2.0.tgz", + "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", + "dev": true, + "requires": { + "assert-plus": "^1.0.0", + "jsprim": "^1.2.2", + "sshpk": "^1.7.0" + } + }, + "inflight": { + "version": "1.0.6", + "resolved": "http://registry.npm.taobao.org/inflight/download/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.3", + "resolved": "http://registry.npm.taobao.org/inherits/download/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=", + "dev": true + }, + "is": { + "version": "3.2.1", + "resolved": "http://registry.npm.taobao.org/is/download/is-3.2.1.tgz", + "integrity": "sha1-0Kwq1V63sL7JJqUmb2xmKqqD3KU=", + "dev": true + }, + "is-buffer": { + "version": "1.1.6", + "resolved": "http://registry.npm.taobao.org/is-buffer/download/is-buffer-1.1.6.tgz", + "integrity": "sha1-76ouqdqg16suoTqXsritUf776L4=", + "dev": true + }, + "is-dotfile": { + "version": "1.0.3", + "resolved": "http://registry.npm.taobao.org/is-dotfile/download/is-dotfile-1.0.3.tgz", + "integrity": "sha1-pqLzL/0t+wT1yiXs0Pa4PPeYoeE=", + "dev": true + }, + "is-equal-shallow": { + "version": "0.1.3", + "resolved": "http://registry.npm.taobao.org/is-equal-shallow/download/is-equal-shallow-0.1.3.tgz", + "integrity": "sha1-IjgJj8Ih3gvPpdnqxMRdY4qhxTQ=", + "dev": true, + "requires": { + "is-primitive": "^2.0.0" + } + }, + "is-extendable": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/is-extendable/download/is-extendable-0.1.1.tgz", + "integrity": "sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik=", + "dev": true + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "http://registry.npm.taobao.org/is-extglob/download/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "dev": true + }, + "is-glob": { + "version": "3.1.0", + "resolved": "http://registry.npm.taobao.org/is-glob/download/is-glob-3.1.0.tgz", + "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", + "dev": true, + "requires": { + "is-extglob": "^2.1.0" + } + }, + "is-number": { + "version": "2.1.0", + "resolved": "http://registry.npm.taobao.org/is-number/download/is-number-2.1.0.tgz", + "integrity": "sha1-Afy7s5NGOlSPL0ZszhbezknbkI8=", + "dev": true, + "requires": { + "kind-of": "^3.0.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "http://registry.npm.taobao.org/kind-of/download/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "is-obj": { + "version": "1.0.1", + "resolved": "http://registry.npm.taobao.org/is-obj/download/is-obj-1.0.1.tgz", + "integrity": "sha1-PkcprB9f3gJc19g6iW2rn09n2w8=", + "dev": true + }, + "is-posix-bracket": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/is-posix-bracket/download/is-posix-bracket-0.1.1.tgz", + "integrity": "sha1-MzTceXdDaOkvAW5vvAqI9c1ua8Q=", + "dev": true + }, + "is-primitive": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/is-primitive/download/is-primitive-2.0.0.tgz", + "integrity": "sha1-IHurkWOEmcB7Kt8kCkGochADRXU=", + "dev": true + }, + "is-stream": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/is-stream/download/is-stream-1.1.0.tgz", + "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=", + "dev": true + }, + "is-typedarray": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/is-typedarray/download/is-typedarray-1.0.0.tgz", + "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=", + "dev": true + }, + "is-utf8": { + "version": "0.2.1", + "resolved": "http://registry.npm.taobao.org/is-utf8/download/is-utf8-0.2.1.tgz", + "integrity": "sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI=", + "dev": true + }, + "is-valid-glob": { + "version": "0.3.0", + "resolved": "http://registry.npm.taobao.org/is-valid-glob/download/is-valid-glob-0.3.0.tgz", + "integrity": "sha1-1LVcafUYhvm2XHDWwmItN+KfSP4=", + "dev": true + }, + "isarray": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/isarray/download/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", + "dev": true + }, + "isobject": { + "version": "2.1.0", + "resolved": "http://registry.npm.taobao.org/isobject/download/isobject-2.1.0.tgz", + "integrity": "sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk=", + "dev": true, + "requires": { + "isarray": "1.0.0" + } + }, + "isstream": { + "version": "0.1.2", + "resolved": "http://registry.npm.taobao.org/isstream/download/isstream-0.1.2.tgz", + "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=", + "dev": true + }, + "js-tokens": { + "version": "3.0.2", + "resolved": "http://registry.npm.taobao.org/js-tokens/download/js-tokens-3.0.2.tgz", + "integrity": "sha1-mGbfOVECEw449/mWvOtlRDIJwls=", + "dev": true + }, + "js-yaml": { + "version": "3.12.0", + "resolved": "http://registry.npm.taobao.org/js-yaml/download/js-yaml-3.12.0.tgz", + "integrity": "sha1-6u1lbsg0TxD1J8a/obbiJE3hZ9E=", + "dev": true, + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "jsbn": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/jsbn/download/jsbn-0.1.1.tgz", + "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", + "dev": true, + "optional": true + }, + "json-schema": { + "version": "0.2.3", + "resolved": "http://registry.npm.taobao.org/json-schema/download/json-schema-0.2.3.tgz", + "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=", + "dev": true + }, + "json-schema-traverse": { + "version": "0.3.1", + "resolved": "http://registry.npm.taobao.org/json-schema-traverse/download/json-schema-traverse-0.3.1.tgz", + "integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=", + "dev": true + }, + "json-stable-stringify": { + "version": "1.0.1", + "resolved": "http://registry.npm.taobao.org/json-stable-stringify/download/json-stable-stringify-1.0.1.tgz", + "integrity": "sha1-mnWdOcXy/1A/1TAGRu1EX4jE+a8=", + "dev": true, + "requires": { + "jsonify": "~0.0.0" + } + }, + "json-stringify-safe": { + "version": "5.0.1", + "resolved": "http://registry.npm.taobao.org/json-stringify-safe/download/json-stringify-safe-5.0.1.tgz", + "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", + "dev": true + }, + "jsonify": { + "version": "0.0.0", + "resolved": "http://registry.npm.taobao.org/jsonify/download/jsonify-0.0.0.tgz", + "integrity": "sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM=", + "dev": true + }, + "jsprim": { + "version": "1.4.1", + "resolved": "http://registry.npm.taobao.org/jsprim/download/jsprim-1.4.1.tgz", + "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", + "dev": true, + "requires": { + "assert-plus": "1.0.0", + "extsprintf": "1.3.0", + "json-schema": "0.2.3", + "verror": "1.10.0" + } + }, + "kind-of": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/kind-of/download/kind-of-1.1.0.tgz", + "integrity": "sha1-FAo9LUGjbS78+pN3tiwk+ElaXEQ=", + "dev": true + }, + "lazystream": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/lazystream/download/lazystream-1.0.0.tgz", + "integrity": "sha1-9plf4PggOS9hOWvolGJAe7dxaOQ=", + "dev": true, + "requires": { + "readable-stream": "^2.0.5" + } + }, + "lodash.isequal": { + "version": "4.5.0", + "resolved": "http://registry.npm.taobao.org/lodash.isequal/download/lodash.isequal-4.5.0.tgz", + "integrity": "sha1-QVxEePK8wwEgwizhDtMib30+GOA=", + "dev": true + }, + "map-stream": { + "version": "0.1.0", + "resolved": "http://registry.npm.taobao.org/map-stream/download/map-stream-0.1.0.tgz", + "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=", + "dev": true + }, + "math-random": { + "version": "1.0.1", + "resolved": "http://registry.npm.taobao.org/math-random/download/math-random-1.0.1.tgz", + "integrity": "sha1-izqsWIuKZuSXXjzepn97sylgH6w=", + "dev": true + }, + "merge-stream": { + "version": "1.0.1", + "resolved": "http://registry.npm.taobao.org/merge-stream/download/merge-stream-1.0.1.tgz", + "integrity": "sha1-QEEgLVCKNCugAXQAjfDCUbjBNeE=", + "dev": true, + "requires": { + "readable-stream": "^2.0.1" + } + }, + "micromatch": { + "version": "2.3.11", + "resolved": "http://registry.npm.taobao.org/micromatch/download/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "dev": true, + "requires": { + "arr-diff": "^2.0.0", + "array-unique": "^0.2.1", + "braces": "^1.8.2", + "expand-brackets": "^0.1.4", + "extglob": "^0.3.1", + "filename-regex": "^2.0.0", + "is-extglob": "^1.0.0", + "is-glob": "^2.0.1", + "kind-of": "^3.0.2", + "normalize-path": "^2.0.1", + "object.omit": "^2.0.0", + "parse-glob": "^3.0.4", + "regex-cache": "^0.4.2" + }, + "dependencies": { + "arr-diff": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/arr-diff/download/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "dev": true, + "requires": { + "arr-flatten": "^1.0.1" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/is-extglob/download/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + }, + "is-glob": { + "version": "2.0.1", + "resolved": "http://registry.npm.taobao.org/is-glob/download/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "dev": true, + "requires": { + "is-extglob": "^1.0.0" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "http://registry.npm.taobao.org/kind-of/download/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "mime-db": { + "version": "1.33.0", + "resolved": "http://registry.npm.taobao.org/mime-db/download/mime-db-1.33.0.tgz", + "integrity": "sha1-o0kgUKXLm2NFBUHjnZeI0icng9s=", + "dev": true + }, + "mime-types": { + "version": "2.1.18", + "resolved": "http://registry.npm.taobao.org/mime-types/download/mime-types-2.1.18.tgz", + "integrity": "sha1-bzI/YKg9ERRvgx/xH9ZuL+VQO7g=", + "dev": true, + "requires": { + "mime-db": "~1.33.0" + } + }, + "minimatch": { + "version": "3.0.4", + "resolved": "http://registry.npm.taobao.org/minimatch/download/minimatch-3.0.4.tgz", + "integrity": "sha1-UWbihkV/AzBgZL5Ul+jbsMPTIIM=", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "0.0.8", + "resolved": "http://registry.npm.taobao.org/minimist/download/minimist-0.0.8.tgz", + "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", + "dev": true + }, + "mkdirp": { + "version": "0.5.1", + "resolved": "http://registry.npm.taobao.org/mkdirp/download/mkdirp-0.5.1.tgz", + "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", + "dev": true, + "requires": { + "minimist": "0.0.8" + } + }, + "mocha": { + "version": "4.1.0", + "resolved": "http://registry.npm.taobao.org/mocha/download/mocha-4.1.0.tgz", + "integrity": "sha1-fYbPvPNcuCnidUwy4XNV7AUzh5Q=", + "dev": true, + "requires": { + "browser-stdout": "1.3.0", + "commander": "2.11.0", + "debug": "3.1.0", + "diff": "3.3.1", + "escape-string-regexp": "1.0.5", + "glob": "7.1.2", + "growl": "1.10.3", + "he": "1.1.1", + "mkdirp": "0.5.1", + "supports-color": "4.4.0" + }, + "dependencies": { + "commander": { + "version": "2.11.0", + "resolved": "http://registry.npm.taobao.org/commander/download/commander-2.11.0.tgz", + "integrity": "sha1-FXFS/R56bI2YpbcVzzdt+SgARWM=", + "dev": true + }, + "diff": { + "version": "3.3.1", + "resolved": "http://registry.npm.taobao.org/diff/download/diff-3.3.1.tgz", + "integrity": "sha1-qoVnpu7QPFMfyJ0/cRzQ5SWd7HU=", + "dev": true + }, + "has-flag": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/has-flag/download/has-flag-2.0.0.tgz", + "integrity": "sha1-6CB68cx7MNRGzHC3NLXovhj4jVE=", + "dev": true + }, + "supports-color": { + "version": "4.4.0", + "resolved": "http://registry.npm.taobao.org/supports-color/download/supports-color-4.4.0.tgz", + "integrity": "sha1-iD992rwWUUKyphQn8zUt7RldGj4=", + "dev": true, + "requires": { + "has-flag": "^2.0.0" + } + } + } + }, + "ms": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/ms/download/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", + "dev": true + }, + "multimatch": { + "version": "2.1.0", + "resolved": "http://registry.npm.taobao.org/multimatch/download/multimatch-2.1.0.tgz", + "integrity": "sha1-nHkGoi+0wCkZ4vX3UWG0zb1LKis=", + "dev": true, + "requires": { + "array-differ": "^1.0.0", + "array-union": "^1.0.1", + "arrify": "^1.0.0", + "minimatch": "^3.0.0" + } + }, + "node.extend": { + "version": "1.1.6", + "resolved": "http://registry.npm.taobao.org/node.extend/download/node.extend-1.1.6.tgz", + "integrity": "sha1-p7iCyC1sk6SGOlUEvV3o7IYli5Y=", + "dev": true, + "requires": { + "is": "^3.1.0" + } + }, + "normalize-path": { + "version": "2.1.1", + "resolved": "http://registry.npm.taobao.org/normalize-path/download/normalize-path-2.1.1.tgz", + "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", + "dev": true, + "requires": { + "remove-trailing-separator": "^1.0.1" + } + }, + "oauth-sign": { + "version": "0.8.2", + "resolved": "http://registry.npm.taobao.org/oauth-sign/download/oauth-sign-0.8.2.tgz", + "integrity": "sha1-Rqarfwrq2N6unsBWV4C31O/rnUM=", + "dev": true + }, + "object-assign": { + "version": "4.1.1", + "resolved": "http://registry.npm.taobao.org/object-assign/download/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", + "dev": true + }, + "object.omit": { + "version": "2.0.1", + "resolved": "http://registry.npm.taobao.org/object.omit/download/object.omit-2.0.1.tgz", + "integrity": "sha1-Gpx0SCnznbuFjHbKNXmuKlTr0fo=", + "dev": true, + "requires": { + "for-own": "^0.1.4", + "is-extendable": "^0.1.1" + } + }, + "once": { + "version": "1.4.0", + "resolved": "http://registry.npm.taobao.org/once/download/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "ordered-read-streams": { + "version": "0.3.0", + "resolved": "http://registry.npm.taobao.org/ordered-read-streams/download/ordered-read-streams-0.3.0.tgz", + "integrity": "sha1-cTfmmzKYuzQiR6G77jiByA4v14s=", + "dev": true, + "requires": { + "is-stream": "^1.0.1", + "readable-stream": "^2.0.1" + } + }, + "parse-glob": { + "version": "3.0.4", + "resolved": "http://registry.npm.taobao.org/parse-glob/download/parse-glob-3.0.4.tgz", + "integrity": "sha1-ssN2z7EfNVE7rdFz7wu246OIORw=", + "dev": true, + "requires": { + "glob-base": "^0.3.0", + "is-dotfile": "^1.0.0", + "is-extglob": "^1.0.0", + "is-glob": "^2.0.0" + }, + "dependencies": { + "is-extglob": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/is-extglob/download/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + }, + "is-glob": { + "version": "2.0.1", + "resolved": "http://registry.npm.taobao.org/is-glob/download/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "dev": true, + "requires": { + "is-extglob": "^1.0.0" + } + } + } + }, + "path-dirname": { + "version": "1.0.2", + "resolved": "http://registry.npm.taobao.org/path-dirname/download/path-dirname-1.0.2.tgz", + "integrity": "sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA=", + "dev": true + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "http://registry.npm.taobao.org/path-is-absolute/download/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "path-parse": { + "version": "1.0.5", + "resolved": "http://registry.npm.taobao.org/path-parse/download/path-parse-1.0.5.tgz", + "integrity": "sha1-PBrfhx6pzWyUMbbqK9dKD/BVxME=", + "dev": true + }, + "pause-stream": { + "version": "0.0.11", + "resolved": "http://registry.npm.taobao.org/pause-stream/download/pause-stream-0.0.11.tgz", + "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", + "dev": true, + "requires": { + "through": "~2.3" + } + }, + "pend": { + "version": "1.2.0", + "resolved": "http://registry.npm.taobao.org/pend/download/pend-1.2.0.tgz", + "integrity": "sha1-elfrVQpng/kRUzH89GY9XI4AelA=", + "dev": true + }, + "performance-now": { + "version": "2.1.0", + "resolved": "http://registry.npm.taobao.org/performance-now/download/performance-now-2.1.0.tgz", + "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", + "dev": true + }, + "plugin-error": { + "version": "0.1.2", + "resolved": "http://registry.npm.taobao.org/plugin-error/download/plugin-error-0.1.2.tgz", + "integrity": "sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4=", + "dev": true, + "requires": { + "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" + } + }, + "preserve": { + "version": "0.2.0", + "resolved": "http://registry.npm.taobao.org/preserve/download/preserve-0.2.0.tgz", + "integrity": "sha1-gV7R9uvGWSb4ZbMQwHE7yzMVzks=", + "dev": true + }, + "process-nextick-args": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/process-nextick-args/download/process-nextick-args-2.0.0.tgz", + "integrity": "sha1-o31zL0JxtKsa0HDTVQjoKQeI/6o=", + "dev": true + }, + "punycode": { + "version": "1.4.1", + "resolved": "http://registry.npm.taobao.org/punycode/download/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "dev": true + }, + "qs": { + "version": "6.5.2", + "resolved": "http://registry.npm.taobao.org/qs/download/qs-6.5.2.tgz", + "integrity": "sha1-yzroBuh0BERYTvFUzo7pjUA/PjY=", + "dev": true + }, + "querystringify": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/querystringify/download/querystringify-2.0.0.tgz", + "integrity": "sha1-+j7W5o6xUVlFfImze8ZHKDMZV1U=", + "dev": true + }, + "queue": { + "version": "3.1.0", + "resolved": "http://registry.npm.taobao.org/queue/download/queue-3.1.0.tgz", + "integrity": "sha1-bEnQHwCeIlZ4h4nyv/rGuLmZBYU=", + "dev": true, + "requires": { + "inherits": "~2.0.0" + } + }, + "randomatic": { + "version": "3.0.0", + "resolved": "http://registry.npm.taobao.org/randomatic/download/randomatic-3.0.0.tgz", + "integrity": "sha1-01SQAw6091eN4pLObfsEqRoSiSM=", + "dev": true, + "requires": { + "is-number": "^4.0.0", + "kind-of": "^6.0.0", + "math-random": "^1.0.1" + }, + "dependencies": { + "is-number": { + "version": "4.0.0", + "resolved": "http://registry.npm.taobao.org/is-number/download/is-number-4.0.0.tgz", + "integrity": "sha1-ACbjf1RU1z41bf5lZGmYZ8an8P8=", + "dev": true + }, + "kind-of": { + "version": "6.0.2", + "resolved": "http://registry.npm.taobao.org/kind-of/download/kind-of-6.0.2.tgz", + "integrity": "sha1-ARRrNqYhjmTljzqNZt5df8b20FE=", + "dev": true + } + } + }, + "readable-stream": { + "version": "2.3.6", + "resolved": "http://registry.npm.taobao.org/readable-stream/download/readable-stream-2.3.6.tgz", + "integrity": "sha1-sRwn2IuP8fvgcGQ8+UsMea4bCq8=", + "dev": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "regex-cache": { + "version": "0.4.4", + "resolved": "http://registry.npm.taobao.org/regex-cache/download/regex-cache-0.4.4.tgz", + "integrity": "sha1-db3FiioUls7EihKDW8VMjVYjNt0=", + "dev": true, + "requires": { + "is-equal-shallow": "^0.1.3" + } + }, + "remove-trailing-separator": { + "version": "1.1.0", + "resolved": "http://registry.npm.taobao.org/remove-trailing-separator/download/remove-trailing-separator-1.1.0.tgz", + "integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8=", + "dev": true + }, + "repeat-element": { + "version": "1.1.2", + "resolved": "http://registry.npm.taobao.org/repeat-element/download/repeat-element-1.1.2.tgz", + "integrity": "sha1-7wiaF40Ug7quTZPrmLT55OEdmQo=", + "dev": true + }, + "repeat-string": { + "version": "1.6.1", + "resolved": "http://registry.npm.taobao.org/repeat-string/download/repeat-string-1.6.1.tgz", + "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=", + "dev": true + }, + "replace-ext": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/replace-ext/download/replace-ext-1.0.0.tgz", + "integrity": "sha1-3mMSg3P8v3w8z6TeWkgMRaZ5WOs=", + "dev": true + }, + "request": { + "version": "2.87.0", + "resolved": "http://registry.npm.taobao.org/request/download/request-2.87.0.tgz", + "integrity": "sha1-MvACNc0I1IK00NaNuTqCnA7VdW4=", + "dev": true, + "requires": { + "aws-sign2": "~0.7.0", + "aws4": "^1.6.0", + "caseless": "~0.12.0", + "combined-stream": "~1.0.5", + "extend": "~3.0.1", + "forever-agent": "~0.6.1", + "form-data": "~2.3.1", + "har-validator": "~5.0.3", + "http-signature": "~1.2.0", + "is-typedarray": "~1.0.0", + "isstream": "~0.1.2", + "json-stringify-safe": "~5.0.1", + "mime-types": "~2.1.17", + "oauth-sign": "~0.8.2", + "performance-now": "^2.1.0", + "qs": "~6.5.1", + "safe-buffer": "^5.1.1", + "tough-cookie": "~2.3.3", + "tunnel-agent": "^0.6.0", + "uuid": "^3.1.0" + } + }, + "requires-port": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/requires-port/download/requires-port-1.0.0.tgz", + "integrity": "sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8=", + "dev": true + }, + "resolve": { + "version": "1.8.1", + "resolved": "http://registry.npm.taobao.org/resolve/download/resolve-1.8.1.tgz", + "integrity": "sha1-gvHsGaQjrB+9CAsLqwa6NuhKeiY=", + "dev": true, + "requires": { + "path-parse": "^1.0.5" + } + }, + "rimraf": { + "version": "2.6.2", + "resolved": "http://registry.npm.taobao.org/rimraf/download/rimraf-2.6.2.tgz", + "integrity": "sha1-LtgVDSShbqhlHm1u8PR8QVjOejY=", + "dev": true, + "requires": { + "glob": "^7.0.5" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "http://registry.npm.taobao.org/safe-buffer/download/safe-buffer-5.1.2.tgz", + "integrity": "sha1-mR7GnSluAxN0fVm9/St0XDX4go0=", + "dev": true + }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "http://registry.npm.taobao.org/safer-buffer/download/safer-buffer-2.1.2.tgz", + "integrity": "sha1-RPoWGwGHuVSd2Eu5GAL5vYOFzWo=", + "dev": true + }, + "semver": { + "version": "5.5.0", + "resolved": "http://registry.npm.taobao.org/semver/download/semver-5.5.0.tgz", + "integrity": "sha1-3Eu8emyp2Rbe5dQ1FvAJK1j3uKs=", + "dev": true + }, + "source-map": { + "version": "0.6.1", + "resolved": "http://registry.npm.taobao.org/source-map/download/source-map-0.6.1.tgz", + "integrity": "sha1-dHIq8y6WFOnCh6jQu95IteLxomM=", + "dev": true + }, + "source-map-support": { + "version": "0.5.6", + "resolved": "http://registry.npm.taobao.org/source-map-support/download/source-map-support-0.5.6.tgz", + "integrity": "sha1-RDXO5Gsaq2K46GEM5g94gJHFHBM=", + "dev": true, + "requires": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "split": { + "version": "0.3.3", + "resolved": "http://registry.npm.taobao.org/split/download/split-0.3.3.tgz", + "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", + "dev": true, + "requires": { + "through": "2" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "http://registry.npm.taobao.org/sprintf-js/download/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "sshpk": { + "version": "1.14.2", + "resolved": "http://registry.npm.taobao.org/sshpk/download/sshpk-1.14.2.tgz", + "integrity": "sha1-xvxhZIo9nE52T9P8306hBeSSupg=", + "dev": true, + "requires": { + "asn1": "~0.2.3", + "assert-plus": "^1.0.0", + "bcrypt-pbkdf": "^1.0.0", + "dashdash": "^1.12.0", + "ecc-jsbn": "~0.1.1", + "getpass": "^0.1.1", + "jsbn": "~0.1.0", + "safer-buffer": "^2.0.2", + "tweetnacl": "~0.14.0" + } + }, + "stat-mode": { + "version": "0.2.2", + "resolved": "http://registry.npm.taobao.org/stat-mode/download/stat-mode-0.2.2.tgz", + "integrity": "sha1-5sgLYjEj19gM8TLOU480YokHJQI=", + "dev": true + }, + "stream-combiner": { + "version": "0.0.4", + "resolved": "http://registry.npm.taobao.org/stream-combiner/download/stream-combiner-0.0.4.tgz", + "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", + "dev": true, + "requires": { + "duplexer": "~0.1.1" + } + }, + "stream-shift": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/stream-shift/download/stream-shift-1.0.0.tgz", + "integrity": "sha1-1cdSgl5TZ+eG944Y5EXqIjoVWVI=", + "dev": true + }, + "streamfilter": { + "version": "1.0.7", + "resolved": "http://registry.npm.taobao.org/streamfilter/download/streamfilter-1.0.7.tgz", + "integrity": "sha1-rj5kUiqlo1wGH9F/Z2IMdlPGQ8k=", + "dev": true, + "requires": { + "readable-stream": "^2.0.2" + } + }, + "streamifier": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/streamifier/download/streamifier-0.1.1.tgz", + "integrity": "sha1-l+mNj6TRBdYqJpHR3AfoINuN/E8=", + "dev": true + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "http://registry.npm.taobao.org/string_decoder/download/string_decoder-1.1.1.tgz", + "integrity": "sha1-nPFhG6YmhdcDCunkujQUnDrwP8g=", + "dev": true, + "requires": { + "safe-buffer": "~5.1.0" + } + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "http://registry.npm.taobao.org/strip-ansi/download/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "dev": true, + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "strip-bom": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/strip-bom/download/strip-bom-2.0.0.tgz", + "integrity": "sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4=", + "dev": true, + "requires": { + "is-utf8": "^0.2.0" + } + }, + "strip-bom-stream": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/strip-bom-stream/download/strip-bom-stream-1.0.0.tgz", + "integrity": "sha1-5xRDmFd9Uaa+0PoZlPoF9D/ZiO4=", + "dev": true, + "requires": { + "first-chunk-stream": "^1.0.0", + "strip-bom": "^2.0.0" + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/supports-color/download/supports-color-2.0.0.tgz", + "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=", + "dev": true + }, + "tar": { + "version": "2.2.1", + "resolved": "http://registry.npm.taobao.org/tar/download/tar-2.2.1.tgz", + "integrity": "sha1-jk0qJWwOIYXGsYrWlK7JaLg8sdE=", + "dev": true, + "requires": { + "block-stream": "*", + "fstream": "^1.0.2", + "inherits": "2" + } + }, + "through": { + "version": "2.3.8", + "resolved": "http://registry.npm.taobao.org/through/download/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", + "dev": true + }, + "through2": { + "version": "2.0.3", + "resolved": "http://registry.npm.taobao.org/through2/download/through2-2.0.3.tgz", + "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", + "dev": true, + "requires": { + "readable-stream": "^2.1.5", + "xtend": "~4.0.1" + } + }, + "through2-filter": { + "version": "2.0.0", + "resolved": "http://registry.npm.taobao.org/through2-filter/download/through2-filter-2.0.0.tgz", + "integrity": "sha1-YLxVoNrLdghdsfna6Zq0P4PWIuw=", + "dev": true, + "requires": { + "through2": "~2.0.0", + "xtend": "~4.0.0" + } + }, + "to-absolute-glob": { + "version": "0.1.1", + "resolved": "http://registry.npm.taobao.org/to-absolute-glob/download/to-absolute-glob-0.1.1.tgz", + "integrity": "sha1-HN+kcqnvUMI57maZm2YsoOs5k38=", + "dev": true, + "requires": { + "extend-shallow": "^2.0.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "http://registry.npm.taobao.org/extend-shallow/download/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "tough-cookie": { + "version": "2.3.4", + "resolved": "http://registry.npm.taobao.org/tough-cookie/download/tough-cookie-2.3.4.tgz", + "integrity": "sha1-7GDO44rGdQY//JelwYlwV47oNlU=", + "dev": true, + "requires": { + "punycode": "^1.4.1" + } + }, + "ts-debounce": { + "version": "0.3.2", + "resolved": "http://registry.npm.taobao.org/ts-debounce/download/ts-debounce-0.3.2.tgz", + "integrity": "sha1-IPjhZZptUpBddPd6EUXYZiVHv60=" + }, + "tslib": { + "version": "1.9.3", + "resolved": "http://registry.npm.taobao.org/tslib/download/tslib-1.9.3.tgz", + "integrity": "sha1-1+TdeSRdhUKMTX5IIqeZF5VMooY=", + "dev": true + }, + "tslint": { + "version": "5.10.0", + "resolved": "http://registry.npm.taobao.org/tslint/download/tslint-5.10.0.tgz", + "integrity": "sha1-EeJrzLiK+gLdDZlWyuPUVAtfVMM=", + "dev": true, + "requires": { + "babel-code-frame": "^6.22.0", + "builtin-modules": "^1.1.1", + "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.8.0", + "tsutils": "^2.12.1" + } + }, + "tsutils": { + "version": "2.27.2", + "resolved": "http://registry.npm.taobao.org/tsutils/download/tsutils-2.27.2.tgz", + "integrity": "sha1-YLqIoj1veF7EuJxugXnKybQx8cc=", + "dev": true, + "requires": { + "tslib": "^1.8.1" + } + }, + "tunnel-agent": { + "version": "0.6.0", + "resolved": "http://registry.npm.taobao.org/tunnel-agent/download/tunnel-agent-0.6.0.tgz", + "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", + "dev": true, + "requires": { + "safe-buffer": "^5.0.1" + } + }, + "tweetnacl": { + "version": "0.14.5", + "resolved": "http://registry.npm.taobao.org/tweetnacl/download/tweetnacl-0.14.5.tgz", + "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", + "dev": true, + "optional": true + }, + "typescript": { + "version": "2.9.2", + "resolved": "http://registry.npm.taobao.org/typescript/download/typescript-2.9.2.tgz", + "integrity": "sha1-HL9h0F1rliaSROtqO85L2RTg8Aw=", + "dev": true + }, + "unique-stream": { + "version": "2.2.1", + "resolved": "http://registry.npm.taobao.org/unique-stream/download/unique-stream-2.2.1.tgz", + "integrity": "sha1-WqADz76Uxf+GbE59ZouxxNuts2k=", + "dev": true, + "requires": { + "json-stable-stringify": "^1.0.0", + "through2-filter": "^2.0.0" + } + }, + "url-parse": { + "version": "1.4.1", + "resolved": "http://registry.npm.taobao.org/url-parse/download/url-parse-1.4.1.tgz", + "integrity": "sha1-TeydrT3IWF+GL+1GHS4Zu/Yj3zA=", + "dev": true, + "requires": { + "querystringify": "^2.0.0", + "requires-port": "^1.0.0" + } + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "http://registry.npm.taobao.org/util-deprecate/download/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", + "dev": true + }, + "uuid": { + "version": "3.3.2", + "resolved": "http://registry.npm.taobao.org/uuid/download/uuid-3.3.2.tgz", + "integrity": "sha1-G0r0lV6zB3xQHCOHL8ZROBFYcTE=", + "dev": true + }, + "vali-date": { + "version": "1.0.0", + "resolved": "http://registry.npm.taobao.org/vali-date/download/vali-date-1.0.0.tgz", + "integrity": "sha1-G5BKWWCfsyjvB4E4Qgk09rhnCaY=", + "dev": true + }, + "verror": { + "version": "1.10.0", + "resolved": "http://registry.npm.taobao.org/verror/download/verror-1.10.0.tgz", + "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", + "dev": true, + "requires": { + "assert-plus": "^1.0.0", + "core-util-is": "1.0.2", + "extsprintf": "^1.2.0" + } + }, + "vinyl": { + "version": "0.4.6", + "resolved": "http://registry.npm.taobao.org/vinyl/download/vinyl-0.4.6.tgz", + "integrity": "sha1-LzVsh6VQolVGHza76ypbqL94SEc=", + "dev": true, + "requires": { + "clone": "^0.2.0", + "clone-stats": "^0.0.1" + } + }, + "vinyl-fs": { + "version": "2.4.4", + "resolved": "http://registry.npm.taobao.org/vinyl-fs/download/vinyl-fs-2.4.4.tgz", + "integrity": "sha1-vm/zJwy1Xf19MGNkDegfJddTIjk=", + "dev": true, + "requires": { + "duplexify": "^3.2.0", + "glob-stream": "^5.3.2", + "graceful-fs": "^4.0.0", + "gulp-sourcemaps": "1.6.0", + "is-valid-glob": "^0.3.0", + "lazystream": "^1.0.0", + "lodash.isequal": "^4.0.0", + "merge-stream": "^1.0.0", + "mkdirp": "^0.5.0", + "object-assign": "^4.0.0", + "readable-stream": "^2.0.4", + "strip-bom": "^2.0.0", + "strip-bom-stream": "^1.0.0", + "through2": "^2.0.0", + "through2-filter": "^2.0.0", + "vali-date": "^1.0.0", + "vinyl": "^1.0.0" + }, + "dependencies": { + "clone": { + "version": "1.0.4", + "resolved": "http://registry.npm.taobao.org/clone/download/clone-1.0.4.tgz", + "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", + "dev": true + }, + "replace-ext": { + "version": "0.0.1", + "resolved": "http://registry.npm.taobao.org/replace-ext/download/replace-ext-0.0.1.tgz", + "integrity": "sha1-KbvZIHinOfC8zitO5B6DeVNSKSQ=", + "dev": true + }, + "vinyl": { + "version": "1.2.0", + "resolved": "http://registry.npm.taobao.org/vinyl/download/vinyl-1.2.0.tgz", + "integrity": "sha1-XIgDbPVl5d8FVYv8kR+GVt8hiIQ=", + "dev": true, + "requires": { + "clone": "^1.0.0", + "clone-stats": "^0.0.1", + "replace-ext": "0.0.1" + } + } + } + }, + "vinyl-source-stream": { + "version": "1.1.2", + "resolved": "http://registry.npm.taobao.org/vinyl-source-stream/download/vinyl-source-stream-1.1.2.tgz", + "integrity": "sha1-YrU6E1YQqJbpjKlr7jqH8Aio54A=", + "dev": true, + "requires": { + "through2": "^2.0.3", + "vinyl": "^0.4.3" + } + }, + "vscode": { + "version": "1.1.18", + "resolved": "http://registry.npm.taobao.org/vscode/download/vscode-1.1.18.tgz", + "integrity": "sha1-6SJyZdxy/IJr1s170hGT9OSPpnE=", + "dev": true, + "requires": { + "glob": "^7.1.2", + "gulp-chmod": "^2.0.0", + "gulp-filter": "^5.0.1", + "gulp-gunzip": "1.0.0", + "gulp-remote-src-vscode": "^0.5.0", + "gulp-symdest": "^1.1.0", + "gulp-untar": "^0.0.7", + "gulp-vinyl-zip": "^2.1.0", + "mocha": "^4.0.1", + "request": "^2.83.0", + "semver": "^5.4.1", + "source-map-support": "^0.5.0", + "url-parse": "^1.1.9", + "vinyl-source-stream": "^1.1.0" + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "http://registry.npm.taobao.org/wrappy/download/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "xtend": { + "version": "4.0.1", + "resolved": "http://registry.npm.taobao.org/xtend/download/xtend-4.0.1.tgz", + "integrity": "sha1-pcbVMr5lbiPbgg77lDofBJmNY68=", + "dev": true + }, + "yauzl": { + "version": "2.10.0", + "resolved": "http://registry.npm.taobao.org/yauzl/download/yauzl-2.10.0.tgz", + "integrity": "sha1-x+sXyT4RLLEIb6bY5R+wZnt5pfk=", + "dev": true, + "requires": { + "buffer-crc32": "~0.2.3", + "fd-slicer": "~1.1.0" + } + }, + "yazl": { + "version": "2.4.3", + "resolved": "http://registry.npm.taobao.org/yazl/download/yazl-2.4.3.tgz", + "integrity": "sha1-7CblzIfVYBud+EMtvdPNLlFzoHE=", + "dev": true, + "requires": { + "buffer-crc32": "~0.2.3" + } + } + } +} diff --git a/package.json b/package.json index 2fdf00f..6f69465 100644 --- a/package.json +++ b/package.json @@ -1,219 +1,259 @@ { - "name": "vscode-todo-highlight", - "displayName": "TODO Highlight", - "description": "highlight TODOs, FIXMEs, and any keywords, annotations...", - "keywords": [ - "todo", - "fixme", - "highlight", - "keyword", - "annotation" - ], - "version": "0.5.12", - "publisher": "wayou", - "license": "MIT", - "icon": "assets/icon.png", - "homepage": "https://github.com/wayou/vscode-todo-highlight", - "repository": { - "type": "git", - "url": "https://github.com/wayou/vscode-todo-highlight.git" + "name": "vscode-todo-highlight", + "displayName": "TODO Highlight", + "description": "Highlight TODO, FIXME, or whatever annotations.", + "keywords": [ + "todo", + "fixme", + "highlight", + "keyword", + "annotation" + ], + "version": "1.0.0", + "publisher": "wayou", + "license": "MIT", + "icon": "assets/icon.png", + "homepage": "https://github.com/wayou/vscode-todo-highlight", + "repository": { + "type": "git", + "url": "https://github.com/wayou/vscode-todo-highlight.git" + }, + "bugs": { + "url": "https://github.com/wayou/vscode-todo-highlight/issues", + "email": "liuwayong@gmail.com" + }, + "galleryBanner": { + "color": "#272729", + "theme": "dark" + }, + "engines": { + "vscode": "^1.24.0" + }, + "categories": [ + "Other" + ], + "badges": [ + { + "url": "https://img.shields.io/badge/License-MIT-brightgreen.svg", + "href": "https://opensource.org/licenses/MIT", + "description": "License: MIT" }, - "bugs": { - "url": "https://github.com/wayou/vscode-todo-highlight/issues", - "email": "liuwayong@gmail.com" + { + "url": "https://travis-ci.org/wayou/vscode-todo-highlight.svg?branch=master", + "href": "https://travis-ci.org/wayou/vscode-todo-highlight", + "description": "Build Status" }, - "galleryBanner": { - "color": "#272729", - "theme": "dark" + { + "url": "https://vsmarketplacebadge.apphb.com/version-short/wayou.vscode-todo-highlight.svg", + "href": "https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight", + "description": "Version" }, - "engines": { - "vscode": "^1.5.0" + { + "url": "https://vsmarketplacebadge.apphb.com/installs-short/wayou.vscode-todo-highlight.svg", + "href": "https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight", + "description": "Installs" }, - "categories": [ - "Other" - ], - "activationEvents": [ - "*" + { + "url": "https://vsmarketplacebadge.apphb.com/rating-short/wayou.vscode-todo-highlight.svg", + "href": "https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight", + "description": "Ratings" + } + ], + "activationEvents": [ + "*" + ], + "main": "./out/extension", + "contributes": { + "commands": [ + { + "title": "Toggle highlight", + "category": "TODO Highlight", + "command": "todohighlight.toggleHighlight" + }, + { + "title": "List annotations in current file...", + "category": "TODO Highlight", + "command": "todohighlight.listAnnotations" + }, + { + "title": "List all annotations...", + "category": "TODO Highlight", + "command": "todohighlight.listAllAnnotations" + }, + { + "title": "Toggle URI pattern", + "category": "TODO Highlight", + "command": "todohighlight.toggleURI" + } ], - "main": "./src/extension", - "scripts": { - "postinstall": "node ./node_modules/vscode/bin/install", - "test": "node ./node_modules/vscode/bin/test" - }, - "badges": [ - { - "url": "https://img.shields.io/badge/License-MIT-brightgreen.svg", - "href": "https://opensource.org/licenses/MIT", - "description": "License: MIT" - }, - { - "url": "https://travis-ci.org/wayou/vscode-todo-highlight.svg?branch=master", - "href": "https://travis-ci.org/wayou/vscode-todo-highlight", - "description": "Build Status" + "configuration": { + "type": "object", + "title": "TODO Highlight", + "properties": { + "todohighlight.isEnable": { + "type": "boolean", + "default": true, + "description": "enable/disable this extension." }, - { - "url": "https://vsmarketplacebadge.apphb.com/version-short/wayou.vscode-todo-highlight.svg", - "href": "https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight", - "description": "Version" + "todohighlight.isCaseSensitive": { + "type": "boolean", + "default": true, + "description": "whether the keywords are case sensitive or not." }, - { - "url": "https://vsmarketplacebadge.apphb.com/installs-short/wayou.vscode-todo-highlight.svg", - "href": "https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight", - "description": "Installs" + "todohighlight.toggleURI": { + "type": "boolean", + "default": false, + "description": "if the file uri within the output channel is not clickable, set this to true to toggle the uri patten between `#` and `::`" }, - { - "url": "https://vsmarketplacebadge.apphb.com/rating-short/wayou.vscode-todo-highlight.svg", - "href": "https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight", - "description": "Ratings" - } - ], - "contributes": { - "commands": [ - { - "title": "Toggle highlight", - "category": "TODO-Highlight", - "command": "todohighlight.toggleHighlight" - }, + "todohighlight.keywords": { + "type": "array", + "default": [ { - "title": "List highlighted annotations", - "category": "TODO-Highlight", - "command": "todohighlight.listAnnotations" - } - ], - "configuration": { - "type": "object", - "title": "TODO Highlight", - "properties": { - "todohighlight.isEnable": { - "type": "boolean", - "default": true, - "description": "Enable or disable the highlight" + "pattern": "TODO:", + "style": { + "dark": { + "color": "#757575" }, - "todohighlight.isCaseSensitive": { - "type": "boolean", - "default": true, - "description": "Specify whether the keywords are case sensitive or not" + "light": { + "color": "#fff" }, - "todohighlight.toggleURI": { - "type": "boolean", - "default": false, - "description": "If the file path within the output channel not clickable, set this to true to toggle the path patten between `#` and `::`" + "backgroundColor": "#ffbd2a", + "borderRadius": "2px", + "border": "1px solid red" + }, + "description": "Things need to be done later." + }, + { + "pattern": "FIXME:", + "style": { + "dark": { + "color": "#eee" }, - "todohighlight.keywords": { - "type": "array", - "description": "Customize keywords and colors. Any css color identifier is valid.", - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "object", - "properties": { - "text": { - "type": "string", - "description": "Custom text to be highlighted" - }, - "color": { - "type": "string", - "description": "The text color. Besides, you can play with all the string and boolean styling properties provied by VS Code API. See all available properties on VSCode doc DecorationRenderOptions section: https://code.visualstudio.com/docs/extensionAPI/vscode-api" - }, - "backgroundColor": { - "type": "string", - "description": "The text background color. See all available properties on VSCode doc DecorationRenderOptions section: https://code.visualstudio.com/docs/extensionAPI/vscode-api" - }, - "overviewRulerColor": { - "type": "string", - "description": "The color of the ruler mark on the scroll bar. Use rgba() and define transparent colors to play well with other decorations. See all available properties on VSCode doc DecorationRenderOptions section: https://code.visualstudio.com/docs/extensionAPI/vscode-api" - } - } - } - ] - } + "light": { + "color": "#fff" }, - "todohighlight.keywordsPattern": { + "backgroundColor": "#f06292", + "borderRadius": "2px", + "border": "1px solid red" + }, + "description": "Things need to be fixed." + }, + "AVOID:", + "BUG:", + "CAUTION:", + "CONFIGURATION:", + "DEBUG:", + "DEPRECATED:", + "DO_NOT_REMOVE:", + "HACK:", + "IMPORTANT:", + "IMPROVE:", + "INFO:", + "ISSUE:", + "KEEP:", + "LEGACY:", + "NOTE:", + "OPTIMIZE:", + "PERFORMANCE:", + "PLACEHOLDER:", + "PREFER:", + "REFACTOR:", + "REMOVE:", + "REVIEW:", + "RFC:", + "TEMP:", + "WARNING:" + ], + "description": "annotations that will be highlighted.", + "items": { + "anyOf": [ + { + "type": "string", + "description": "plain string or escaped RegExp string. e.g. `TODO:`, `\\\\bTODO\\\\b`" + }, + { + "type": "object", + "properties": { + "pattern": { "type": "string", - "default": "", - "description": "Specify keywords via RegExp instead of `todohighlight.keywords` one by one. NOTE that if this presents, `todohighlight.keywords` will be ignored. And REMEMBER to escapse the back slash if there's any in your regexp (using \\\\ instead of single back slash)" - }, - "todohighlight.defaultStyle": { + "description": "plain string or escaped RegExp string. e.g. `TODO:`, `\\\\bTODO\\\\b`" + }, + "style": { "type": "object", - "description": "Default style for all customized keywords", - "properties": { - "color": { - "type": "string", - "description": "The text color. See all available properties on VSCode doc DecorationRenderOptions section: https://code.visualstudio.com/docs/extensionAPI/vscode-api" - }, - "backgroundColor": { - "type": "string", - "description": "The text background color. See all available properties on VSCode doc DecorationRenderOptions section: https://code.visualstudio.com/docs/extensionAPI/vscode-api" - }, - "overviewRulerColor": { - "type": "string", - "description": "The color of the ruler mark on the scroll bar. See all available properties on VSCode doc DecorationRenderOptions section: https://code.visualstudio.com/docs/extensionAPI/vscode-api" - } - } - }, - "todohighlight.include": { - "type": "array", - "default": [ - "**/*.js", - "**/*.jsx", - "**/*.ts", - "**/*.tsx", - "**/*.html", - "**/*.php", - "**/*.css", - "**/*.scss" - ], - "description": "Glob patterns that defines the files to search for. Only include files you need, DO NOT USE `{**/*.*}` for both permormance and avoiding binary files reason.", - "items": { - "anyOf": [ - { - "type": "string", - "description": "A glob pattern that defines the files to search for. Only include files you need, DO NOT USE `**/*.*` for both performance and avoiding binary files reason" - } - ] - } - }, - "todohighlight.exclude": { - "type": "array", - "default": [ - "**/node_modules/**", - "**/bower_components/**", - "**/dist/**", - "**/build/**", - "**/.vscode/**", - "**/.github/**", - "**/_output/**", - "**/*.min.*", - "**/*.map", - "**/.next/**" - ], - "description": "Glob pattern that defines files and folders to exclude while listing annotations.", - "items": { - "anyOf": [ - { - "type": "string", - "description": "A glob pattern that defines files and folders to exclude while listing annotations" - } - ] - } - }, - "todohighlight.maxFilesForSearch": { - "type": "number", - "default": 5120, - "description": "Max files for searching" + "description": "style applied to the annotations. Reference the VS Code extension API to see all available properties https://code.visualstudio.com/docs/extensionAPI/vscode-api#DecorationRenderOptions ." + }, + "description": { + "type": "string", + "description": "Descripe the annotation." + } } - } + } + ] + } + }, + "todohighlight.defaultStyle": { + "type": "object", + "borderRadius": "2px", + "border": "1px solid red", + "default": { + "color": "#2196f3", + "backgroundColor": "#fffd38" + }, + "description": "default style applied to the annotations. Reference the VS Code extension API to see all available properties https://code.visualstudio.com/docs/extensionAPI/vscode-api#DecorationRenderOptions ." + }, + "todohighlight.include": { + "type": "array", + "default": [ + "**/*" + ], + "description": "a set of glob patterns that defines the files to search for. Each of the item is a glob pattern to include the files while searching for annotations. e.g. `**/*.jsx`.", + "items": { + "anyOf": [ + { + "type": "string", + "description": "a glob pattern to include the files while searching for annotations. e.g. `**/*.jsx`." + } + ] + } + }, + "todohighlight.exclude": { + "type": "array", + "default": [ + "**/.next/**", + "**/.vscode/**", + "**/*.map", + "**/*.min.*", + "**/bower_components/**", + "**/dist/**", + "**/node_modules/**" + ], + "description": "glob pattern that exclude files or directories while searching annotations.", + "items": { + "anyOf": [ + { + "type": "string", + "description": "A glob pattern to exclude the files while searching for annotations. e.g. `**/*.jsx`." + } + ] + } } - }, - "devDependencies": { - "typescript": "^2.0.3", - "vscode": "^1.0.0", - "mocha": "^2.3.3", - "eslint": "^3.6.0", - "@types/node": "^6.0.40", - "@types/mocha": "^2.2.32" + } } -} \ No newline at end of file + }, + "scripts": { + "vscode:prepublish": "npm run compile", + "compile": "tsc -p ./", + "watch": "tsc -watch -p ./", + "postinstall": "node ./node_modules/vscode/bin/install" + }, + "devDependencies": { + "@types/mocha": "^2.2.42", + "@types/node": "^7.0.43", + "tslint": "^5.8.0", + "typescript": "^2.6.1", + "vscode": "^1.1.6" + }, + "dependencies": { + "ts-debounce": "^0.3.2" + } +} diff --git a/src/HighlightExtension.ts b/src/HighlightExtension.ts new file mode 100644 index 0000000..481f813 --- /dev/null +++ b/src/HighlightExtension.ts @@ -0,0 +1,395 @@ +/* + * @author: wayou + * @date: 2018-07-15 15:35:11 + * @description: + */ + +// tslint:disable:no-console + +import { platform } from "os"; +import * as vscode from "vscode"; +import { updateCompletions } from "./completionHelper"; +import { + getAnnotationTypes, + getConfig, + getRegExpBySelection, + IAnnotations, + updatePatternData, +} from "./configHelper"; +import { EXTENSION_NAMESPACE } from "./consts"; +import { CommandTypes } from "./consts"; +import { + getAnnotationsInCurrentFile, + ICurrentAnnotationItem, + updateDecorations, +} from "./decorationHelper"; +import { + errorHandler, + getCurrentWorkspace, + getGlobPattern, + IProgressType, +} from "./util"; + +export default class HighlightExtension { + private context: vscode.ExtensionContext; + private activeEditor: vscode.TextEditor | undefined; + private config: vscode.WorkspaceConfiguration; + private annotations: IAnnotations = {}; + private regExp: RegExp | undefined; + private processing: boolean = false; + private outputChannel: vscode.OutputChannel; + + constructor(context: vscode.ExtensionContext) { + this.context = context; + this.activeEditor = vscode.window.activeTextEditor; + this.config = getConfig(); + this.outputChannel = vscode.window.createOutputChannel(EXTENSION_NAMESPACE); + this.init(); + } + + public init() { + this.registCommands(this.context); + this.setupEvents(); + + this.updateData(); + } + + public cleanup() { + return undefined; + } + + private updateData() { + this._updatePatternData(); + this._updateCompletions(); + this._updateDecorations(); + } + + private _updateDecorations() { + updateDecorations( + this.config, + this.annotations, + this.activeEditor, + this.regExp, + ); + } + + private _updatePatternData() { + const result = updatePatternData(this.config, this.annotations); + this.regExp = result.regExp; + this.annotations = result.annotations; + } + + private _updateCompletions() { + updateCompletions(this.config); + } + + /** + * process the file search + * @param files a set of `Uri`s to process + * @param choosenAnnotationType a set of selected annotation types to search + * @param progress a `Progress` represents the processing progress + * @param cancelToken a token witch cancels the task + */ + private async processFiles( + files: vscode.Uri[], + choosenAnnotationType: string[], + progress: vscode.Progress, + cancelToken: vscode.CancellationToken, + ) { + let annotationCount = 0; + let index = 0; + const totalFilesCount = files.length; + const regExp = getRegExpBySelection(choosenAnnotationType); + this.outputChannel.clear(); + + const toggleURI = this.config.get("toggleURI", false); + // NOTE: see issue https://github.com/Microsoft/vscode/issues/586 + let uriSymbol = toggleURI ? "#" : ":"; + if (platform() === "linux") { + uriSymbol = toggleURI ? ":" : "#"; + } + + const processFile = async (file: vscode.Uri): Promise => { + const relativeFilePath = vscode.workspace.asRelativePath(file.fsPath); + progress.report({ + message: `${index + 1}/${totalFilesCount} ${relativeFilePath}`, + increment: index / totalFilesCount, + }); + + try { + const textDocument = await vscode.workspace.openTextDocument(file); + // ---- annotation parse start ---- + const fileContent = textDocument.getText(); + let match: RegExpExecArray | null; + // tslint:disable-next-line:no-conditional-assignment + while ((match = regExp.exec(fileContent))) { + annotationCount++; + const positionOfMatchedAnnotation = textDocument.positionAt( + match.index, + ); + const line = positionOfMatchedAnnotation.line; + const col = positionOfMatchedAnnotation.character; + const ouputContent = textDocument.getText( + new vscode.Range( + positionOfMatchedAnnotation, + textDocument.lineAt(line).range.end, + ), + ); + + const colPosition = uriSymbol === "#" ? "" : `${uriSymbol}${col + 1}`; + const fileURI = `${file.path}${uriSymbol}${line + 1}${colPosition}`; + + this.outputChannel.appendLine( + `#${annotationCount}: ${fileURI} \n${ouputContent}\n`, + ); + } + // ---- annotation parse end ---- + + if ( + index < totalFilesCount - 1 && + !cancelToken.isCancellationRequested + ) { + index++; + return processFile(files[index]); + } else { + this.fileProcessDone(index, annotationCount); + Promise.resolve(); + } + } catch (error) { + console.log(`open ${file.fsPath} failed, \n ${error}`); + // NOTE: cause all file types are included by default for the user convenience, + // (no need to manully config the `include` option) + // here we need to skip errors that raised by opening a none-text file, a binary file for example. + // continue to next and ignore the error + // reject(reason); + this.fileProcessDone(index, annotationCount); + } + }; + return processFile(files[index]); + } + + private fileProcessDone(index: number, annotationCount: number) { + console.log(`file processing done!`); + this.outputChannel.appendLine( + `Searched ${index + 1} file(s), found ${annotationCount} annotation(s).`, + ); + this.outputChannel.appendLine( + "Tip: If the file uri's not clickable, try config `todohighlight.toggleURI` to `true`.", + ); + this.outputChannel.show(); + } + + /** + * + * @param choosenAnnotationType the selected pattern + * @param isListAll search current file or whole project + */ + private listAnnotations( + choosenAnnotationType: string[], + isListAll: boolean = false, + ) { + if (this.processing) { + vscode.window.showInformationMessage( + `[${EXTENSION_NAMESPACE}] Searching already in progress, cancel the previous to start new search.`, + ); + return; + } + + vscode.window + .withProgress( + { + cancellable: true, + location: vscode.ProgressLocation.Notification, + title: `[${EXTENSION_NAMESPACE}] searching annotations`, + }, + ( + progress: vscode.Progress, + cancelToken: vscode.CancellationToken, + ) => { + this.processing = true; + return this.searchTask( + isListAll, + cancelToken, + choosenAnnotationType, + progress, + ); + }, + ) + .then( + () => { + this.processing = false; + console.log("search progress done!"); + }, + (error: any) => { + this.processing = false; + errorHandler(error); + }, + ); + } + + private async searchTask( + isListAll: boolean, + cancelToken: vscode.CancellationToken, + choosenAnnotationType: string[], + progress: vscode.Progress, + ) { + const workspaceFolder = getCurrentWorkspace(); + if (!workspaceFolder) { + return; + } + const include = new vscode.RelativePattern( + workspaceFolder, + getGlobPattern(this.config.get("include", [])), + ); + + const exclude = getGlobPattern( + this.config.get("exclude", []), + ); + + let files: vscode.Uri[] = this.activeEditor + ? [this.activeEditor.document.uri] + : []; + + if (isListAll) { + try { + files = await vscode.workspace.findFiles( + include, + exclude, + undefined, + cancelToken, + ); + } catch (error) { + errorHandler(error); + } + } + + return this.processFiles( + files, + choosenAnnotationType, + progress, + cancelToken, + ); + } + + /** + * inital commands + * @param context ExtensionContext + */ + private registCommands(context: vscode.ExtensionContext) { + context.subscriptions.push( + vscode.commands.registerCommand(CommandTypes.TOGGLE_HIGHLIGHT, () => { + this.config + .update("isEnable", !this.config.get("isEnable"), true) + .then(() => { + this.config = getConfig(); + this._updateDecorations(); + }); + }), + ); + + context.subscriptions.push( + vscode.commands.registerCommand(CommandTypes.TOGGLE_URI, () => { + this.config + .update("toggleURI", !this.config.get("toggleURI"), false) + .then(() => { + this.config = getConfig(); + this._updateDecorations(); + }); + }), + ); + + context.subscriptions.push( + vscode.commands.registerCommand(CommandTypes.LIST_ANNOTATIONS, () => { + const annotationTypes = getAnnotationsInCurrentFile( + this.activeEditor, + this.regExp, + this.config, + this.annotations, + ); + if (annotationTypes.length === 0) { + vscode.window.showInformationMessage( + `No annotations found in current file.`, + ); + return; + } + vscode.window + .showQuickPick(annotationTypes, { + placeHolder: `select annotations to list within current file...`, + canPickMany: true, + }) + .then((choosenAnnotationTypes) => { + if (choosenAnnotationTypes && choosenAnnotationTypes.length > 0) { + const annotations = choosenAnnotationTypes.map((item) => { + return item.pattern; + }); + this.listAnnotations(annotations); + } else { + vscode.window.showInformationMessage( + `[${EXTENSION_NAMESPACE}] no items are chosen.`, + ); + } + }); + }), + ); + + context.subscriptions.push( + vscode.commands.registerCommand(CommandTypes.LIST_ALL_ANNOTATIONS, () => { + const annotationTypes = getAnnotationTypes(this.annotations); + vscode.window + .showQuickPick(annotationTypes, { + placeHolder: `pick annotations to search...`, + canPickMany: true, + }) + .then((choosenAnnotationType) => { + if (choosenAnnotationType && choosenAnnotationType.length > 0) { + this.listAnnotations(choosenAnnotationType, true); + } else { + vscode.window.showInformationMessage( + `[${EXTENSION_NAMESPACE}] dismissed for no items are choosen.`, + ); + } + }); + }), + ); + } + + /** + * events binding + */ + private setupEvents() { + vscode.window.onDidChangeActiveTextEditor( + (editor) => { + this.activeEditor = editor; + if (editor) { + this._updateDecorations(); + } + }, + this, + this.context.subscriptions, + ); + + vscode.workspace.onDidChangeTextDocument( + (event) => { + if ( + this.activeEditor && + event.document === this.activeEditor.document + ) { + this._updateDecorations(); + } + }, + this, + this.context.subscriptions, + ); + + vscode.workspace.onDidChangeConfiguration( + (event) => { + if (event.affectsConfiguration(EXTENSION_NAMESPACE)) { + this.config = getConfig(); + this.updateData(); + } + }, + this, + this.context.subscriptions, + ); + } +} diff --git a/src/completionHelper.ts b/src/completionHelper.ts new file mode 100644 index 0000000..0d3bbe0 --- /dev/null +++ b/src/completionHelper.ts @@ -0,0 +1,51 @@ +import * as vscode from "vscode"; +import { IConfigAnnotation } from "./configHelper"; + +export interface ICompletions { + [pattern: string]: vscode.CompletionItem; +} + +let completionItemProvider: vscode.Disposable; + +/** + * update the completion registed to the editor + * @param config a instance of `WorkspaceConfiguration` + */ +export function updateCompletions(config: vscode.WorkspaceConfiguration) { + const configAnnotations = config.get>( + "keywords", + [], + ); + const completions: vscode.CompletionItem[] = configAnnotations.map( + (annotation: string | IConfigAnnotation) => { + const pattern = + typeof annotation === "object" ? annotation.pattern : annotation; + const description = + typeof annotation === "object" && annotation.description + ? annotation.description + : ""; + const item = new vscode.CompletionItem( + pattern, + vscode.CompletionItemKind.Text, + ); + if (description) { + item.documentation = description; + } + return item; + }, + ); + + if (completionItemProvider) { + completionItemProvider.dispose(); + } + completionItemProvider = vscode.languages.registerCompletionItemProvider( + { + scheme: "file", + }, + { + provideCompletionItems() { + return completions; + }, + }, + ); +} diff --git a/src/configHelper.ts b/src/configHelper.ts new file mode 100644 index 0000000..bf3a3cb --- /dev/null +++ b/src/configHelper.ts @@ -0,0 +1,112 @@ +/* + * @author: wayou + * @date: 2018-07-15 15:35:22 + * @description: + */ + +import * as vscode from "vscode"; +import { EXTENSION_NAMESPACE } from "./consts"; +import { errorHandler } from "./util"; + +export interface IConfigAnnotation { + pattern: string; + style?: vscode.DecorationRenderOptions; + description?: string; +} + +export interface IAnnotations { + [pattern: string]: vscode.TextEditorDecorationType; +} + +interface IPatternData { + regExp: RegExp; + annotations: IAnnotations; +} + +export function getConfig() { + return vscode.workspace.getConfiguration(EXTENSION_NAMESPACE); +} + +/** + * - convert keywords to key-value object {[patter]:decorationType} + * - merge all patterns into one regexp + * @param {WorkspaceConfiguration} config + * @param {IAnnotations} annotations + * @returns {IPatternData} + */ +export function updatePatternData( + config: vscode.WorkspaceConfiguration, + annotations: IAnnotations, +): IPatternData { + const configAnnotations = config.get>( + "keywords", + [], + ); + const defaultStyle = config.get( + "defaultStyle", + {}, + ); + const regExp: string[] = []; + configAnnotations.forEach((configAnnotation) => { + getDecorationType(defaultStyle, annotations, configAnnotation); + const patternString = getRegExp4Annotation(configAnnotation); + if (patternString) { + regExp.push(patternString); + } + }); + + const flag = config.get("isCaseSensitive", true) ? "g" : "gi"; + + return { + regExp: new RegExp(`${regExp.join("|")}`, flag), + annotations, + }; +} + +// clear the existing ones and create new one based on the config +export function getDecorationType( + defaultStyle: vscode.DecorationRenderOptions, + types: IAnnotations, + annotation: string | IConfigAnnotation, +) { + try { + const pattern = + typeof annotation === "object" ? annotation.pattern : annotation; + const style = + typeof annotation === "object" && annotation.style + ? annotation.style + : defaultStyle; + if (types[pattern]) { + types[pattern].dispose(); + } + types[pattern] = vscode.window.createTextEditorDecorationType(style); + } catch (error) { + errorHandler( + error, + "`todohighlight.keywords` does not match the schema, check and try again.", + ); + } +} + +function getRegExp4Annotation( + annotation: string | IConfigAnnotation, +): string | undefined { + try { + return typeof annotation === "object" ? annotation.pattern : annotation; + } catch (error) { + errorHandler( + error, + "`todohighlight.keywords` does not match the schema, check and try again.", + ); + } +} + +export function getRegExpBySelection(choosenAnnotationType: string[]): RegExp { + const flag = `g${getConfig().get("isCaseSensitive") ? "" : "i"}`; + return new RegExp(choosenAnnotationType.join("|"), flag); +} + +export const getAnnotationTypes = (annotations: IAnnotations): string[] => { + const annotationTypes = Object.keys(annotations); + return annotationTypes; +}; diff --git a/src/consts.ts b/src/consts.ts new file mode 100644 index 0000000..291895b --- /dev/null +++ b/src/consts.ts @@ -0,0 +1,19 @@ +/* + * @author: wayou + * @date: 2018-07-15 15:35:30 + * @description: + */ + +export const PUBLISHER_NAME = "wayou"; +export const EXTENSION_NAME = "vscode-todo-highlight"; +export const EXTENSION_NAMESPACE = "todohighlight"; + +// urls longer than this will raise github `414 Request-URI Too Large` error +export const GITHUB_HEADER_SIZE_LIMIT = 8195; + +export enum CommandTypes { + TOGGLE_HIGHLIGHT = "todohighlight.toggleHighlight", + TOGGLE_URI = "todohighlight.toggleURI", + LIST_ANNOTATIONS = "todohighlight.listAnnotations", + LIST_ALL_ANNOTATIONS = "todohighlight.listAllAnnotations", +} diff --git a/src/decorationHelper.ts b/src/decorationHelper.ts new file mode 100644 index 0000000..9355a56 --- /dev/null +++ b/src/decorationHelper.ts @@ -0,0 +1,112 @@ +/* + * @author: wayou + * @date: 2018-07-15 15:35:38 + * @description: + */ + +import { debounce } from "ts-debounce"; +import * as vscode from "vscode"; +import { IAnnotations } from "./configHelper"; + +export interface ICurrentAnnotationItem { + label: string; + count: number; + pattern: string; +} + +export const updateDecorations = debounce( + ( + config: vscode.WorkspaceConfiguration, + annotations: IAnnotations, + activeEditor: vscode.TextEditor | undefined, + regExp: RegExp | undefined, + ) => { + const isCaseSensitive = config.get("isCaseSensitive", true); + const isEnable = config.get("isEnable", true); + const flag = isCaseSensitive ? "g" : "gi"; + if (!activeEditor || !regExp) { + return []; + } + + const text = activeEditor.document.getText(); + + const tmpRanges: { + [pattern: string]: vscode.Range[]; + } = {}; + + let match: RegExpExecArray | null; + // tslint:disable-next-line:no-conditional-assignment + while ((match = regExp.exec(text))) { + const matchedAnnotation = match[0]; + // reveal the pattern that generate the result + const originalPattern = Object.keys(annotations).find((pattern) => { + return new RegExp(`^${pattern}$`, flag).test(matchedAnnotation); + }); + if (originalPattern) { + const startPos = activeEditor.document.positionAt(match.index); + const endPos = activeEditor.document.positionAt( + match.index + match[0].length, + ); + const range = new vscode.Range(startPos, endPos); + + if (!tmpRanges[originalPattern]) { + tmpRanges[originalPattern] = [range]; + } else { + tmpRanges[originalPattern].push(range); + } + } + } + + Object.keys(annotations).forEach((pattern) => { + const decorationType = annotations[pattern]; + if (isEnable && tmpRanges[pattern]) { + activeEditor.setDecorations(decorationType, tmpRanges[pattern]); + } else { + activeEditor.setDecorations(decorationType, []); + } + }); + }, + 50, +); + +export function getAnnotationsInCurrentFile( + activeEditor: vscode.TextEditor | undefined, + regExp: RegExp | undefined, + config: vscode.WorkspaceConfiguration, + annotations: IAnnotations, +): ICurrentAnnotationItem[] { + if (!activeEditor || !regExp) { + return []; + } + const isCaseSensitive = config.get("isCaseSensitive", true); + const flag = isCaseSensitive ? "g" : "gi"; + const text = activeEditor.document.getText(); + // const result: string[] = []; + const result: { [pattern: string]: ICurrentAnnotationItem } = {}; + let match: RegExpExecArray | null; + // tslint:disable-next-line:no-conditional-assignment + while ((match = regExp.exec(text))) { + const matchedAnnotation = match[0]; + const originalPattern = Object.keys(annotations).find((pattern) => { + return new RegExp(`^${pattern}$`, flag).test(matchedAnnotation); + }); + if (originalPattern) { + if (result[originalPattern]) { + result[originalPattern].count += 1; + result[originalPattern].pattern = originalPattern; + result[originalPattern].label = `${originalPattern} (${ + result[originalPattern].count + })`; + } else { + result[originalPattern] = { + label: `${originalPattern} (1)`, + count: 1, + pattern: originalPattern, + }; + } + } + } + return Object.keys(result).map((key) => { + return result[key]; + }); +} diff --git a/src/extension.js b/src/extension.js deleted file mode 100644 index 8ae0439..0000000 --- a/src/extension.js +++ /dev/null @@ -1,177 +0,0 @@ -/** - * vscode plugin for highlighting TODOs and FIXMEs within your code - * - * NOTE: each decoration type has a unique key, the highlight and clear highight functionality are based on it - */ - -var vscode = require('vscode'); -var util = require('./util'); -var window = vscode.window; -var workspace = vscode.workspace; - -function activate(context) { - - var timeout = null; - var activeEditor = window.activeTextEditor; - var isCaseSensitive, assembledData, decorationTypes, pattern, styleForRegExp, keywordsPattern; - var workspaceState = context.workspaceState; - - var settings = workspace.getConfiguration('todohighlight'); - - init(settings); - - context.subscriptions.push(vscode.commands.registerCommand('todohighlight.toggleHighlight', function () { - settings.update('isEnable', !settings.get('isEnable'), true).then(function () { - triggerUpdateDecorations(); - }); - })) - - context.subscriptions.push(vscode.commands.registerCommand('todohighlight.listAnnotations', function () { - if (keywordsPattern.trim()) { - util.searchAnnotations(workspaceState, pattern, util.annotationsFound); - } else { - if (!assembledData) return; - var availableAnnotationTypes = Object.keys(assembledData); - availableAnnotationTypes.unshift('ALL'); - util.chooseAnnotationType(availableAnnotationTypes).then(function (annotationType) { - if (!annotationType) return; - var searchPattern = pattern; - if (annotationType != 'ALL') { - annotationType = util.escapeRegExp(annotationType); - searchPattern = new RegExp(annotationType, isCaseSensitive ? 'g' : 'gi'); - } - util.searchAnnotations(workspaceState, searchPattern, util.annotationsFound); - }); - } - })); - - context.subscriptions.push(vscode.commands.registerCommand('todohighlight.showOutputChannel', function () { - var annotationList = workspaceState.get('annotationList', []); - util.showOutputChannel(annotationList); - })); - - if (activeEditor) { - triggerUpdateDecorations(); - } - - window.onDidChangeActiveTextEditor(function (editor) { - activeEditor = editor; - if (editor) { - triggerUpdateDecorations(); - } - }, null, context.subscriptions); - - workspace.onDidChangeTextDocument(function (event) { - if (activeEditor && event.document === activeEditor.document) { - triggerUpdateDecorations(); - } - }, null, context.subscriptions); - - workspace.onDidChangeConfiguration(function () { - settings = workspace.getConfiguration('todohighlight'); - - //NOTE: if disabled, do not re-initialize the data or we will not be able to clear the style immediatly via 'toggle highlight' command - if (!settings.get('isEnable')) return; - - init(settings); - triggerUpdateDecorations(); - }, null, context.subscriptions); - - function updateDecorations() { - - if (!activeEditor || !activeEditor.document) { - return; - } - - var text = activeEditor.document.getText(); - var mathes = {}, match; - while (match = pattern.exec(text)) { - var startPos = activeEditor.document.positionAt(match.index); - var endPos = activeEditor.document.positionAt(match.index + match[0].length); - var decoration = { - range: new vscode.Range(startPos, endPos) - }; - - var matchedValue = match[0]; - if (!isCaseSensitive) { - matchedValue = matchedValue.toUpperCase(); - } - - if (mathes[matchedValue]) { - mathes[matchedValue].push(decoration); - } else { - mathes[matchedValue] = [decoration]; - } - - if (keywordsPattern.trim() && !decorationTypes[matchedValue]) { - decorationTypes[matchedValue] = window.createTextEditorDecorationType(styleForRegExp); - } - } - - Object.keys(decorationTypes).forEach((v) => { - if (!isCaseSensitive) { - v = v.toUpperCase(); - } - var rangeOption = settings.get('isEnable') && mathes[v] ? mathes[v] : []; - var decorationType = decorationTypes[v]; - activeEditor.setDecorations(decorationType, rangeOption); - }) - } - - function init(settings) { - var customDefaultStyle = settings.get('defaultStyle'); - keywordsPattern = settings.get('keywordsPattern'); - isCaseSensitive = settings.get('isCaseSensitive', true); - - if (!window.statusBarItem) { - window.statusBarItem = util.createStatusBarItem(); - } - if (!window.outputChannel) { - window.outputChannel = window.createOutputChannel('TodoHighlight'); - } - - decorationTypes = {}; - - if (keywordsPattern.trim()) { - styleForRegExp = Object.assign({}, util.DEFAULT_STYLE, customDefaultStyle, { - overviewRulerLane: vscode.OverviewRulerLane.Right - }); - pattern = keywordsPattern; - } else { - assembledData = util.getAssembledData(settings.get('keywords'), customDefaultStyle, isCaseSensitive); - Object.keys(assembledData).forEach((v) => { - if (!isCaseSensitive) { - v = v.toUpperCase() - } - - var mergedStyle = Object.assign({}, { - overviewRulerLane: vscode.OverviewRulerLane.Right - }, assembledData[v]); - - if (!mergedStyle.overviewRulerColor) { - // use backgroundColor as the default overviewRulerColor if not specified by the user setting - mergedStyle.overviewRulerColor = mergedStyle.backgroundColor; - } - - decorationTypes[v] = window.createTextEditorDecorationType(mergedStyle); - }); - - pattern = Object.keys(assembledData).map((v) => { - return util.escapeRegExp(v); - }).join('|'); - } - - pattern = new RegExp(pattern, 'gi'); - if (isCaseSensitive) { - pattern = new RegExp(pattern, 'g'); - } - - } - - function triggerUpdateDecorations() { - timeout && clearTimeout(timeout); - timeout = setTimeout(updateDecorations, 0); - } -} - -exports.activate = activate; diff --git a/src/extension.ts b/src/extension.ts new file mode 100644 index 0000000..5a115db --- /dev/null +++ b/src/extension.ts @@ -0,0 +1,19 @@ +/* + * @author: wayou + * @date: 2018-07-15 15:31:24 + * @description: a vscode extension add text decoration. + */ + +import { ExtensionContext } from "vscode"; + +import HighlightExtension from "./HighlightExtension"; + +let highlightExtension: HighlightExtension; + +export function activate(context: ExtensionContext) { + highlightExtension = new HighlightExtension(context); +} + +export function deactivate() { + highlightExtension.cleanup(); +} diff --git a/src/typings.d.ts b/src/typings.d.ts new file mode 100644 index 0000000..09eae41 --- /dev/null +++ b/src/typings.d.ts @@ -0,0 +1,4 @@ +declare module "*.json" { + const value: any; + export default value; +} \ No newline at end of file diff --git a/src/util.js b/src/util.js deleted file mode 100644 index e1c8548..0000000 --- a/src/util.js +++ /dev/null @@ -1,260 +0,0 @@ -var vscode = require('vscode'); -var os = require("os"); -var window = vscode.window; -var workspace = vscode.workspace; - -var defaultIcon = '$(checklist)'; -var zapIcon = '$(zap)'; -var defaultMsg = '0'; - -var DEFAULT_KEYWORDS = { - "TODO:": { - text: "TODO:", - color: '#fff', - backgroundColor: '#ffbd2a', - overviewRulerColor: 'rgba(255,189,42,0.8)' - }, - "FIXME:": { - text: "FIXME:", - color: '#fff', - backgroundColor: '#f06292', - overviewRulerColor: 'rgba(240,98,146,0.8)' - } -}; - -var DEFAULT_STYLE = { - color: "#2196f3", - backgroundColor: "#ffeb3b", -}; - -function getAssembledData(keywords, customDefaultStyle, isCaseSensitive) { - var result = {} - keywords.forEach((v) => { - v = typeof v == 'string' ? { text: v } : v; - var text = v.text; - if (!text) return;//NOTE: in case of the text is empty - - if (!isCaseSensitive) { - text = text.toUpperCase(); - } - - if (text == 'TODO:' || text == 'FIXME:') { - v = Object.assign({}, DEFAULT_KEYWORDS[text], v); - } - result[text] = Object.assign({}, DEFAULT_STYLE, customDefaultStyle, v); - }) - - Object.keys(DEFAULT_KEYWORDS).forEach((v) => { - if (!result[v]) { - result[v] = Object.assign({}, DEFAULT_STYLE, customDefaultStyle, DEFAULT_KEYWORDS[v]); - } - }); - - return result; -} - -function chooseAnnotationType(availableAnnotationTypes) { - return window.showQuickPick(availableAnnotationTypes, {}); -} - -//get the include/exclude config -function getPathes(config) { - return Array.isArray(config) ? - '{' + config.join(',') + '}' - : (typeof config == 'string' ? config : ''); -} - -function searchAnnotations(workspaceState, pattern, callback) { - - var settings = workspace.getConfiguration('todohighlight'); - var includePattern = getPathes(settings.get('include')) || '{**/*}'; - var excludePattern = getPathes(settings.get('exclude')); - var limitationForSearch = settings.get('maxFilesForSearch', 5120); - - var statusMsg = ` Searching...`; - - window.processing = true; - - setStatusMsg(zapIcon, statusMsg); - - workspace.findFiles(includePattern, excludePattern, limitationForSearch).then(function (files) { - - if (!files || files.length === 0) { - callback({ message: 'No files found' }); - return; - } - - var totalFiles = files.length, - progress = 0, - times = 0, - annotations = {}, - annotationList = []; - - function file_iterated() { - times++; - progress = Math.floor(times / totalFiles * 100); - - setStatusMsg(zapIcon, progress + '% ' + statusMsg); - - if (times === totalFiles || window.manullyCancel) { - window.processing = true; - workspaceState.update('annotationList', annotationList); - callback(null, annotations, annotationList); - } - } - - for (var i = 0; i < totalFiles; i++) { - - workspace.openTextDocument(files[i]).then(function (file) { - searchAnnotationInFile(file, annotations, annotationList, pattern); - file_iterated(); - }, function (err) { - errorHandler(err); - file_iterated(); - }); - - } - - }, function (err) { - errorHandler(err); - }); -} - -function searchAnnotationInFile(file, annotations, annotationList, regexp) { - var fileInUri = file.uri.toString(); - var pathWithoutFile = fileInUri.substring(7, fileInUri.length); - - for (var line = 0; line < file.lineCount; line++) { - var lineText = file.lineAt(line).text; - var match = lineText.match(regexp); - if (match !== null) { - if (!annotations.hasOwnProperty(pathWithoutFile)) { - annotations[pathWithoutFile] = []; - } - var content = getContent(lineText, match); - if (content.length > 500) { - content = content.substring(0, 500).trim() + '...'; - } - var locationInfo = getLocationInfo(fileInUri, pathWithoutFile, lineText, line, match); - - var annotation = { - uri: locationInfo.uri, - label: content, - detail: locationInfo.relativePath, - lineNum: line, - fileName: locationInfo.absPath, - startCol: locationInfo.startCol, - endCol: locationInfo.endCol - }; - annotationList.push(annotation); - annotations[pathWithoutFile].push(annotation); - } - } -} - -function annotationsFound(err, annotations, annotationList) { - if (err) { - console.log('todohighlight err:', err); - setStatusMsg(defaultIcon, defaultMsg); - return; - } - - var resultNum = annotationList.length; - var tooltip = resultNum + ' result(s) found'; - setStatusMsg(defaultIcon, resultNum, tooltip); - showOutputChannel(annotationList); -} - -function showOutputChannel(data) { - if (!window.outputChannel) return; - window.outputChannel.clear(); - - if (data.length === 0) { - window.showInformationMessage('No results'); - return; - } - - var settings = workspace.getConfiguration('todohighlight'); - var toggleURI = settings.get('toggleURI', false); - - data.forEach(function (v, i, a) { - // due to an issue of vscode(https://github.com/Microsoft/vscode/issues/586), in order to make file path clickable within the output channel,the file path differs from platform - var patternA = '#' + (i + 1) + '\t' + v.uri + '#' + (v.lineNum + 1); - var patternB = '#' + (i + 1) + '\t' + v.uri + ':' + (v.lineNum + 1) + ':' + (v.startCol + 1); - var patterns = [patternA, patternB]; - - //for windows and mac - var patternType = 0; - if (os.platform() == "linux") { - // for linux - patternType = 1; - } - if (toggleURI) { - //toggle the pattern - patternType = +!patternType; - } - window.outputChannel.appendLine(patterns[patternType]); - window.outputChannel.appendLine('\t' + v.label + '\n'); - }); - window.outputChannel.show(); -} - -function getContent(lineText, match) { - return lineText.substring(lineText.indexOf(match[0]), lineText.length); -}; - -function getLocationInfo(fileInUri, pathWithoutFile, lineText, line, match) { - var rootPath = workspace.rootPath + '/'; - var outputFile = pathWithoutFile.replace(rootPath, ''); - var startCol = lineText.indexOf(match[0]); - var endCol = lineText.length; - var location = outputFile + ' ' + (line + 1) + ':' + (startCol + 1); - - return { - uri: fileInUri, - absPath: pathWithoutFile, - relativePath: location, - startCol: startCol, - endCol: endCol - }; -}; - -function createStatusBarItem() { - var statusBarItem = window.createStatusBarItem(vscode.StatusBarAlignment.Left); - statusBarItem.text = defaultIcon + defaultMsg; - statusBarItem.tooltip = 'List annotations'; - statusBarItem.command = 'todohighlight.showOutputChannel'; - return statusBarItem; -}; - -function errorHandler(err) { - window.processing = true; - setStatusMsg(defaultIcon, defaultMsg); - console.log('todohighlight err:', err); -} - -function setStatusMsg(icon, msg, tooltip) { - if (window.statusBarItem) { - window.statusBarItem.text = `${icon} ${msg}` || ''; - if (tooltip) { - window.statusBarItem.tooltip = tooltip; - } - window.statusBarItem.show(); - } -} - -function escapeRegExp(s) { - return s.replace(/[-\/\\^$*+?.()|[\]{}]/g, '\\$&'); -} - -module.exports = { - DEFAULT_STYLE, - getAssembledData, - chooseAnnotationType, - searchAnnotations, - annotationsFound, - createStatusBarItem, - setStatusMsg, - showOutputChannel, - escapeRegExp -}; diff --git a/src/util.ts b/src/util.ts new file mode 100644 index 0000000..ed9ef87 --- /dev/null +++ b/src/util.ts @@ -0,0 +1,72 @@ +import * as os from "os"; +import * as vscode from "vscode"; +import { workspace, WorkspaceFolder } from "vscode"; +import * as pkg from "../package.json"; +import { GITHUB_HEADER_SIZE_LIMIT } from "./consts"; + +export function getIssueUrl(error: any) { + const breakSymbol = "%0A"; + const envInfo = `OS: ${os.platform()} ${os.release()} ${breakSymbol} ${ + vscode.env.appName + }: ${vscode.version} ${breakSymbol} ${(pkg as any).name}: ${ + (pkg as any).version + }`; + let formatedStack = "no stack info."; + const stack = error.stack; + if (stack) { + if (typeof stack === "string") { + formatedStack = stack; + } else if (stack.join) { + formatedStack = stack.join(breakSymbol); + } + } + const errorInfo = ` + \`\`\`${breakSymbol} + ${error.name}:${error.message} ${breakSymbol}${breakSymbol} ${formatedStack} + ${breakSymbol}\`\`\` + `; + const body = encodeURI(`${envInfo}${breakSymbol}${breakSymbol}${errorInfo}`); + const bodyWithoutErrorStack = encodeURI(`${envInfo}`); + let url = `${(pkg as any).bugs.url}/new?title=&body=${body}`; + if (url.length > GITHUB_HEADER_SIZE_LIMIT) { + url = `${(pkg as any).bugs.url}/new?title=&body=${bodyWithoutErrorStack}`; + } + return url; +} + +export function getCurrentWorkspace(): WorkspaceFolder | undefined { + if (workspace.workspaceFolders === undefined) { + return undefined; + } + return workspace.workspaceFolders.filter((i) => i.name === workspace.name)[0]; +} + +export function getGlobPattern(source: string | string[]): string { + return Array.isArray(source) + ? "{" + source.join(",") + "}" + : typeof source === "string" + ? source + : ""; +} + +export function errorHandler(error: any, msg?: string): void { + const actions = ["FILE AN ISSUE", "CLOSE"]; + vscode.window + .showErrorMessage( + `${error.name || "Error"}:${msg || error.message || '"unknown error"'}`, + ...actions, + ) + .then((action) => { + if (action === actions[0]) { + vscode.commands.executeCommand( + "vscode.open", + vscode.Uri.parse(getIssueUrl(error)), + ); + } + }); +} + +export interface IProgressType { + message?: string | undefined; + increment?: number | undefined; +} diff --git a/test/extension.test.js b/test/extension.test.js deleted file mode 100644 index c3c1517..0000000 --- a/test/extension.test.js +++ /dev/null @@ -1,24 +0,0 @@ -/* global suite, test */ - -// -// Note: This example test is leveraging the Mocha test framework. -// Please refer to their documentation on https://mochajs.org/ for help. -// - -// The module 'assert' provides assertion methods from node -var assert = require('assert'); - -// You can import and use all API from the 'vscode' module -// as well as import your extension to test it -var vscode = require('vscode'); -var myExtension = require('../extension'); - -// Defines a Mocha test suite to group tests of similar kind together -suite("Extension Tests", function() { - - // Defines a Mocha unit test - test("Something 1", function() { - assert.equal(-1, [1, 2, 3].indexOf(5)); - assert.equal(-1, [1, 2, 3].indexOf(0)); - }); -}); \ No newline at end of file diff --git a/test/index.js b/test/index.js deleted file mode 100644 index 5604517..0000000 --- a/test/index.js +++ /dev/null @@ -1,22 +0,0 @@ -// -// PLEASE DO NOT MODIFY / DELETE UNLESS YOU KNOW WHAT YOU ARE DOING -// -// This file is providing the test runner to use when running extension tests. -// By default the test runner in use is Mocha based. -// -// You can provide your own test runner if you want to override it by exporting -// a function run(testRoot: string, clb: (error:Error) => void) that the extension -// host can call to run the tests. The test runner is expected to use console.log -// to report the results back to the caller. When the tests are finished, return -// a possible error to the callback or null if none. - -var testRunner = require('vscode/lib/testrunner'); - -// You can directly control Mocha options by uncommenting the following lines -// See https://github.com/mochajs/mocha/wiki/Using-mocha-programmatically#set-options for more info -testRunner.configure({ - ui: 'tdd', // the TDD UI is being used in extension.test.js (suite, test, etc.) - useColors: true // colored output from test results -}); - -module.exports = testRunner; \ No newline at end of file diff --git a/tsconfig.json b/tsconfig.json new file mode 100644 index 0000000..8aa5312 --- /dev/null +++ b/tsconfig.json @@ -0,0 +1,23 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es6", + "outDir": "out", + "lib": [ + "es6" + ], + "sourceMap": true, + "rootDir": "src", + /* Strict Type-Checking Option */ + "strict": true, /* enable all strict type-checking options */ + /* Additional Checks */ + "noUnusedLocals": true /* Report errors on unused locals. */ + // "noImplicitReturns": true, /* Report error when not all code paths in function return a value. */ + // "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ + // "noUnusedParameters": true, /* Report errors on unused parameters. */ + }, + "exclude": [ + "node_modules", + ".vscode-test" + ] +} \ No newline at end of file diff --git a/tslint.json b/tslint.json new file mode 100644 index 0000000..77f9221 --- /dev/null +++ b/tslint.json @@ -0,0 +1,14 @@ +{ + "extends": "tslint:recommended", + "rules": { + "object-literal-sort-keys": false, + "no-string-throw": true, + "no-unused-expression": true, + "no-duplicate-variable": true, + "curly": true, + "class-name": true, + "semicolon": [true, "always"], + "triple-equals": true + }, + "defaultSeverity": "warning" +} diff --git a/vscode-todo-highlight-0.5.12.vsix b/vscode-todo-highlight-0.5.12.vsix deleted file mode 100644 index 34e0173..0000000 Binary files a/vscode-todo-highlight-0.5.12.vsix and /dev/null differ