Permalink
Browse files

update regexp

  • Loading branch information...
1 parent af7503e commit 10bb3df3b7b3404cb6948eab8d6de92203aad9c5 @flyerhzm committed Feb 6, 2010
Showing with 4 additions and 4 deletions.
  1. +2 −2 README.textile
  2. +2 −2 example/github_projects.rb
View
@@ -60,8 +60,8 @@ end
projects = []
crawler = RegexpCrawler::Crawler.new(
:start_page => "http://github.com/flyerhzm",
- :continue_regexp => %r{<h3>[\s|\n]*?<a href="(/flyerhzm/.*?)">}m,
- :capture_regexp => %r{<a href="http://github.com/flyerhzm/[^"]*?">(.*?)</a>.*?<div id="repository_description".*?>[\s|\n]*?<p>(.*?)[\s|\n]*?<span id="read_more".*(<div class="wikistyle">.*?</div>)</div>}m,
+ :continue_regexp => %r{<h3>[\s\n]*?<a href="(/flyerhzm/.*?)">}m,
+ :capture_regexp => %r{<a href="http://github.com/flyerhzm/[^"]*?">(.*?)</a>.*?<div id="repository_description".*?>[\s\n]*?<p>(.*?)[\s\n]*?<span id="read_more".*(<div class="wikistyle">.*?</div>)</div>}m,
:named_captures => ['title', 'description', 'body'],
:logger => true,
:save_method => Proc.new do |result, page|
@@ -14,8 +14,8 @@ def initialize(options)
projects = []
crawler = RegexpCrawler::Crawler.new(
:start_page => "http://github.com/flyerhzm",
- :continue_regexp => %r{<h3>[\s|\n]*?<a href="(/flyerhzm/.*?)">}m,
- :capture_regexp => %r{<a href="http://github.com/flyerhzm/[^"]*?">(.*?)</a>.*?<div id="repository_description".*?>[\s|\n]*?<p>(.*?)[\s|\n]*?<span id="read_more".*(<div class="wikistyle">.*?</div>)</div>}m,
+ :continue_regexp => %r{<h3>[\s\n]*?<a href="(/flyerhzm/.*?)">}m,
+ :capture_regexp => %r{<a href="http://github.com/flyerhzm/[^"]*?">(.*?)</a>.*?<div id="repository_description".*?>[\s\n]*?<p>(.*?)[\s\n]*?<span id="read_more".*(<div class="wikistyle">.*?</div>)</div>}m,
:named_captures => ['title', 'description', 'body'],
:logger => true,
:save_method => Proc.new do |result, page|

0 comments on commit 10bb3df

Please sign in to comment.