cloudsync enables simple cloud file-level sync with a variety of cloud providers
Project description
cloudsync README
Python Cloud Synchronization Library
pip install cloudsync
Example:
from cloudsync import CloudSync, CloudSyncProvider
local = CloudSyncProvider("local", path="/usr/home/alice/test", monitor=True)
remote = CloudSyncProvider("gdrive", path="/test-folder")
remote.connect()
sync = CloudSync(local, remote)
sync.start()
with open("/usr/home/alice/test/hello.txt", "w") as f:
f.write("hello")
# give the monitor a second to notice the change
# alternatively we can "poke" the local provider, forcing a sync
time.sleep(1)
sync.wait(timeout=10)
# using no_poke to deliberately trick our sync into *not* knowing about the rename
remote.rename("/test-folder/hello.txt", "/test-folder/goodbye.txt", no_poke=True)
# we should still sync properly because of the event cursor
while not os.path.exists("/usr/home/alice/test/goodbye.txt"):
time.sleep(1)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
cloudsync-1.3.19a5.tar.gz
(186.4 kB
view details)
Built Distribution
cloudsync-1.3.19a5-py3-none-any.whl
(179.3 kB
view details)
File details
Details for the file cloudsync-1.3.19a5.tar.gz
.
File metadata
- Download URL: cloudsync-1.3.19a5.tar.gz
- Upload date:
- Size: 186.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.22.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 25b90fb928dd2728e801a7a4de37048a0a02a27aae90285873edea5c95602ad7 |
|
MD5 | 49839d188deb065d12554a1c205daf4d |
|
BLAKE2b-256 | 01cb5d4ae66143a5d3d9a159a7732150878a8a6579d03a21c7163cc58147acee |
File details
Details for the file cloudsync-1.3.19a5-py3-none-any.whl
.
File metadata
- Download URL: cloudsync-1.3.19a5-py3-none-any.whl
- Upload date:
- Size: 179.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.22.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8999ccf9dd14a40cad73fd4af7c0b66182ece34834967babd8f30e7750b544b5 |
|
MD5 | 5e662c407332738655dfadb0bb9f616f |
|
BLAKE2b-256 | c787e04f68a6a84c8df75cdd5803d0dc23a4f4fd21f69c27425812ce8ef16014 |