microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
163.29k stars 28.89k forks source link

Git - Merge Conflict - Accept All Incoming/Current - Multiple Repositories #134370

Open dustyghost opened 3 years ago

dustyghost commented 3 years ago

Does this issue occur when all extensions are disabled?: Yes

Version: 1.60.2 (user setup) Commit: 7f6ab5485bbc008386c4386d08766667e155244e Date: 2021-09-22T12:00:31.514Z Electron: 13.1.8 Chrome: 91.0.4472.164 Node.js: 14.16.0 V8: 9.1.269.39-electron.0 OS: Windows_NT x64 10.0.19042

Steps to Reproduce:

Open a workspace folder that has subfolders with git repos in each. In one of the repos, merge so that multiple file merge conflict happens Open command pallet select "Merge Conflict: Accept All Incoming" Expected: all merge conflicts should have been incoming Actual: Nothing happens

Similarly if you select all the files in the conflict, and on the right click menu select "Accept All Incoming" nothing happens.

kretes commented 2 years ago

I can confirm I see the same with a git submodules project in a submodule.

Nothing happens and nothing in Console > Git.

Version: 1.64.2
Commit: f80445acd5a3dadef24aa209168452a3d97cc326
Date: 2022-02-09T22:02:29.527Z
Electron: 13.5.2
Chromium: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Linux x64 5.13.0-28-generic snap
lszomoru commented 1 year ago

@joaomoreno, I am suspecting that when the command is invoked from the command palette we do not have enough information to "guess" the repository against which the command should be executed. Assuming that my hypothesis is correct, do you think that is makes sense to "hide" these commands from the command palette when the workspace contains multiple repositories in order to avoid confusion?

joaomoreno commented 1 year ago

Our usual approach here is to show a quick pick to select which repo the user meant to run the command on. If that's not happening, feels like a bug in itself.

lszomoru commented 1 year ago

This command is being contributed by the vscode.merge-conflict and seems to operate at the document level. Reassigning it to @chrmarti who owns this extension.