Commit 3d703a7
committed
Add initial support for libgit2/rugged involving massive changes
Large change set here! Difficult to split this up into modular changes as Grit at the time was the heart of the processing. The initial implementation done here for Rugged works, and all the specs are currently passing. The GPG signing issue is no longer an issue, and Rugged also provides a substantial speed boost and memory reduction than the Grit implementation. The current state also run on Ruby 2.0.x as we are not held back by Grit. Remove: * The use of Grit for git processing * repo.rb as Rugged::Repository provided sufficient repo finding capabilities * Mixin for Grit::Blob to include LanguageSniffer functionality * blob_finder.rb as Rugged::Diff::Patch provides sufficient functionality to acquire the individual SHA's of blobs affected in the diff, which then can be Rugged::Repository.lookup(sha) * FileSummary struct and instead just use the patch information from DiffSummary Add: * Rugged for git processing * Direct use of LanguageSniffer in diff_summary to detect the language of the diff's content (using the blob in question) * Additional functionality to diff_summary.rb as it now is responsible for working with patches (provides #additions, #deletions, #status) * Additional information on LanguageSummary (:added_files, :deleted_files, :modified_files) Refactor: * How we found the commits to process, Grit::Commit.find_all(…) was replaces with Rugged::Walker * spec_helper.rb to now use Rugged::Repository instead of our own class * The terminology of :create, :delete to :added_files, :deleted_files Fix: * The ability to handle time_since and time_until for commits to work with Rugged (check on each commit if it is valid -- #valid_commit?) * Specs to work with new implementation and terminologies * fixtures to use the updated key names1 parent a680753 commit 3d703a7
File tree
19 files changed
+223
-409
lines changed- lib
- git_statistics
- formatters
- spec
- fixtures
- formatters
19 files changed
+223
-409
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | | - | |
| 20 | + | |
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
| |||
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
38 | | - | |
| 39 | + | |
39 | 40 | | |
40 | 41 | | |
41 | 42 | | |
42 | 43 | | |
43 | | - | |
44 | | - | |
45 | | - | |
| 44 | + | |
| 45 | + | |
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | 7 | | |
11 | | - | |
| 8 | + | |
12 | 9 | | |
13 | 10 | | |
14 | 11 | | |
15 | 12 | | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
21 | 22 | | |
| 23 | + | |
22 | 24 | | |
23 | 25 | | |
24 | 26 | | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
25 | 39 | | |
26 | 40 | | |
27 | | - | |
| 41 | + | |
28 | 42 | | |
29 | | - | |
30 | | - | |
31 | | - | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
32 | 46 | | |
33 | 47 | | |
34 | 48 | | |
35 | 49 | | |
36 | | - | |
37 | | - | |
38 | | - | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
39 | 54 | | |
40 | 55 | | |
41 | 56 | | |
42 | 57 | | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
47 | 61 | | |
48 | | - | |
49 | | - | |
| 62 | + | |
| 63 | + | |
50 | 64 | | |
51 | | - | |
52 | | - | |
| 65 | + | |
53 | 66 | | |
54 | 67 | | |
55 | 68 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
5 | 8 | | |
6 | 9 | | |
7 | 10 | | |
| |||
10 | 13 | | |
11 | 14 | | |
12 | 15 | | |
13 | | - | |
14 | | - | |
| 16 | + | |
| 17 | + | |
15 | 18 | | |
16 | 19 | | |
17 | 20 | | |
18 | | - | |
19 | | - | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
20 | 28 | | |
21 | 29 | | |
22 | 30 | | |
| |||
35 | 43 | | |
36 | 44 | | |
37 | 45 | | |
38 | | - | |
| 46 | + | |
39 | 47 | | |
40 | 48 | | |
41 | | - | |
| 49 | + | |
42 | 50 | | |
43 | 51 | | |
44 | 52 | | |
45 | 53 | | |
46 | 54 | | |
47 | 55 | | |
48 | 56 | | |
49 | | - | |
| 57 | + | |
50 | 58 | | |
51 | 59 | | |
52 | 60 | | |
| |||
55 | 63 | | |
56 | 64 | | |
57 | 65 | | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | 66 | | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
| 67 | + | |
| 68 | + | |
77 | 69 | | |
78 | 70 | | |
79 | 71 | | |
80 | 72 | | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
86 | | - | |
87 | | - | |
88 | | - | |
89 | | - | |
90 | | - | |
91 | | - | |
92 | | - | |
93 | | - | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | 73 | | |
125 | 74 | | |
126 | 75 | | |
| |||
130 | 79 | | |
131 | 80 | | |
132 | 81 | | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | | - | |
| 82 | + | |
146 | 83 | | |
147 | 84 | | |
148 | 85 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
120 | | - | |
121 | | - | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
122 | 123 | | |
123 | 124 | | |
124 | 125 | | |
| |||
130 | 131 | | |
131 | 132 | | |
132 | 133 | | |
133 | | - | |
134 | | - | |
| 134 | + | |
| 135 | + | |
135 | 136 | | |
136 | 137 | | |
137 | 138 | | |
| |||
0 commit comments