Atomic rename temp file vs Deno.lockFile for retry-safe writes
A design needs to write a single output file with automatic retries and avoid duplicated or partial writes when multiple invocations overlap. The constraint is cross-platform consistency and no built-in atomic-write helper in the Deno standard library. One documented approach is write-to-temp then Deno.rename. On POSIX systems rename is commonly atomic, whic