in reply to unlink and -U
Please note the caveat about errors at the end its perldoc.
Update: File::Path exports mktree and rmtree by default, so use File::Path; will suffice.
After Compline,Zaxo