Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

image_optim installs without checking for existence of /usr/bin/which #59

Closed
grepwood opened this issue Aug 26, 2014 · 2 comments
Closed

Comments

@grepwood
Copy link

While trying to optimize a picture, image_optim failed because /usr/bin/which was not present on the system. Is it possible that Gem would check if /usr/bin/which exists so that it can install only if this dependency is satisfied?

@toy
Copy link
Owner

toy commented Aug 26, 2014

Do you mean not installing gem if which is not present?
Looking at stackoverflow question it seems better to avoid which. Also it seems that it would be best to use version method which should return empty string if binary is not present.

@grepwood
Copy link
Author

Exactly. The code that requires which is lib/image_optim/config.rblib/image_optim/binary_resolver.rb and on some systems which isn't provided by default. The user has to install it on their own. If you're planning on replacing which with builtin bash functions, then #59 will become a non-issue as soon as that happens. Confirming that it's fixed.

@toy toy closed this as completed in 27be9b4 Aug 29, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants