Search This Blog

Total Pageviews

Tuesday, 30 August 2011

Unix find command on shell script

cat mfind.sh


echo "enter the path:\c"
read path
echo "enter the file name:\c"
read filename
find $path -name $filename -print > x
nl=`wc -l < x`
if [ $nl -eq 0 ]
then
echo File not found
else
cat < x
fi

No comments:

Oracle DBA

anuj blog Archive