When attempting to use Git for version control, or importing external packages on Microsoft Visual Studio 2015 – some enterprise users may come across the ECMDERR error. This is caused by a conflict between Git and Microsoft Visual Studio.
It appears that the issue occurs in a limited number of corporate or enterprise IT networks, and could be the result of stringent internal firewalls. Never-the-less, if you are developing web applications that use external libraries, chances are you will need Git to work.
For example, if you are using Bower as your package management tool, restoring the packages listed in your
bower.json file will give you the ECMDERR error.
There is a solution, and it will need (temporary) admin privileges on your machine.
You will need administrator privileges on your machine to install some software. You should also have some pre-existing code handy to test after working through this tutorial.
Step 1: Install Git for Windows. Follow the on-screen instructions to complete the installation. Most of the default settings will be fine, but when you are prompted how you would like to use Git from the command line, it is crucial that you select the option:
“Run Git from the Windows Command Prompt” as seen in the image below.
Step 2: Ensure Git has been installed successfully. Do this by opening Command Prompt and running the
git command. If you get a ‘Command not found’ error, there is a problem with your installation and you should follow the instructions posted here.
Step 3: Now we need to tell Visual Studio to use this external version of Git we have installed. We do this by launching Visual Studio 2015 > Tools > Options > Projects and Solutions > External Web Tools > Untick
Then click the Add icon in the same window and enter the following:
C:\Program Files\Git\bin. Ensure that the path to the Git folder is correct and accurate to your installation. For some users it may be Program Files(x86) instead.
Step 4: Restart Visual Studio 2015 and re-attempt the process that gave you the ECMDERR error. Since we have told Visual Studio to use the externally configured Git tool, installed correctly under administrator privileges, it should now work.