check if any program is instaled


I have problem sometimes when i write application and wont check if any application exist in the
system.


#It is simple example witch functions 

if_i_am () {
    type "$1" 2>&1 ;
}
if if_i_am hddtemp ; then
   hddtemp_tool="1"
else
   hddtemp_tool="0"
exit
fi
Advertisements

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s