| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 42af9be commit 6ef7a80
3 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,5 +1,7 @@ | |||
| 1 | 1 | source "http://rubygems.org" | |
| 2 | 2 | ||
| 3 | + ruby '1.9.3' | ||
| 4 | + | ||
| 3 | 5 | gem 'builder' | |
| 4 | 6 | gem 'coderay' | |
| 5 | 7 | gem 'kramdown', '~> 0.13.2' | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -48,6 +48,7 @@ is a group of commits per day, starting on `Sunday`. | |||
| 48 | 48 | ### Response | |
| 49 | 49 | ||
| 50 | 50 | <%= headers 200 %> | |
| 51 | + <%= json(:repo_stats_code_frequency) %> | ||
| 51 | 52 | ||
| 52 | 53 | ## Get the weekly commit count for the repo owner and others | |
| 53 | 54 | ||
@@ -56,11 +57,21 @@ is a group of commits per day, starting on `Sunday`. | |||
| 56 | 57 | ### Response | |
| 57 | 58 | ||
| 58 | 59 | <%= headers 200 %> | |
| 60 | + <%= json(:repo_stats_participation) %> | ||
| 59 | 61 | ||
| 60 | 62 | ## Get the number of commits per hour in day | |
| 61 | 63 | ||
| 62 | 64 | GET /repos/:owner/:repo/stats/punch_card | |
| 63 | 65 | ||
| 64 | 66 | ### Response | |
| 65 | 67 | ||
| 66 | - <%= headers 200 %> | ||
| 68 | + Each array contains the day number, hour number and number of commits: | ||
| 69 | + | ||
| 70 | + * `0-6` = Sunday - Saturday | ||
| 71 | + * `0-23` = Hour of day | ||
| 72 | + * Number of commits | ||
| 73 | + | ||
| 74 | + For example, `[2, 14, 25]` would indicate that there were 25 total commits, during the 2:00pm hour on Tuesdays. | ||
| 75 | + | ||
| 76 | + <%= headers 200 %> | ||
| 77 | + <%= json(:repo_stats_punch_card) %> | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1140,12 +1140,28 @@ def text_html(response, status, head = {}) | |||
| 1140 | 1140 | ] | |
| 1141 | 1141 | }] | |
| 1142 | 1142 | ||
| 1143 | - | ||
| 1144 | 1143 | REPO_STATS_COMMIT_ACTIVITY = [{ | |
| 1145 | 1144 | :days => [0, 3, 26, 20, 39, 1, 0], | |
| 1146 | 1145 | :total => 89, | |
| 1147 | 1146 | :week => "2012-05-06" | |
| 1148 | 1147 | }] | |
| 1148 | + | ||
| 1149 | + REPO_STATS_CODE_FREQUENCY = [[ | ||
| 1150 | + 1302998400, | ||
| 1151 | + 1124, | ||
| 1152 | + -435 | ||
| 1153 | + ]] | ||
| 1154 | + | ||
| 1155 | + REPO_STATS_PARTICIPATION = { | ||
| 1156 | + :all => [11,21,15,2,8,1,8,23,17,21,11,10,33,91,38,34,22,23,32,3,43,87,71,18,13,5,13,16,66,27,12,45,110,117,13,8,18,9,19,26,39,12,20,31,46,91,45,10,24,9,29,7], | ||
| 1157 | + :owner => [3,2,3,0,2,0,5,14,7,9,1,5,0,48,19,2,0,1,10,2,23,40,35,8,8,2,10,6,30,0,2,9,53,104,3,3,10,4,7,11,21,4,4,22,26,63,11,2,14,1,10,3] | ||
| 1158 | + } | ||
| 1159 | + | ||
| 1160 | + REPO_STATS_PUNCH_CARD = [ | ||
| 1161 | + [0,0,5], | ||
| 1162 | + [0,1,43], | ||
| 1163 | + [0,2,21] | ||
| 1164 | + ] | ||
| 1149 | 1165 | end | |
| 1150 | 1166 | end | |
| 1151 | 1167 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments