sh:识别:未找到命令 imagemagick Rails 3

2023-12-24

我正在将 ImageMagick-6.7.4 与 Rails 3 一起使用,并且还安装了paperclip我的应用程序的宝石。我跟着本指南 https://www.imagemagick.org/script/download.php#macosx安装imagemagick它可以在我的终端上运行,但不能在我的 Rails 应用程序中运行。我已将识别命令的路径包含在我的development.rb中:

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

您可以尝试创建符号链接来识别从您的目录到 usr/bin 目录的情况。

ln -s /your/imagemagick/path/identify /usr/bin/identify
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

sh:识别:未找到命令 imagemagick Rails 3 的相关文章

随机推荐