From ca27a87b050689863d1ec2000b8bf17064b92415 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Thu, 16 Feb 2017 10:23:15 +0100 Subject: [PATCH] git: hide/show commands based on state --- extensions/git/package.json | 102 ++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) diff --git a/extensions/git/package.json b/extensions/git/package.json index 16fc5f3d3b1..7c6ea83911a 100644 --- a/extensions/git/package.json +++ b/extensions/git/package.json @@ -200,6 +200,108 @@ } ], "menus": { + "commandPalette": [ + { + "command": "git.init", + "when": "scmProvider == git && scmProviderState == norepo" + }, + { + "command": "git.refresh", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.openChange", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.openFile", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.stage", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.stageAll", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.unstage", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.unstageAll", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.clean", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.cleanAll", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.commit", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.commitStaged", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.commitStagedSigned", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.commitAll", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.commitAllSigned", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.undoCommit", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.checkout", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.branch", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.pull", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.pullRebase", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.push", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.pushTo", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.sync", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.publish", + "when": "scmProvider == git && scmProviderState == idle" + }, + { + "command": "git.showOutput", + "when": "scmProvider == git && scmProviderState == idle" + } + ], "scm/title": [ { "command": "git.init",