Permalink
Browse files

takes wiki page selector to external

  • Loading branch information...
1 parent 957ed64 commit 2ed129e3c174cb9192830a4b63171942baf10ff5 @tosik tosik committed Sep 5, 2011
Showing with 8 additions and 2 deletions.
  1. +8 −2 lib/redmine_wiki_exporter.rb
View
10 lib/redmine_wiki_exporter.rb
@@ -101,10 +101,16 @@ def wiki_urls
}
end
+ def scraping_selector=(selector)
+ @scraping_selector = selector
+ end
+ def scraping_selector
+ @scraping_selector
+ end
+
def scrape
- wiki_urls.select {|url| url.to_s.include? "Spec_"}.each do |url|
+ wiki_urls.select(&scraping_selector).each do |url|
save(url.split('/').last)
end
end
end
-

0 comments on commit 2ed129e

Please sign in to comment.