projects
/
gitlive
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
0ead9ee
)
GitLogParser.js
author
Alan Knowles
<alan@roojs.com>
Wed, 2 Jan 2013 06:54:16 +0000
(14:54 +0800)
committer
Alan Knowles
<alan@roojs.com>
Wed, 2 Jan 2013 06:54:16 +0000
(14:54 +0800)
GitLogParser.js
patch
|
blob
|
history
diff --git
a/GitLogParser.js
b/GitLogParser.js
index
1cea049
..
b1281e7
100644
(file)
--- a/
GitLogParser.js
+++ b/
GitLogParser.js
@@
-225,11
+225,13
@@
for (var h in res) {
}
for (var h in GitLogParser.shours) {
var hsum = [];
}
for (var h in GitLogParser.shours) {
var hsum = [];
+ var htot = 0;
for (var desc in GitLogParser.shours[h]) {
for (var desc in GitLogParser.shours[h]) {
+ htot += GitLogParser.shours[h][desc]/60000).toFixed(2)*1;
hsum.push({ desc : desc, tot : (GitLogParser.shours[h][desc]/60000).toFixed(2)*1 })
}
hsum.sort(function(a,b) { if (a.tot == b.tot) { return 0; } return a.tot < b.tot ? 1 : -1 });
hsum.push({ desc : desc, tot : (GitLogParser.shours[h][desc]/60000).toFixed(2)*1 })
}
hsum.sort(function(a,b) { if (a.tot == b.tot) { return 0; } return a.tot < b.tot ? 1 : -1 });
- print(h+':');
+ print(h+':
Total (' + htot +')
');
hsum.forEach(function(r) {
print (" " + r.tot + " : " + r.desc);
});
hsum.forEach(function(r) {
print (" " + r.tot + " : " + r.desc);
});