delete index file before writing to it (if change)

Otherwise, the file is writen in place and changes the hardlinked
ones too in older trees, therefore introduces inconsistencies in
older snapshotted trees.
Merge pull request #15 from dr4Ke/mirror_to_hardlinked_directory

Fix skel (indexes) updates in a hardlinked mirror