mardi 4 juillet 2017

Shell Script output contains multiple words

I am trying to create a script in which I am running a command which gives a output. I am interested in few words in the output, I am using following script:

cfservices=$(cf services)<br/>
if [[ $cfservices == *"postgres...."* ]]; then<br/>
echo " done "<br/>
else<br/>
echo " fail "

but this helps find only one word. Please help me find multiple words.

Aucun commentaire:

Enregistrer un commentaire