I need to move a folder using unix mv command, but only if the target is in the same drive or the same filesystem. What would be the best approach?
migrated from stackoverflow.com Apr 29 at 22:37
This question came from our site for professional and enthusiast programmers.
So you can:
and then compare.
You can also write like this:
Other option. Also taken from the Stackexchange question:
|show 2 more comments|
This is probably not the cleanest solution, but you could use the fact that hard links can't be created between drives.