gitlab_git 5.5.0 → 5.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/lib/gitlab_git/stats.rb +2 -2
- data/lib/gitlab_git/tree.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 22c9d438dba25f5af52d7593c07a24305f0afa9a
|
4
|
+
data.tar.gz: 4e1bdb1156a383b84f62574999e8a5b09d7e52f9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1c061e05b23be02d1601f7b85343daeb24188bbe041e535d44d9c4a12246b8ed4bfa63680408a19c281c038b50ab479e0f5f2183889a252d57858f0b51557097
|
7
|
+
data.tar.gz: fa7bb4a72420cf3ee6d52f715511cd0f6712e8550afed4af85448c5136fdb47894e63826711d47eac2fe2d8a225eedb3a3c4b16ea96e6a4e9147ce5d227b325e
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
5.
|
1
|
+
5.6.0
|
data/lib/gitlab_git/stats.rb
CHANGED
@@ -52,13 +52,13 @@ module Gitlab
|
|
52
52
|
authors.sort_by(&:commits).reverse
|
53
53
|
end
|
54
54
|
|
55
|
-
def build_graph
|
55
|
+
def build_graph(n = 4)
|
56
56
|
from, to = (Date.today.prev_day(n*7)), Date.today
|
57
57
|
args = ['--all', "--since=#{from.to_s}", '--format=%ad' ]
|
58
58
|
rev_list = repo.git.run(nil, 'rev-list', nil, {}, args).split("\n")
|
59
59
|
|
60
60
|
commits_dates = rev_list.values_at(* rev_list.each_index.select {|i| i.odd?})
|
61
|
-
commits_dates = commits_dates.map { |date_str| Time.parse(date_str).to_date.to_s
|
61
|
+
commits_dates = commits_dates.map { |date_str| Time.parse(date_str).to_date.to_s }
|
62
62
|
|
63
63
|
commits_per_day = from.upto(to).map do |day|
|
64
64
|
commits_dates.count(day.to_date.to_s)
|
data/lib/gitlab_git/tree.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gitlab_git
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.
|
4
|
+
version: 5.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dmitriy Zaporozhets
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-02-
|
11
|
+
date: 2014-02-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gitlab-linguist
|