|
scan and move
i have a script to look for a file, but it moves a file that's being used.
i want to use:
if file exists > 0, and not being updated/used in the last 2 minutes, move to /tmp
i can do this much:
if [ -s filename.txt ]
then
mv filename.txt /tmp
else
exit
fi
or how can i check if filename.txt is being used ?
|