Answers for "copy files to directory python"

6

python copy file to another directory

import shutil
shutil.copy2('/src/dir/file.ext', '/dst/dir/newname.ext') # complete target filename given
shutil.copy2('/src/file.ext', '/dst/dir') # target filename is /dst/dir/file.ext
Posted by: Guest on February-22-2021
0

copyfile pyhon

from shutil import copyfile
copyfile(src, dst)
Posted by: Guest on October-03-2020

Code answers related to "copy files to directory python"

Python Answers by Framework

Browse Popular Code Answers by Language