Skip to content

Instantly share code, notes, and snippets.

@rb2k
Created February 25, 2010 15:31
Show Gist options
  • Save rb2k/314631 to your computer and use it in GitHub Desktop.
Save rb2k/314631 to your computer and use it in GitHub Desktop.
o = OrderedHash.new
o[:findandmodify] = 'to_crawl'
o[:sort] = {:incoming_links => -1}
o[:remove] = true
o[:limit] = amount
jobs = queue.db.command(o)["value"]
puts jobs.inspect
jobs.each do |page|
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment