Remove "total_authors = 0" fallback.
When counting authors, do not fall back to 0 if the git call fails. Zero
authors causes ZeroDivisionError later on otherwise. This reverts an old change
for msysgit on win32, introduced in a01045f248
.
It should no longer be necessary.
master
parent
2e1aba41e9
commit
496228fb74
5
gitstats
5
gitstats
|
@ -248,10 +248,7 @@ class GitDataCollector(DataCollector):
|
|||
def collect(self, dir):
|
||||
DataCollector.collect(self, dir)
|
||||
|
||||
try:
|
||||
self.total_authors += int(getpipeoutput(['git shortlog -s %s' % getcommitrange(), 'wc -l']))
|
||||
except:
|
||||
self.total_authors = 0
|
||||
self.total_authors += int(getpipeoutput(['git shortlog -s %s' % getcommitrange(), 'wc -l']))
|
||||
#self.total_lines = int(getoutput('git-ls-files -z |xargs -0 cat |wc -l'))
|
||||
|
||||
# tags
|
||||
|
|
Loading…
Reference in New Issue