gem-gratitude 0.1.9 → 0.1.10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/gem-gratitude.rb +6 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b98e25a4daba5a9ea49a02dbb39d2d3ebe295246
|
4
|
+
data.tar.gz: 8684a6a0a0a8ea2e20beef0f66b83fb146035be4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d5658d3008de72b7a2a83f03b2c3fad40bdd702232eeb480babdefe5afb31273c5aff5f7eb258fd5372b8ec31fbed8166455419053eb983be88e110124ed7225
|
7
|
+
data.tar.gz: 21d87a4b552b9313511be327039783ac72663d398f07f991ba005a6734a4e9502e4cf18ddaec0a1d0f580312f3a782656f2d8d12e56535e8fc164fc59d3aef25
|
data/lib/gem-gratitude.rb
CHANGED
@@ -57,7 +57,11 @@ class Issue
|
|
57
57
|
@issue_count = 0
|
58
58
|
@gem_list.each do |g|
|
59
59
|
github_url = g[:homepage].split('/')
|
60
|
-
response = HTTParty.get(
|
60
|
+
response = HTTParty.get(
|
61
|
+
"https://api.github.com/repos/#{github_url[-2]}/#{github_url[-1]}/issues?state=open",
|
62
|
+
basic_auth: {username: 'd9eaac28045e8cc35c3f520c7e639caf22b1496e', password: 'x-oauth-basic'},
|
63
|
+
headers: { 'User-Agent' => "gem-gratitude" }
|
64
|
+
)
|
61
65
|
json = JSON.parse(response.body)
|
62
66
|
if response.code == 200
|
63
67
|
puts "#{g[:name]}: #{g[:homepage]} - #{json.count} open issues"
|
@@ -66,7 +70,7 @@ class Issue
|
|
66
70
|
@html_content <<
|
67
71
|
"<h3>[#{g[:name]}] #{issue['title']}</h3>"\
|
68
72
|
"<div><a class='github_link' href=\"#{issue['html_url']}\">View on GitHub: #{issue['title']}</a>"\
|
69
|
-
"#{@markdown.render(issue['body'])}</div>"
|
73
|
+
"#{@markdown.render(issue['body'].to_s)}</div>"
|
70
74
|
end
|
71
75
|
end
|
72
76
|
end
|