mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-26 03:29:00 +01:00
Add worktree command (#255945)
* Basic functionality of adding worktree * Code refactoring and clean up * Remove accidentally added submodules * Specify folder destination * Remove default worktree path, always prompt for destination instead * create worktree only displayed in repo's worktree subcommands * Git - handle another error condition when detecting worktrees (#256278) * Rework creating worktree flow * Include worktree name placeholder --------- Co-authored-by: Ladislau Szomoru <3372902+lszomoru@users.noreply.github.com>
This commit is contained in:
@@ -539,6 +539,12 @@
|
||||
"category": "Git",
|
||||
"enablement": "!operationInProgress"
|
||||
},
|
||||
{
|
||||
"command": "git.createWorktree",
|
||||
"title": "%command.createWorktree%",
|
||||
"category": "Git",
|
||||
"enablement": "!operationInProgress"
|
||||
},
|
||||
{
|
||||
"command": "git.deleteWorktree",
|
||||
"title": "%command.deleteWorktree%",
|
||||
@@ -1295,6 +1301,10 @@
|
||||
"command": "git.deleteTag",
|
||||
"when": "config.git.enabled && !git.missing && gitOpenRepositoryCount != 0"
|
||||
},
|
||||
{
|
||||
"command": "git.createWorktree",
|
||||
"when": "config.git.enabled && !git.missing && gitOpenRepositoryCount != 0"
|
||||
},
|
||||
{
|
||||
"command": "git.deleteWorktree",
|
||||
"when": "config.git.enabled && !git.missing && gitOpenRepositoryCount != 0"
|
||||
@@ -2556,8 +2566,13 @@
|
||||
],
|
||||
"git.worktrees": [
|
||||
{
|
||||
"command": "git.deleteWorktree",
|
||||
"when": "scmProviderContext == repository",
|
||||
"command": "git.createWorktree",
|
||||
"group": "worktrees@1"
|
||||
},
|
||||
{
|
||||
"command": "git.deleteWorktree",
|
||||
"group": "worktrees@2"
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user