Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Exch(1) – atomically exchanges paths between two files (2023) (man7.org)
15 points by jesprenj on May 30, 2024 | hide | past | favorite | 4 comments


I think the time it would take me to remember the command, look at the man page to see if I had it right, and then do the command, I could have done the three mv commands

mv zork mytemp

mv advent zork

mv mytemp advent


Not atomic. We are talking renameat2 () here



I'm surprised this isn't in more standard libraries, are there any other atomic file operations being neglected like this?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: