1

Possible Duplicate:
Paperclip Error

I have ImageMagick installed. If I try using it on the command line it works. I can use identify. It is located in /usr/bin. And in my development.rb I do the

Paperclip.options[:command_path] = '/usr/bin/'

It still will not work. I keep getting this error.

Command :: identify -format %wx%h :file
[paperclip] An error was received while processing: #<Paperclip::NotIdentifiedByImageMagickError: /tmp/stream20121130-6368-1c4xwb9-0.jpg is not recognized by the 'identify' command.>

I have no idea how to make this work. I have tried everything. I also tried adding this to my config/initializers/paperclip.rb but it didn't work

require 'paperclip'

if RAILS_ENV == "development"
 Paperclip.options[:command_path] = '/usr/bin/'
end
Community
  • 1
  • 1
Newcastle
  • 45
  • 4
  • Presumably your `development.rb` should refer to `/usr/bin`, not `usr/bin`. Is that a typo in your `development.rb` file, or just in your question? – Keith Thompson Nov 30 '12 at 21:43
  • yea that is a typo in my question. I actually do have Paperclip.options[:command_path] = '/usr/bin/' in my development.rb. Sorry. What should I do? – Newcastle Nov 30 '12 at 21:57
  • Does `identify` process the file correctly in the first place on the command line? Next. Upload the file and save it. Don't process it. Then try running identify on the command line on the uploaded file. Seems like somewhere the file is getting corrupted/modified such that identify can't parse it. It's finding it okay so I don't think settings :command_path is your issue. – Philip Hallstrom Nov 30 '12 at 22:19
  • Does `file ` work from the command line? – Keith Thompson Nov 30 '12 at 22:53
  • So Identify just by itself works for the /tmp/stream20121130-6368-1c4xwb9-0.jpg. But I'm getting an error for identify -format "200x200" /tmp/stream20121130-6368-1c4xwb9-0.jpg.Why is that happening? – Newcastle Dec 01 '12 at 19:49
  • I had to downgrade to cocain 0.3.2. I was using 0.4.2. It works now. Thanks anyway – Newcastle Dec 01 '12 at 19:59

0 Answers0