有没有办法将命令添加到侧栏中源代码管理中的更多操作

Is there a way to add commands to the more actions in the source control in the side bar

是否可以通过扩展程序向此菜单添加自定义命令:

The docs crytpical mention a few extensible menus but nothing about the git extras.

是否可以向此菜单添加命令?是否有建议使这个可扩展...?

您链接到正确的地方:

The scm/title menu is located to the right of the SCM view title. The menu items in the navigation group will be inline, while all the others will be within the … dropdown menu.

我 package.json 中的这段代码作为测试对我有用:

 "contributes": {
  "menus": {
    "scm/title": [
      {
        "command": "find-and-transform.searchInFile",
        "when": "editorIsOpen && config.find-and-transform.enableContextMenus",
        "group": "4_search"
      }
    ]
  }
}

替换为您的值。应在 commands 部分提供相同的命令,例如:

"commands": [
   {
    "command": "find-and-transform.searchInFile",
    "title": "Search in this File",
    "category": "Find-Transform"
   }
]