how to find if particular package has been selected or not through shell script.