我在Rails 3中使用回形針。試圖上傳圖片。我看了一些其他問題,但我似乎無法解決它。回形針給出錯誤,可能是由於錯誤的路徑變量?
我得到這個錯誤試圖挽救我的模型:
Photo C:/Users/Benjamin/AppData/Local/Temp/ben_2.png20120408-3864-l1w6rb is not recognized by the 'identify' command.
Photo C:/Users/Benjamin/AppData/Local/Temp/ben_2.png20120408-3864-l1w6rb is not recognized by the 'identify' command.
在我development.rb
我有
Paperclip.options[:command_path] = "/c/Program Files/ImageMagick-6.7.6-Q16/convert"
運行的轉換給了我:
$ which convert
/c/Windows/system32/convert
運行的識別給我:
$ which identify
//empty line
我的路徑是這樣的:
C:\ Program Files文件\的ImageMagick-6.7.6-Q16; C:\ WINDOWS \ SYSTEM32; C:\ WINDOWS; C:\ WINDOWS \ SYSTEM32 \ WBEM; C:\ Windows \ System32 \ WindowsPowerShell \ v1.0 \; C:\ Program Files \ Smart Projects \ IsoBuster; c:\ Program Files \ Microsoft SQL Server \ 100 \ Tools \ Binn \; c:\ Program Files \ Microsoft SQL Server \ 100 \ DTS \ Binn \; C:\ Program Files \ MiKTeX 2.9 \ miktex \ bin \
任何幫助我做錯了什麼?
哦,是的,我試過做哪些識別,並有一個換行符,沒有別的。 – benjgorman 2012-04-08 01:30:03
你有與imagemagick安裝的PNG庫嗎?檢查識別語法幫助 - 在那裏有一個選項來顯示它所知道的格式。 – Zabba 2012-04-08 01:48:44
jpegs不工作,所以我猜這不是錯誤? – benjgorman 2012-04-08 01:53:39