Hi , I go to 2 page and download 2 file jpegsrc.v8d.tar.gz , optipng-0.6.5.tar.gz. And what thing must to do then ???
And I wonder if I use this gem in heroku host. Is this support lib for this gem ?
Thanks for your attention
You simply must insert into your Gemfile the following line:
gem "paperclip-smusher", "~> 0.1.1"
save, and then run (from console) a:
All the rest should be done by bundler.
Heroku supports both these two libs (we actually use it on Blomming).
thank you so much. Your gem is very useful :D
Hi knightq , I test upload image to s3 (host heroku) but It seem not smusher my image
my gem in heroku :
The gem works (obviously) on server side: once you've uploaded your full size non.smushed image on your application server (heroku, as you told me), and just before the uploading to S3, it smush the image.
At the end of the whole process, you have the image smushed on your S3 bucket.
You have anyway to pay the payload for the upload from the client to your server, since the cut is done after that.
Have I answered to you question?
You misunderstand :D
I mean : why the image on s3 (I uploaded for test your gem) , it size not change (it be no smushered)
I install gem "smusher" in my computer, then I run console: smusher path/home.jpg
home.jpg 22.4 KB (22910 bytes) and after smusher by gem "smusher" in my computer -> 21.6 KB (22144 bytes).
Then I test upload home.jpg 22.4 KB (22910 bytes) to s3. And I SAVE it back to check the size , I see it still 22.4 KB
Thank for your attention :D
I suggest you to try with another image.
The lib used to reduce the image size is not exaclty the same used by Yahoo! on its web service.
If you try again with another image (maybe with a larger one) you should see however an image size reduction, isn't it?
Thanks , that works :D