Sunday, February 7, 2010

Tip #11: Careful, Mac OS overwrites, not merges folders

When copying a folder to a destination which has an existing folder of the same name, Mac OS will overwrite the entire contents of the old folder with the new one's, instead of merging the contents (and optionally, overwriting files with the same name) as in Windows.

This tip is best understood by an example, which you could follow along if you are a Mac user. On your Desktop, create a folder named Alice (don't ask why). Open TextEdit, and save an empty text file into that folder, named X. Now go to your home folder, and create a folder also named Alice. Using TextEdit again, save another empty text file into the second Alice folder, named Y.

With your home folder still open in a Finder window, drag the Alice folder which is in your home folder onto your desktop. 



Mac OS will tell you that a folder with the same name exists in the location you are moving the folder to (strangely enough, the title of the prompt says "Copy"), and ask you if you want to replace it. If you choose Replace, file X will be gone in the original folder on the Desktop, and replaced by file Y.

Therefore, if you wish to merge the contents of two identically-named folders, you will need to select all files in the source folder (Command + A), then drag them to the destination folder. Mac OS will then ask you one by one for each file from the source folder which has an identical twin in the destination folder, whether you want to replace, not replace, or stop the whole copy operation altogether.

What if you want to overwrite folder contents in Windows? Just delete the destination folder, and copy the source folder to the destination folder's location!

No comments :

Post a Comment

All comments are subject to moderation. If you don't want to sign in, comment as "Name/URL".