This repository has been archived by the owner on Oct 10, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(import-management): Add imports and imports under cursor (#383)
Re-Introduce the `add import` and `add import under cursor` feature. This feature was removed due to the fact, that it uses the declaration index. That index was broken and caused vscode to totally crash. I removed the "support" for javascript files, which mainly caused the crashes. This due to the fact, that compiled javascripts (like webpack results) were indexed and crashed the memory of the process.
- Loading branch information
Showing
31 changed files
with
1,473 additions
and
2,206 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,3 @@ | ||
{ | ||
"extends": "./tsconfig.base.json", | ||
"include": [ | ||
"../src/**/*" | ||
], | ||
"exclude": [ | ||
"../src/_old", | ||
"../test" | ||
] | ||
"extends": "./tsconfig.base.json" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"extends": "./tsconfig.base.json", | ||
"include": [ | ||
"../src/**/*", | ||
"../test/**/*" | ||
], | ||
"exclude": [ | ||
"../src/_old", | ||
"../test/_old", | ||
"../test/etc" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,7 +18,7 @@ | |
"Other", | ||
"Languages" | ||
], | ||
"main": "./out/extension", | ||
"main": "./out/src/extension", | ||
"author": "Christoph Bühler <[email protected]>", | ||
"license": "MIT", | ||
"contributors": [], | ||
|
@@ -58,9 +58,7 @@ | |
"build": "npm run clean && tsc -p ./config/tsconfig.build.json", | ||
"develop": "npm run clean && tsc -p .", | ||
"lint": "tslint -c ./tslint.json -p ./config/tsconfig.build.json", | ||
"test": "npm run lint && npm run clean && jest -c ./jest.json", | ||
"test:watch": "npm run clean && jest -c ./jest.json --watch --no-coverage", | ||
"test:vscode": "echo 'beside unit test with jest, there could be integration test with node ./node_modules/vscode/bin/test'", | ||
"test": "npm run lint && npm run clean && tsc -p ./config/tsconfig.test.json && node ./node_modules/vscode/bin/test", | ||
"semantic-release": "semantic-release" | ||
}, | ||
"release": { | ||
|
@@ -82,25 +80,25 @@ | |
}, | ||
"devDependencies": { | ||
"@smartive/tslint-config": "^2.0.0", | ||
"@types/jest": "^22.0.1", | ||
"@types/chai": "^4.1.1", | ||
"@types/mocha": "^2.2.46", | ||
"@types/node": "^9.3.0", | ||
"@types/reflect-metadata": "0.1.0", | ||
"cross-env": "^5.1.3", | ||
"@types/sinon": "^4.1.3", | ||
"@types/sinon-chai": "^2.7.29", | ||
"chai": "^4.1.2", | ||
"del-cli": "^1.1.0", | ||
"filewalker": "^0.1.3", | ||
"jest": "^22.1.2", | ||
"semantic-release": "^12.2.2", | ||
"semantic-release-vsce": "^1.0.2", | ||
"ts-jest": "^22.0.1", | ||
"sinon": "^4.2.0", | ||
"sinon-chai": "^2.14.0", | ||
"tslint": "^5.9.1", | ||
"tsutils": "^2.19.1", | ||
"vscode": "^1.1.10" | ||
}, | ||
"dependencies": { | ||
"inversify": "^4.9.0", | ||
"inversify-inject-decorators": "^3.1.0", | ||
"reflect-metadata": "^0.1.12", | ||
"rxjs": "^5.5.6", | ||
"tslib": "^1.8.1", | ||
"typescript": "~2.6.2", | ||
"typescript-parser": "^2.2.2", | ||
|
@@ -114,6 +112,14 @@ | |
], | ||
"contributes": { | ||
"commands": [ | ||
{ | ||
"command": "typescriptHero.index.addImport", | ||
"title": "TS Hero: Add an import to current file" | ||
}, | ||
{ | ||
"command": "typescriptHero.index.addImportUnderCursor", | ||
"title": "TS Hero: Adds the current symbol under the cursor as an import to current file" | ||
}, | ||
{ | ||
"command": "typescriptHero.imports.organize", | ||
"title": "TS Hero: Organize imports (sort and remove unused)" | ||
|
@@ -124,6 +130,16 @@ | |
} | ||
], | ||
"keybindings": [ | ||
{ | ||
"command": "typescriptHero.index.addImport", | ||
"key": "ctrl+shift+i", | ||
"when": "editorTextFocus" | ||
}, | ||
{ | ||
"command": "typescriptHero.index.addImportUnderCursor", | ||
"key": "ctrl+alt+i", | ||
"when": "editorTextFocus" | ||
}, | ||
{ | ||
"command": "typescriptHero.imports.organize", | ||
"key": "ctrl+alt+o", | ||
|
@@ -305,6 +321,32 @@ | |
], | ||
"description": "Defines the groups of the imports ordering. Multiple groups possible, see readme for instructions.", | ||
"scope": "resource" | ||
}, | ||
"typescriptHero.index.workspaceIgnorePatterns": { | ||
"type": "array", | ||
"items": { | ||
"type": "string" | ||
}, | ||
"uniqueItems": true, | ||
"default": [ | ||
"**/build/**/*", | ||
"**/out/**/*", | ||
"**/dist/**/*" | ||
], | ||
"description": "Defines partial pathes (globs) that are ignored during indexing of the **workspace**.", | ||
"scope": "resource" | ||
}, | ||
"typescriptHero.index.moduleIgnorePatterns": { | ||
"type": "array", | ||
"items": { | ||
"type": "string" | ||
}, | ||
"uniqueItems": true, | ||
"default": [ | ||
"**/node_modules/**/*" | ||
], | ||
"description": "Defines partial pathes (globs) that are ignored during indexing of the **node_modules**. This patterns are attached to the node_module/<name> of each found module.", | ||
"scope": "resource" | ||
} | ||
} | ||
} | ||
|
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.