Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed diff

Fixed git show HEAD command:
  HEAD needs to be upper-cased, or it is not interpreted as a treeish
  • Loading branch information...
commit ea141995b5d4b022c868d503b37805ca7a784ab2 1 parent ea50ec2
@cristinecula cristinecula authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 git_gutter_handler.py
View
6 git_gutter_handler.py
@@ -39,7 +39,7 @@ def update_git_file(self):
# between updates for performance
if view_collection.ViewCollection.git_time(self.view) > 5:
self.git_temp_file.truncate()
- args = ['git','--git-dir='+self.git_dir,'--work-tree='+self.git_tree,'show','head:'+self.git_path]
+ args = ['git','--git-dir='+self.git_dir,'--work-tree='+self.git_tree,'show','HEAD:'+self.git_path]
try:
subprocess.call(args, stdout=self.git_temp_file)
view_collection.ViewCollection.update_git_time(self.view)
@@ -82,10 +82,10 @@ def diff(self):
self.update_git_file()
self.update_buf_file()
- args = ['diff',self.git_temp_file.name,self.buf_temp_file.name]
+ args = ['diff',self.git_temp_file.name,self.buf_temp_file.name,'-b']
proc = subprocess.Popen(args, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
results = proc.stdout.read()
return self.process_diff(results)
else:
- return ([],[],[])
+ return ([],[],[])
Please sign in to comment.
Something went wrong with that request. Please try again.