Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

regenerating thumbnails using paperclip gem

I have a simple rails app and i use paperclip gem for my image processing. after uploading an image with a style like (:thumb => "30x30#") and i later want to add a new style like (:large => "300x300>"). the problem i am having is that, if i add the new style i would have a broken image link when rendering the image unless i upload a new image or update the old one. is it possible to regenerate the styles of the previously uploaded images? if so i would like to know how or do i have to re-upload the images again to have the new styles.

like image 431
Uchenna Avatar asked Feb 20 '12 18:02

Uchenna


1 Answers

went trough the paperclip documentation and found this.

rake paperclip:refresh:missing_styles

and it worked

like image 149
Uchenna Avatar answered Nov 11 '22 22:11

Uchenna