-d


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting -d
# 1  
Old 03-29-2006
-d

why we use -d in script?
# 2  
Old 03-29-2006
Quote:
Originally Posted by debasis.mishra
why we use -d in script?
-d can be used for so many things. Unless you show us the code snippet, it is hard to give a definitive answer.

Guessing... look into man test to see about -d.
# 3  
Old 03-29-2006
Where is this -d being used? Is it for a particular command? If so, then check the man page for that command.
# 4  
Old 03-29-2006
reply about -d

Actually my friend using the -d in this code.

if [ -d $LOG_DIR ]
then
cd $LOG_DIR
echo $LOG_DIR >> $LOG_FILE
find . \( -name '*.log*' -type f \) -mtime +30 -exec rm -f {} \;
fi
# 5  
Old 03-29-2006
As I said ealier, look into man test to see the description about -d
# 6  
Old 03-29-2006
i got the solution.thanks
# 7  
Old 03-29-2006
will u tell me what is this meaning?

find . \( -name '*.log*' -type f \) -mtime +30 -exec rm -f {} \;

What it will search the file which is less than 30 minutes?
Login or Register to Ask a Question

Previous Thread | Next Thread
Login or Register to Ask a Question