From 8f96a71c10a76e5d53d4ab82eed1baed32797e24 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 30 Dec 2016 11:03:46 +0100 Subject: [PATCH] modernize vim-sample --- vim-sample/package.json | 91 +++++++++++++++----------- vim-sample/tsconfig.json | 8 ++- vim-sample/typings/node.d.ts | 1 - vim-sample/typings/vscode-typings.d.ts | 1 - 4 files changed, 56 insertions(+), 45 deletions(-) delete mode 100644 vim-sample/typings/node.d.ts delete mode 100644 vim-sample/typings/vscode-typings.d.ts diff --git a/vim-sample/package.json b/vim-sample/package.json index eb7eaa82..f097cb0a 100644 --- a/vim-sample/package.json +++ b/vim-sample/package.json @@ -15,44 +15,54 @@ ], "main": "./out/src/extension", "contributes": { - "keybindings": [{ - "command": "vim.goToNormalMode", - "key": "escape", - "when": "editorTextFocus && !vim.inNormalMode" - },{ - "command": "vim.clearInput", - "key": "escape", - "when": "editorTextFocus && vim.hasInput" - },{ - "command": "redo", - "key": "ctrl+r", - "mac": "cmd+r", - "when": "editorTextFocus" - },{ - "command": "e", - "key": "ctrl+e", - "when": "editorTextFocus && vim.inNormalMode" - },{ - "command": "d", - "key": "ctrl+d", - "when": "editorTextFocus && vim.inNormalMode" - },{ - "command": "f", - "key": "ctrl+f", - "when": "editorTextFocus && vim.inNormalMode" - },{ - "command": "y", - "key": "ctrl+y", - "when": "editorTextFocus && vim.inNormalMode" - },{ - "command": "u", - "key": "ctrl+u", - "when": "editorTextFocus && vim.inNormalMode" - },{ - "command": "b", - "key": "ctrl+b", - "when": "editorTextFocus && vim.inNormalMode" - }] + "keybindings": [ + { + "command": "vim.goToNormalMode", + "key": "escape", + "when": "editorTextFocus && !vim.inNormalMode" + }, + { + "command": "vim.clearInput", + "key": "escape", + "when": "editorTextFocus && vim.hasInput" + }, + { + "command": "redo", + "key": "ctrl+r", + "mac": "cmd+r", + "when": "editorTextFocus" + }, + { + "command": "e", + "key": "ctrl+e", + "when": "editorTextFocus && vim.inNormalMode" + }, + { + "command": "d", + "key": "ctrl+d", + "when": "editorTextFocus && vim.inNormalMode" + }, + { + "command": "f", + "key": "ctrl+f", + "when": "editorTextFocus && vim.inNormalMode" + }, + { + "command": "y", + "key": "ctrl+y", + "when": "editorTextFocus && vim.inNormalMode" + }, + { + "command": "u", + "key": "ctrl+u", + "when": "editorTextFocus && vim.inNormalMode" + }, + { + "command": "b", + "key": "ctrl+b", + "when": "editorTextFocus && vim.inNormalMode" + } + ] }, "scripts": { "vscode:prepublish": "node ./node_modules/vscode/bin/compile", @@ -61,6 +71,7 @@ }, "devDependencies": { "typescript": "^1.8.5", - "vscode": "^0.11.0" + "vscode": "^1.0.0", + "@types/node": "*" } -} \ No newline at end of file +} diff --git a/vim-sample/tsconfig.json b/vim-sample/tsconfig.json index 3b648aae..5aee25d9 100644 --- a/vim-sample/tsconfig.json +++ b/vim-sample/tsconfig.json @@ -3,11 +3,13 @@ "module": "commonjs", "target": "es5", "outDir": "out", - "noLib": true, + "lib": [ + "es6" + ], "sourceMap": true, - "rootDir": "." + "rootDir": "src" }, "exclude": [ "node_modules" ] -} \ No newline at end of file +} diff --git a/vim-sample/typings/node.d.ts b/vim-sample/typings/node.d.ts deleted file mode 100644 index 5ed7730b..00000000 --- a/vim-sample/typings/node.d.ts +++ /dev/null @@ -1 +0,0 @@ -/// \ No newline at end of file diff --git a/vim-sample/typings/vscode-typings.d.ts b/vim-sample/typings/vscode-typings.d.ts deleted file mode 100644 index 61430b1c..00000000 --- a/vim-sample/typings/vscode-typings.d.ts +++ /dev/null @@ -1 +0,0 @@ -///