Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Add paperclip new style doesn't affect old uploaded images

I have Company model with logo image

has_attached_file :logo

I have created many companies with their logos.

Now, I need to add new style

has_attached_file :logo, :styles => { :small => "30x15>", :medium => "155x85>" }

Should I re-upload all my old data to regenerate the new styles? I don't think so.... Or is there any rake task can regenerate styles?

like image 326
Mahmoud Khaled Avatar asked Sep 28 '11 16:09

Mahmoud Khaled


1 Answers

See Thumbnail-Generation. If the rake task doesn't work for you, you should be able to use a snippet in the console to invoke reprocess! on the companies in question

like image 102
Jeff Paquette Avatar answered Sep 25 '22 01:09

Jeff Paquette