2012-01-04 21 views
5

私はImageMagick-6.7.4をレール3で使用しており、paperclip gemをアプリケーションにインストールしました。私はをインストールしてimagemagickをインストールし、私の端末からは動作しますが、私のレールアプリでは動作しません。私はsh:identify:コマンドが見つかりませんimageemagick rails 3

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

としての私のdevelopment.rbで特定のコマンドのパスが含まれていたが、それはまだ私にあなたがUSRするディレクトリから識別するために、シンボリックリンクを作ってみることができます

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 

答えて

8

としてエラーが発生します/ binディレクトリに移動します。

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

また、 '/ your/imagemagick/path'を' $ PATH'に追加します(ただし、Railsアプリケーションのコンテキストで行います)。 –

+0

あなたの応答のためにありがとうございました今私の身分証明書パスはPaperclip.options [:command_path] = "/ opt/local/bin /"ですが、以前は私のホームフォルダにインストールしました。これが違いを生み出したかどうかは分かりませんが、今はうまくいきます –

関連する問題