bloomreach / s4cmd

Super S3 command line tool
Apache License 2.0
1.37k stars 211 forks source link

Python Module version + non-blocking? #44

Open cedricjeanty opened 9 years ago

cedricjeanty commented 9 years ago

Could this eventually be a python module, rather than being geared more towards a command line tool? Specific features that would be really useful would be non-blocking behaviors (such as an upload/download manager that could be monitored by other code). Imagine this being part of a python GUI with a progress-bar or similar. What about progress based on bytes uploaded/downloaded versus file count. Finally, what about a continuous scan of an upload path where files are being progressively added, and then uploaded by the manager? Nice job on the code!

chouhanyang commented 8 years ago

s4cmd can be use as module. That is the Options class is used for. Simply create S3Handler and use the methods without using command-line. Is this what you're asking for?

dangetman commented 8 years ago

I've been trying to get this working and can't seem to figure out how to call this directly from python.

Would it be possible to provide a very simple example of what you are describing above? Just a call to get or sync from python would be extremely helpful.