Skip to content

Instantly share code, notes, and snippets.

@tarmolehtpuu
Created July 20, 2011 17:13
Show Gist options
  • Save tarmolehtpuu/1095382 to your computer and use it in GitHub Desktop.
Save tarmolehtpuu/1095382 to your computer and use it in GitHub Desktop.
Quick hack to symlink ImageMagick binaries to /usr/bin (probably simplest way to fix it for Rubymine)
#!/usr/bin/env ruby
PATH_SRC = "/usr/local/bin"
PATH_DST = "/usr/bin"
%w[animate compare composite conjure convert display identify import mogrify montage stream].each do |file|
if File.exists?("#{PATH_DST}/#{file}")
puts "[EXIST]: #{file}"
else
puts "[LINK] : #{file}" and system("ln -s #{PATH_SRC}/#{file} #{PATH_DST}/#{file}")
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment