repocrawler 0.1.10 → 0.1.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: dc5bf52354750d5c04db57825119a1ac363dd89c
4
- data.tar.gz: 4de595550ce80a125543c6b9a4e97ee46d0bd136
3
+ metadata.gz: beae48f48942aeb6c43177674ddf0616246f1307
4
+ data.tar.gz: d54e67b91e1cf32870c986a22aaf9513993b1c69
5
5
  SHA512:
6
- metadata.gz: 16b34922d7827257a31836a2cc339471a20e19c37251cfc7a3ee91fc45db638184912832861ca9d4f7ad3041d28c157e4b9ac2fba8a767fdf7ac7a7ab24f0285
7
- data.tar.gz: fe76c01de67fe2a2a8f4d8ecc6d7e25028bbd43be62cb11f35c7b96889c5197f95a456d308cb550cc2dc2150b4009c1594f9b1d922450cb7b3d8ff8e27a8e4b6
6
+ metadata.gz: c0b1560aa4ba5b83629af268d735ee5041083e5cd82655fd1e651c9e4dfd19e53befd519e99f199ea4f310d91c26251bbaebf9902cb0397e036664e09364a1f9
7
+ data.tar.gz: bd0cf5382f7dc0efe5e74b079f90c48b2b87d73e364f891f0c411cfeb96e7042f83dc3be5e0b239268af8b058221acd9ada241f3bbbfce96eb194511819a5884
@@ -80,6 +80,31 @@ module Repos
80
80
  issues
81
81
  end
82
82
 
83
+ # get commits history
84
+ def get_commits_history
85
+ commits_info = []
86
+ stop = false
87
+ page = 1
88
+
89
+ until stop
90
+ commits_fetch = HTTParty.get(@GITHUB_API_BASE_URL + "/commits?page=#{page}&access_token=#{@access_token}", headers: {
91
+ "User-Agent" => @user_agent
92
+ })
93
+ if commits_fetch.count === 0
94
+ stop = true
95
+ end
96
+
97
+ commits_fetch.each do |commit|
98
+ commits_info << {
99
+ "committer" => commit['commit']['committer']['name']
100
+ "created_at" => commit['commit']['committer']['date']
101
+ }
102
+ end
103
+ end
104
+
105
+ commits_info.reverse!
106
+ end
107
+
83
108
  # get information of the closed issues
84
109
  def get_issues_info
85
110
  closed_issues = []
@@ -1,4 +1,4 @@
1
1
  # Versioning
2
2
  module Repos
3
- VERSION = '0.1.10'
3
+ VERSION = '0.1.11'
4
4
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: repocrawler
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.10
4
+ version: 0.1.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lee Chen