Skip to content

Instantly share code, notes, and snippets.

@jonathanclarke
Created February 28, 2011 22:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jonathanclarke/848224 to your computer and use it in GitHub Desktop.
Save jonathanclarke/848224 to your computer and use it in GitHub Desktop.
Regenerate thumbnails for has_many paperclip
has_attached_file :file,
:styles => { :thumb => "139x107#", :thumb_ems => "64x64#", :thumb_aar => "100x100#", :thumb_newsletter => "80x60#", :thumb_newsletter_product => "110x85#", :web_image => "145x>" },
:storage => :s3,
:bucket => "domain.com_#{RAILS_ENV}",
:s3_credentials => "#{RAILS_ROOT}/config/s3.yml",
:path => ":class/:id/:style/:filename"
RAILS_ENV=staging rake paperclip:refresh:thumbnails CLASS=Asset
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment