Skip to content

Instantly share code, notes, and snippets.

@zhannes
Created March 17, 2015 21:26
Show Gist options
  • Save zhannes/c0a3477613cde89659d0 to your computer and use it in GitHub Desktop.
Save zhannes/c0a3477613cde89659d0 to your computer and use it in GitHub Desktop.
quick script takes a file of URLs and tells FB to recrawl them. When og:image etc have changed, this will refresh FB's cache of the page.
# pass input file as param
return unless ARGV.size > 0
list = ARGV[0]
File.readlines(list).each do |line|
puts `curl --data "id=#{line}&scrape=true" https://graph.facebook.com`
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment