From d2def757ef2eb3fae05fb9d7aa3d0c590eb38104 Mon Sep 17 00:00:00 2001 From: petetronic <1178561+petetronic@users.noreply.github.com> Date: Sun, 3 Nov 2024 12:23:22 -0500 Subject: [PATCH] Include shellscript extension in positron Addresses #5251 Add a conditional keybinding of Ctrl+Enter (Cmd+Enter on Mac) that sends the current selected text to the active Terminal for editor files of language id 'shellscript'. --- build/gulpfile.extensions.js | 3 +++ build/npm/dirs.js | 3 +++ extensions/shellscript/package.json | 8 ++++++++ 3 files changed, 14 insertions(+) diff --git a/build/gulpfile.extensions.js b/build/gulpfile.extensions.js index 9427a9f7660..cf88f84a107 100644 --- a/build/gulpfile.extensions.js +++ b/build/gulpfile.extensions.js @@ -78,6 +78,9 @@ const compilations = [ 'extensions/php-language-features/tsconfig.json', 'extensions/references-view/tsconfig.json', 'extensions/search-result/tsconfig.json', + // --- Start Positron --- + 'extensions/shellscript/tsconfig.json', + // --- End Positron --- 'extensions/simple-browser/tsconfig.json', 'extensions/tunnel-forwarding/tsconfig.json', 'extensions/typescript-language-features/test-workspace/tsconfig.json', diff --git a/build/npm/dirs.js b/build/npm/dirs.js index 1653c395731..726aa438a40 100644 --- a/build/npm/dirs.js +++ b/build/npm/dirs.js @@ -61,6 +61,9 @@ const dirs = [ 'extensions/php-language-features', 'extensions/references-view', 'extensions/search-result', + // --- Start Positron --- + 'extensions/shellscript', + // --- End Positron --- 'extensions/simple-browser', 'extensions/tunnel-forwarding', 'extensions/typescript-language-features', diff --git a/extensions/shellscript/package.json b/extensions/shellscript/package.json index 9a43882bb78..7e0295dbb77 100644 --- a/extensions/shellscript/package.json +++ b/extensions/shellscript/package.json @@ -13,6 +13,14 @@ }, "categories": ["Programming Languages"], "contributes": { + "keybindings": [ + { + "command": "workbench.action.terminal.runSelectedText", + "key": "ctrl+enter", + "mac": "cmd+enter", + "when": "editorTextFocus && editorLangId == shellscript" + } + ], "languages": [ { "id": "shellscript",