SublimeDiffView icon indicating copy to clipboard operation
SublimeDiffView copied to clipboard

Add Note/message about 'git' is missing from command line.

Open joshua-graham-adelphi opened this issue 4 years ago • 0 comments

Hi,

I got the message: This file does not appear to be under version control (Git, SVN or Bazaar)

I had to run some code from: https://github.com/CJTozer/SublimeDiffView/blob/develop/util/vcs.py#L49

to find the error, I had to run in sublime text console: (nothing in console, even after debug = true and restart sublime - except message saying it's debug is enabled.)

import subprocess
subprocess.Popen('git rev-parse --show-toplevel', stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True).communicate()

(b'', b'fatal: not a git repository (or any of the parent directories): .git\n')

I recommend we check for git in path and add info to error message. (many tools such as cmder / sourcetree don't add git to PATH)

joshua-graham-adelphi avatar Feb 04 '21 04:02 joshua-graham-adelphi