SourceTree Terminal not working properly

Viewed 6312

I'm using Windows 10, SourceTree and Git .

When i want to Switch branch by using the SourceTree terminal it shows :

error: pathspec '3.Building-the-API-Implementing-Basic-Requirements' did not match any file(s) known to git.

enter image description here

But if i execute same command from Git Bash in my project directory, it works fine.

enter image description here

enter image description here

Why the SourceTree terminal is not working ? Is there any issue to work SourceTree terminal ?

3 Answers

For the record, I just found out that the Git 2.31 update on SourceTree 3.3.4 Windows causes this very issue, either if you're using the embedded or system Git, and can be fixed by reverting to Git 2.30.2, either configuration.

I, too, have Git 2.31.1 installed in the System and using it as my Sourcetree's Git version (not Embedded).

Alternatively, without reinstalling Sourcetree:

  1. Go to Tools > Options > Git.
  2. Uncheck/disable Use Git Bash as default terminal..
  3. Restart Sourcetree (optional).
  4. Clicking on the Terminal now will launch a Terminal/Command-line in the repository's home directory.

In some cases, depending on your Git's and Sourcetree's configuration and add-ons, you can also do this after Step 4 above.

  1. Go back to Tools > Options > Git.
  2. Check/Enable Use Git Bash as default terminal..
  3. Restart Sourcetree (optional).
  4. Clicking on the Terminal now could launch Git Bash.
Related