scrubber-scrubyt 0.4.16 → 0.4.20
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.
- data/CHANGELOG +7 -0
- data/README +1 -0
- data/Rakefile +1 -1
- data/lib/scrubyt/core/navigation/agents/firewatir.rb +4 -0
- data/lib/scrubyt/core/navigation/agents/mechanize.rb +1 -1
- data/lib/scrubyt/core/shared/extractor.rb +1 -0
- metadata +1 -1
data/CHANGELOG
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
= scRUBYt! Changelog
|
|
2
2
|
|
|
3
|
+
== 0.4.3
|
|
4
|
+
== 20th April
|
|
5
|
+
|
|
6
|
+
- [NEW] option to close the firefox window after the scraping is finished (thanks to Mikkel Garcia and Damien Garros)
|
|
7
|
+
- [FIX] scRUBYt! now works with latest version of mechanize (thanks to nesquena, austinmoore and Leandro Nunes)
|
|
8
|
+
|
|
9
|
+
|
|
3
10
|
== 0.4.05
|
|
4
11
|
== 20th October
|
|
5
12
|
|
data/README
CHANGED
data/Rakefile
CHANGED
|
@@ -17,7 +17,7 @@ task "cleanup_readme" => ["rdoc"]
|
|
|
17
17
|
|
|
18
18
|
gem_spec = Gem::Specification.new do |s|
|
|
19
19
|
s.name = 'scrubyt'
|
|
20
|
-
s.version = '0.4.
|
|
20
|
+
s.version = '0.4.20'
|
|
21
21
|
s.summary = 'A powerful Web-scraping framework built on Mechanize and Hpricot (and FireWatir)'
|
|
22
22
|
s.description = %{scRUBYt! is an easy to learn and use, yet powerful and effective web scraping framework. It's most interesting part is a Web-scraping DSL built on HPricot and WWW::Mechanize, which allows to navigate to the page of interest, then extract and query data records with a few lines of code. It is hard to describe scRUBYt! in a few sentences - you have to see it for yourself!}
|
|
23
23
|
# Files containing Test::Unit test cases.
|
|
@@ -278,7 +278,7 @@ module Scrubyt
|
|
|
278
278
|
loop do
|
|
279
279
|
@@current_form = FetchAction.get_mechanize_doc.forms[i]
|
|
280
280
|
return nil if @@current_form == nil
|
|
281
|
-
break if @@current_form.form_node.attributes[lookup_attribute_name] == lookup_attribute_value
|
|
281
|
+
break if @@current_form.form_node.attributes[lookup_attribute_name].to_s == lookup_attribute_value
|
|
282
282
|
i+= 1
|
|
283
283
|
end
|
|
284
284
|
end
|
|
@@ -83,6 +83,7 @@ module Scrubyt
|
|
|
83
83
|
|
|
84
84
|
#Once all is set up, evaluate the extractor from the root pattern!
|
|
85
85
|
root_results = evaluate_extractor
|
|
86
|
+
FetchAction.close_firefox if @mode.is_a?(Hash) && @mode[:close]
|
|
86
87
|
|
|
87
88
|
@result = ScrubytResult.new('root')
|
|
88
89
|
@result.push(*root_results)
|