Terminal User Guide
In Terminal, you can move and copy files locally or remotely using the
mv
, cp
, and scp
command-line tools.Disk Utility is free and included with every copy of the Mac OS. And while the various cloning apps have a lot more features, if you don’t have access to third-party apps, using Disk Utility will create a perfectly usable clone, although it may require a few more steps and lacks some nice features, such as automation and scheduling. Use disk cloning software to create a bootable USB or CD/DVD drive. To clone a hard drive means to make a 1-to-1 copy of the original drive. It's the quickest and easiest approach to replace a hard drive along with its data. By cloning a disk to a new one, you can escape from the tedious work of transferring data and programs to the new drive.
Mac Users: Clone Your Drive with SuperDuper If you're on a Mac, we recommend SuperDuper for all your cloning needs. It's free, simple to use, and has been around for years.
Mac notes app deleted my notes. Tip: It’s easier to move and copy files using the Finder. See Organize files in folders.
Move a file or folder locally
![Drive Copy Mac App Drive Copy Mac App](/uploads/1/3/3/9/133900290/874271039.png)
- In the Terminal app on your Mac, use the
mv
command to move files or folders from one location to another on the same computer. Themv
command moves the file or folder from its old location and puts it in the new location.Mac app store twist. For example, to move a file from your Downloads folder to a Work folder in your Documents folder:% mv ~/Downloads/MyFile.txt ~/Documents/Work/MyFile.txt
You can also change the name of the file as it’s moved:% mv ~/Downloads/MyFile.txt ~/Documents/Work/NewFileName.txt
See the mv command man page.
Copy a file or folder locally
- In the Terminal app on your Mac, use the
cp
command to make a copy of a file.Leica app for mac. For example, to copy a folder named Expenses in your Documents folder to another volume named Data:% cp -R ~/Documents/Expenses /Volumes/Data/Expenses
The-R
flag causescp
to copy the folder and its contents. Note that the folder name does not end with a slash, which would change howcp
copies the folder.
See the cp command man page.
Copy a file or folder remotely
- In the Terminal app on your Mac, use the
scp
command to copy a file or folder to or from a remote computer.scp
uses the same underlying protocols asssh
.For example, to copy a compressed file from your home folder to another user’s home folder on a remote server:% scp -E ~/ImportantPapers.tgz [email protected]:/Users/username/Desktop/ImportantPapers.tgz
You’re prompted for the user’s password.The-E
flag preserves extended attributes, resource forks, and ACL information.The-r
flag, which isn’t used in this example, causesscp
to copy a folder and its contents.
Drive Copy Mac App Download
See the scp command man page.
Mac App Store Download
See alsoOpen or quit Terminal on MacOpen new Terminal windows and tabs on MacExecute commands and run tools in Terminal on Mac