ruboty-rss 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ruboty/handlers/rss.rb +8 -0
- data/lib/ruboty/rss.rb +1 -0
- data/lib/ruboty/rss/version.rb +1 -1
- 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: 2e7688e50302747bae4f8e18ffb4ca784d69f9c8
|
4
|
+
data.tar.gz: 35990d285fc193e5c9427f5372f52fded6ce0dfb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 96dc570294296ba1e56d58fbcde65d887daa21ead12cea498a5919d44504a05835a28614054ee6bb0973e9e3afa5a3402e9a0df7517b0b723be247401d1989fc
|
7
|
+
data.tar.gz: b3b467ad519baf1a57577e7d74d7190d2e0c58acd025dc8c1a7a2bb2888ba6ed4e6b115c5fc145ee51faec8dc5721d71c2b086e17ae762a1fdd0f1184876f4e4
|
data/lib/ruboty/handlers/rss.rb
CHANGED
@@ -75,7 +75,9 @@ module Ruboty
|
|
75
75
|
Thread.start do
|
76
76
|
while true
|
77
77
|
feeds.each_pair do |id, feed|
|
78
|
+
debug "Fetching RSS feed (#{feed.url})"
|
78
79
|
feed.new_items.each do |item|
|
80
|
+
debug "New item found (#{item.title} / #{item.link})"
|
79
81
|
body = "New Entry: #{item.title}\n#{item.link}"
|
80
82
|
Message.new(
|
81
83
|
feed.attributes.symbolize_keys.except(:url, :id).merge(robot: robot)
|
@@ -93,6 +95,12 @@ module Ruboty
|
|
93
95
|
end while feeds.has_key?(id)
|
94
96
|
id
|
95
97
|
end
|
98
|
+
|
99
|
+
private
|
100
|
+
|
101
|
+
def debug(str)
|
102
|
+
Ruboty.logger.debug("[#{Time.now.to_s}] ruboty-rss: #{str}")
|
103
|
+
end
|
96
104
|
end
|
97
105
|
end
|
98
106
|
end
|
data/lib/ruboty/rss.rb
CHANGED
data/lib/ruboty/rss/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruboty-rss
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryota Arai
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-07-
|
11
|
+
date: 2014-07-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|