grep for word not working

Hi All..I need a help i am trying to find a word using below script whereas the word exists in my file nitin.txt as a directory but still i am getting "word not found" output..Your suggestions welcomed.:
#to check for existence of nitin

#!/bin/bash
cd /apps/uat1/deploy/app

ls -lrt > nitin.txt


FILE=/apps/uat1/deploy/app/nitin.txt

grep -w "*nitin*" $FILE >/dev/null

if [ $? -eq 0 ]
then
   echo "Word found!"
else
   echo "Word NOT found!"
fi

Hi, you are using wild cards (*) as in a globbing situation, whereas grep uses regular expressions so the equivalent would be ".*nitin.*" . With grep this makes little sense however.

If you are looking for the word nitin, you could use this:

grep -w nitin "$FILE"

or for words that contain nitin:

grep nitin "$FILE"

additionally you can use -q to silence grep, so you could do something like this:

if grep -q nitin "$FILE"
then
   echo 'Word found!'
else
   echo 'Word NOT found!'
fi

Thnaks Scrutinizer!!!

It is helpful..
can you please tell me the case when i have to search nitin and there are entry in file like delhiNitin_Unix then how to match nitin here in same situation as explained above just .

what we need to change in below pattern:
grep -w nitin "$FILE"

I gather you do not require a word match, so we do not need -w and we need -i to ignore upper and lower case distinction, so I'd say:

grep -i nitin "$FILE" 

Thnx a lot Scrutinizer :b:..its working ..Now i am moving forward in my script ..
I will keep following you for next times also.