dune
dune copied to clipboard
fix: atomically copy dir targets from sandbox
Instead of manually traversing the directory and moving things file by file, we rely on one call of [Unix.rename].
The advantage is that we move the direcory atomically. Previously, an error could interrupt the recursive rename and leave _build/ with some partially copied directory.
Signed-off-by: Rudi Grinberg [email protected]
ps-id: 39a65638-5953-4ed5-bcae-bbb13c63e46f