I have a process that creates a lockfile ~/process.lock
I wanted to execute a command as soon that process ended, so i wrote
while [ -e ~/process.lock ]
do
:
done
#do stuff after process has ended
Apparently this prevented process.lock being deleted by the parent process. Did this happen? If yes, why? and what is the correct way to do this.