tldr/pages/osx/ditto.md

17 lines
579 B
Markdown
Raw Normal View History

2015-12-31 00:50:05 +00:00
# ditto
> Copy files and directories.
> More information: <https://keith.github.io/xcode-man-pages/ditto.1.html>.
2015-12-31 00:50:05 +00:00
- Overwrite contents of destination directory with contents of source directory:
2015-12-31 00:50:05 +00:00
`ditto {{path/to/source_directory}} {{path/to/destination_directory}}`
2015-12-31 00:50:05 +00:00
- Print a line to the Terminal window for every file that's being copied:
2015-12-31 00:50:05 +00:00
`ditto -V {{path/to/source_directory}} {{path/to/destination_directory}}`
2015-12-31 00:50:05 +00:00
- Copy a given file or directory, while retaining the original file permissions:
2015-12-31 00:50:05 +00:00
`ditto -rsrc {{path/to/source_directory}} {{path/to/destination_directory}}`