瀏覽代碼

Removes some git commands from workspace repo nodes

main
Ramin Tadayon 1 年之前
父節點
當前提交
17970d8258
沒有發現已知的金鑰在資料庫的簽署中 GPG 金鑰 ID: 79D60DDE3DFB95F5
共有 2 個檔案被更改,包括 14 行新增11 行删除
  1. +11
    -11
      package.json
  2. +3
    -0
      src/views/nodes/repositoryNode.ts

+ 11
- 11
package.json 查看文件

@ -11888,18 +11888,18 @@
},
{
"command": "gitlens.views.push",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace.*?\\+closed\\b)/",
"group": "inline@96",
"alt": "gitlens.views.pushWithForce"
},
{
"command": "gitlens.views.pull",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace.*?\\+closed\\b)/",
"group": "inline@97"
},
{
"command": "gitlens.views.fetch",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace.*?\\+closed\\b)/",
"group": "inline@98"
},
{
@ -11914,22 +11914,22 @@
},
{
"command": "gitlens.views.fetch",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace.*?\\+closed\\b)/",
"group": "1_gitlens_actions@1"
},
{
"command": "gitlens.views.pull",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace\\b.*?\\+closed\\b)/",
"group": "1_gitlens_actions@1"
},
{
"command": "gitlens.views.push",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace\\b.*?\\+closed\\b)/",
"group": "1_gitlens_actions@1"
},
{
"command": "gitlens.views.pushWithForce",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "gitlens:hasRemotes && !gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace\\b.*?\\+closed\\b)/",
"group": "1_gitlens_actions@2"
},
{
@ -11955,17 +11955,17 @@
},
{
"command": "gitlens.stashSave",
"when": "!gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "!gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace\\b)/",
"group": "1_gitlens_actions_1@1"
},
{
"command": "gitlens.stashApply",
"when": "!gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b/",
"when": "!gitlens:readonly && !gitlens:untrusted && !gitlens:hasVirtualFolders && viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+workspace\\b)/",
"group": "1_gitlens_actions_1@2"
},
{
"command": "gitlens.views.star",
"when": "viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+starred\\b)/",
"when": "viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+(starred|workspace)\\b)/",
"group": "8_gitlens_actions_@1"
},
{
@ -11975,7 +11975,7 @@
},
{
"command": "gitlens.views.closeRepository",
"when": "viewItem =~ /gitlens:repository\\b/",
"when": "viewItem =~ /gitlens:repository\\b(?!.*?\\b\\+closed\\b)/",
"group": "8_gitlens_actions_@2"
},
{

+ 3
- 0
src/views/nodes/repositoryNode.ts 查看文件

@ -271,6 +271,9 @@ export class RepositoryNode extends SubscribeableViewNode
} else if (this.options.workspace.type === WorkspaceType.Local) {
contextValue += '+local';
}
if (this.repo.closed) {
contextValue += '+closed';
}
}
if (this.repo.virtual) {
contextValue += '+virtual';

Loading…
取消
儲存