Add nested commands to the Command Palette #5614

Closed
opened 2026-01-31 00:17:30 +00:00 by claunia · 8 comments
Owner

Originally created by @zadjii-msft on GitHub (Dec 17, 2019).

The initial design of the command palette only covers singular commands, but includes a follow-up to support nesting commands. This way, all the commands don't appear in the menu straight away. Instead, the user must first select the parent command, to be given the sub-list.

We should support this.

Originally created by @zadjii-msft on GitHub (Dec 17, 2019). The initial design of the command palette only covers singular commands, but includes a follow-up to support nesting commands. This way, all the commands don't appear in the menu straight away. Instead, the user must first select the parent command, to be given the sub-list. We should support this.
claunia added the Resolution-Fix-CommittedArea-SettingsIssue-TaskProduct-Terminal labels 2026-01-31 00:17:30 +00:00
Author
Owner

@cryptworks commented on GitHub (Apr 16, 2020):

I would +1 to this. Recently working with the terminal profiles.json I was having fun with calling directly to the native windows SSH "ssh.exe user@addr" as its own profile. The ability to make a manuitem to call to a separate config as its own menu entry would be tremendous. Even supporting a nested entry of ssh x@x calls with a singular master config entry would be great.

@cryptworks commented on GitHub (Apr 16, 2020): I would +1 to this. Recently working with the terminal profiles.json I was having fun with calling directly to the native windows SSH "ssh.exe user@addr" as its own profile. The ability to make a manuitem to call to a separate config as its own menu entry would be tremendous. Even supporting a nested entry of ssh x@x calls with a singular master config entry would be great.
Author
Owner

@giggio commented on GitHub (Aug 17, 2020):

@zadjii-msft How do we add those nested commands? Is there a commands.json or something like that? I couldn't find it. Or is it on the settings file? If it is, I couldn't find it on schema.

Or is it not supposed to be user customizable?

@giggio commented on GitHub (Aug 17, 2020): @zadjii-msft How do we add those nested commands? Is there a `commands.json` or something like that? I couldn't find it. Or is it on the settings file? If it is, I couldn't find it on schema. Or is it not supposed to be user customizable?
Author
Owner

@zadjii-msft commented on GitHub (Aug 17, 2020):

@giggio If you're using a build that includes #6856, you can do something like the following:

        {
            "name": "Split Pane...",
            "commands": [
                {
                    "iterateOn": "profiles",
                    "name": "Split with ${profile.name}...",
                    "commands": [
                        { "command": { "action": "splitPane", "profile": "${profile.name}", "split": "auto" } },
                        { "command": { "action": "splitPane", "profile": "${profile.name}", "split": "vertical" } },
                        { "command": { "action": "splitPane", "profile": "${profile.name}", "split": "horizontal" } }
                    ]
                }
            ]
        },

Just throw that into your keybindings, and that should work.

@zadjii-msft commented on GitHub (Aug 17, 2020): @giggio If you're using a build that includes #6856, you can do something like the following: ```json { "name": "Split Pane...", "commands": [ { "iterateOn": "profiles", "name": "Split with ${profile.name}...", "commands": [ { "command": { "action": "splitPane", "profile": "${profile.name}", "split": "auto" } }, { "command": { "action": "splitPane", "profile": "${profile.name}", "split": "vertical" } }, { "command": { "action": "splitPane", "profile": "${profile.name}", "split": "horizontal" } } ] } ] }, ``` Just throw that into your `keybindings`, and that should work.
Author
Owner

@giggio commented on GitHub (Aug 17, 2020):

Perfect, it works! I was not sure where to put it. There should be an issue to update the schema.

@giggio commented on GitHub (Aug 17, 2020): Perfect, it works! I was not sure where to put it. There should be an issue to update the schema.
Author
Owner

@zadjii-msft commented on GitHub (Aug 17, 2020):

@giggio I'm purposely not updating the docs until we feel it's ready for general adoption 😉

The docs will probably be updated as a part of #7174

@zadjii-msft commented on GitHub (Aug 17, 2020): @giggio I'm purposely not updating the docs until we feel it's ready for general adoption 😉 The docs will probably be updated as a part of #7174
Author
Owner

@giggio commented on GitHub (Aug 17, 2020):

Not the docs, the schema: https://github.com/microsoft/terminal/blob/master/doc/cascadia/profiles.schema.json

@giggio commented on GitHub (Aug 17, 2020): Not the docs, the schema: https://github.com/microsoft/terminal/blob/master/doc/cascadia/profiles.schema.json
Author
Owner

@zadjii-msft commented on GitHub (Aug 17, 2020):

Sorry, in my head, the schema is part of the docs. I get how that's confusing 😛

@zadjii-msft commented on GitHub (Aug 17, 2020): Sorry, in my head, the schema is part of the docs. I get how that's confusing 😛
Author
Owner

@ghost commented on GitHub (Aug 26, 2020):

:tada:This issue was addressed in #6856, which has now been successfully released as Windows Terminal Preview v1.3.2382.0.🎉

Handy links:

@ghost commented on GitHub (Aug 26, 2020): :tada:This issue was addressed in #6856, which has now been successfully released as `Windows Terminal Preview v1.3.2382.0`.:tada: Handy links: * [Release Notes](https://github.com/microsoft/terminal/releases/tag/v1.3.2382.0) * [Store Download](https://www.microsoft.com/store/apps/9n8g5rfz9xk3?cid=storebadge&ocid=badge)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#5614