Created
November 12, 2015 04:34
-
-
Save jineshpaloor/22587df862fb9475b22e to your computer and use it in GitHub Desktop.
script to copy all files from one folder by traversing recursively to another folder
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
from shutil import * | |
rootdir = '/Users/jineshn/tools/Images.xcassets' | |
for subdir, dirs, files in os.walk(rootdir): | |
for file in files: | |
fn = os.path.join(subdir, file) | |
print fn | |
copyfile(fn, '/Users/jineshn/tools/output/'+file) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment