iterative / PyDrive2

Google Drive API Python wrapper library. Maintained fork of PyDrive.
https://docs.iterative.ai/PyDrive2
Other
581 stars 69 forks source link

add copy method to drive.py #188

Closed simone-viozzi closed 2 years ago

simone-viozzi commented 2 years ago

Hi i added the copy method keeping it as simple as possible.

this PR fixes #83 #53

simone-viozzi commented 2 years ago

Where the test should go? on test_file.py or test_fs.py? they have very different structure

also, I can't seem to run the existing ones :) but is most likely because of the authentication.

shcheklein commented 2 years ago

@simone-viozzi please take a look^, especially the pre-commit hook, it means you need to run it locally. Tests - I'll check if I can run them from your branch.

shcheklein commented 2 years ago

Looks good to me @simone-viozzi , let me try to run tests for this ... and we can merge it soon. Thanks for the PR.

shcheklein commented 2 years ago

@simone-viozzi I've rebased the branch, everything runs fine!

The last thing to see is we need to update docs https://github.com/iterative/PyDrive2/tree/master/docs - could you please take a look?

simone-viozzi commented 2 years ago

i think we can add a short example in https://docs.iterative.ai/PyDrive2/filemanagement/

The documentation of the function itself are generated from the doc-string, right?

shcheklein commented 2 years ago

The documentation of the function itself are generated from the doc-string, right?

Yes, but I would see if there are mentions in those rsts. If not - that's fine.

If you can do a quick example - that would be great! If not that's also fine- not a blocker. Just let me know when you feel you are ready with that, and we'll merge it.

simone-viozzi commented 2 years ago

@shcheklein let's merge it like this. I plan to add other methods too like rename and move, so maybe I will do an example use case with those too.

shcheklein commented 2 years ago

@simone-viozzi done, thanks for the PR.