sh:识别:找不到命令imagemagick rails 3

时间:2012-01-04 07:36:32

标签: ruby-on-rails imagemagick

我正在使用带有rails 3的ImageMagick-6.7.4,并且还将paperclip gem安装到我的应用程序中。我跟着this guide安装了imagemagick,它可以在我的终端上运行,但不能使用我的rails应用程序。我已将development.rb中的identify命令路径包含在

Paperclip.options[:command_path]='/path-where-my-identify-got-installed/'

但它仍然给我一个错误

Command :: identify -format %wx%h'/var/folders/Cd/CdjXsnlyEPyFqs4pwH83T++++TI/-Tmp-/stream20120104-2402-5iizym-0.png[0]'[paperclip] An error was received while processing: #<Paperclip::CommandNotFoundError: Could not run the `identify` command. 
Please installImageMagick.>Command :: identify -format %wx%h '/var/folders/Cd/CdjXsnlyEPyFqs4pwH83T++++TI/-Tmp-/stream20120104-2402-5iizym-0.png[0]'[paperclip] An error was received while processing: #<Paperclip::CommandNotFoundError: Could not run the `identify` command. Please install ImageMagick.>SQL (0.1ms)  BEGIN

1 个答案:

答案 0 :(得分:8)

您可以尝试使用符号链接从您的目录中识别到usr / bin目录。

ln -s /your/imagemagick/path/identify /usr/bin/identify