I need to check out whether my linux system installation have "convert" command available. Is there a command to control this situation?
Asked
Active
Viewed 76 times
0
1 Answers
1
To determine if a command is available
which <command>
In your case
which convert
Or use locate
sudo updatedb #necessary if you recently installed
locate convert
convert is a part of imagemagick , so to install
sudo apt-get install imagemagick

Panther
- 102,067
-
-
@heemayl - why not ? convert is a bit strange as it is a part of imagemagik – Panther May 30 '15 at 19:04
-
at the very least level, why would you fork an external process that
type
orhash
can do easily....the link has farther explanations.... – heemayl May 30 '15 at 19:07 -
@heemayl - that link seems a little off topic to say the least (running which in scripts), not to mention somewhat opinionated and even inaccurate. With modern computers launching a separate process is rather trivial (0.012 seconds, really ?) and which does set an exit status. – Panther May 30 '15 at 19:30
http://stackoverflow.com/questions/592620/check-if-a-program-exists-from-a-bash-script
– Anders May 30 '15 at 18:48which convert
– Panther May 30 '15 at 18:48type -a convert
– heemayl May 30 '15 at 18:49