Skip to content

fix(docs): update shell integration settings.json codeblock #860

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 22 additions & 27 deletions TerminalDocs/tutorials/shell-integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,33 +58,28 @@ Supporting these features requires cooperation between your shell and the Termin
To enable these features in the Terminal, you'll want to add the following to your settings:

```json
"profiles":
{
"defaults":
{
// Enable marks on the scrollbar
"showMarksOnScrollbar": true,

// Needed for both pwsh, CMD and bash shell integration
"autoMarkPrompts": true,

// Add support for a right-click context menu
// You can also just bind the `showContextMenu` action
"experimental.rightClickContextMenu": true,
},
}
"actions":
[
// Scroll between prompts
{ "keys": "ctrl+up", "command": { "action": "scrollToMark", "direction": "previous" }, },
{ "keys": "ctrl+down", "command": { "action": "scrollToMark", "direction": "next" }, },

// Add the ability to select a whole command (or its output)
{ "command": { "action": "selectOutput", "direction": "prev" }, },
{ "command": { "action": "selectOutput", "direction": "next" }, },

{ "command": { "action": "selectCommand", "direction": "prev" }, },
{ "command": { "action": "selectCommand", "direction": "next" }, },
"profiles": {
"defaults": {
// Enable marks on the scrollbar
"showMarksOnScrollbar": true,

// Needed for both pwsh, CMD and bash shell integration
"autoMarkPrompts": true,

// Add support for a right-click context menu
// You can also just bind the `showContextMenu` action
"experimental.rightClickContextMenu": true,
},
},
"actions": [
// Create actions/commands for scrolling to previous/next mark
{ "command": { "action": "scrollToMark", "direction": "previous" }, "id": "Terminal.ScrollToPreviousMark" },
{ "command": { "action": "scrollToMark", "direction": "next" }, "id": "Terminal.ScrollToNextMark" }
],
"keybindings": [
// Define hotkeys/shortcuts for these actions by referencing the prior (user-)assigned IDs
{ "id": "Terminal.ScrollToPreviousMark", "keys": "ctrl+up" },
{ "id": "Terminal.ScrollToNextMark", "keys": "ctrl+down" }
]
```

Expand Down