'VSCode, Perforce: "SOURCE CONTROL No source control providers registered."

I'm using VSCode x64 on Win10 x64, and desire to use Perforce with it. I have a Perforce installation on the same machine that already works with both local and remote VS clients. I've installed and loaded the VSCode Perforce plugin from VSCode Marketplace. Activation Mode is set to "autodetect".

However, in the Source Control pane, VSCode shows "SOURCE CONTROL No source control providers registered."

I've found No source control providers registered on Mac and tried the disable-reload sequence described but problem still exists.

No 3-dot menu to "Switch SCM provider". Right now I've disabled all other extensions, Have tried re-installing the extension, as well as adding Perforce login settings to workspace "settings.json", and have put similar ".p4config" at workspace root, but to no avail.

Found Git missing in VSCode - no source control providers, not sure where I would set the equivalent to "git.path" nor what the path would be: to Perforce itself, or to the VSCode extension; not sure of the path to that extension.

Would appreciate any hints on how to get the VSCode Perforce plugin to register. Is the VSCode Perforce plugin known to work with x64 for both VSCode and Win10?



Solution 1:[1]

Following are steps to resolve "No source control providers registered" issue

1) Install GIT

2) Ensure GIT is added to Path environment variable, you can verify whether GIT installation by typing "CTRL+SHFT+P" in VS Code and entering "GIT: Show Git Output". Refer to the screenshot below enter image description here

3) Visual studio code expects that a GIT repository is loaded into it by using open folder. You need to manually clone your GIT repository and load it into Visual studio using "Open Folder" from file menu or side bar enter image description here

4)Now in your Source Control tab, you will find GIT successfully integrated enter image description here

Solution 2:[2]

I had the same issue. Double check that you have the correct settings enabled:

The following can be set in VSCode user or workspace settings to properly detect the perforce depot

{
    "perforce.user": "your_user",
    "perforce.client": "your_client",
    "perforce.port": "example.com:1666"
}

You can also create a .p4config file at the root of your workspace with perforce variables

P4USER=your_user
P4CLIENT=your_client
P4PORT=example.com:1666

I configured the properties in the workflow settings and set the perforce.activationMode to always and now it works.

Note that only changing the setting parameter perforce.activationMode to always seems not to allow to active the extension if the user/client/port are not correct. I think this may be the root cause for the confusion, as the documentation for this setting reads as it should do so (always - Always try to activate the extension (old behavior)).

PS: Why is none of the other answers referring to Perforce?

Solution 3:[3]

If someone reaches up to here and still didn't get the issue resolved.

click extensions > In search box type @builtin > find git vscode extension > install it.

enter image description here

Solution 4:[4]

The only thing you have to do to solve the problem is open folder appdata folder:

  1. win+r
  2. write %appdata% & ENTER
  3. delete code folder.
  4. Start VS code again

It is restarted. Now you can see the git icon available.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Kiran Vedula
Solution 2 Tromse
Solution 3 rs_punia
Solution 4 Mihai