Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Duplicate files & folders without content
# http://stackoverflow.com/a/25847006/262455
# If there are only directories and regular files, you can do something like this:
cd "$src"
find . -type d -print0 | ( cd "$dst" ; xargs -0 mkdir -p )
find . -type f -print0 | ( cd "$dst" ; xargs -0 touch )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment