|
|
|
|
|
|
481
|
ReportCreator.create(self, data, path)
|
481
|
ReportCreator.create(self, data, path)
|
|
482
|
self.title = data.projectname
|
482
|
self.title = data.projectname
|
|
483
|
|
483
|
|
|
484
|
- # copy static files if they do not exist
|
|
|
|
485
|
- basedirs = [os.path.dirname(os.path.abspath(__file__)), '/usr/share/gitstats']
|
|
|
|
|
|
484
|
+ # copy static files. Looks in the binary directory, ../share/gitstats and /usr/share/gitstats
|
|
|
|
485
|
+ binarypath = os.path.dirname(os.path.abspath(__file__))
|
|
|
|
486
|
+ secondarypath = os.path.join(binarypath, '..', 'share', 'gitstats')
|
|
|
|
487
|
+ basedirs = [binarypath, secondarypath, '/usr/share/gitstats']
|
|
486
|
for file in ('gitstats.css', 'sortable.js', 'arrow-up.gif', 'arrow-down.gif', 'arrow-none.gif'):
|
488
|
for file in ('gitstats.css', 'sortable.js', 'arrow-up.gif', 'arrow-down.gif', 'arrow-none.gif'):
|
|
487
|
for base in basedirs:
|
489
|
for base in basedirs:
|
|
488
|
src = base + '/' + file
|
490
|
src = base + '/' + file
|