About 249,000 results
Open links in new tab
  1. python - How do I copy a file? - Stack Overflow

    Sep 23, 2008 · Special files such as character or block devices and pipes cannot be copied with this function. src and dst are path names given as strings. Take a look at filesys for all the file …

  2. Copy multiple files in Python - Stack Overflow

    Nov 27, 2018 · How to copy all the files present in one directory to another directory using Python. I have the source path and the destination path as string.

  3. python - How to Copy Files Fast - Stack Overflow

    Oct 26, 2024 · What is the fastest way to copy files in a python program? It takes at least 3 times longer to copy files with shutil.copyfile() versus to a regular right-click-copy > right-click-paste …

  4. shutil - How do I copy an entire directory of files into an existing ...

    There is a Python issue about changing shutil.copytree() 's behavior to allow writing to an existing directory, but there are some behavior details that need to be agreed on.

  5. Python - What is the fastest way i can copy files from a source …

    Feb 2, 2012 · If you want to copy recursively, use os.walk (see other question: Python recursive folder read). You can adapt the solution accordingly. Note that "fastest" is a broad term. Hard …

  6. Copy file or directories recursively in Python - Stack Overflow

    Python seems to have functions for copying files (e.g. shutil.copy) and functions for copying directories (e.g. shutil.copytree) but I haven't found any function that handles both. Sure, it's …

  7. Copy file with pathlib in Python - Stack Overflow

    Nov 10, 2015 · As per the comments, one can use write_bytes and read_bytes to copy text files, but if you need to deal with the encoding at copy time write_text an read_text present the …

  8. How to copy directory recursively in python and overwrite all?

    I'm trying to copy /home/myUser/dir1/ and all its contents (and their contents, etc.) to /home/myuser/dir2/ in python. Furthermore, I want the copy to overwrite everything in dir2/. It …

  9. Python - Move and overwrite files and folders - Stack Overflow

    I wanted to move files and folder structures and overwrite existing files, but not delete anything which is in the destination folder structure. I solved it by using os.walk(), recursively calling my …

  10. Python: How to move or copy Azure Blob from one container to …

    Sep 10, 2015 · Move is not natively supported in Azure Storage. You can accomplish move operation by performing copy operation, wait for the copy to finish (very important because …

Refresh