Client for cloud Yandex.Disk
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
YaDiskClient Add link to related article. Jun 4, 2018
tests Add tests. Jan 8, 2018
.gitignore Add some tests. Jan 26, 2014
.travis.yml Fix source path for coverage. Jan 8, 2018
LICENSE Create package YaDiskClient. Jan 26, 2014
MANIFEST.in Create package YaDiskClient. Jan 26, 2014
README.rst Amend. Jun 4, 2018
setup.py Fix documentation. Jan 7, 2018

README.rst

YaDiskClient

https://travis-ci.org/TyVik/YaDiskClient.svg?branch=master https://coveralls.io/repos/github/TyVik/YaDiskClient/badge.svg?branch=master

Client for Yandex.Disk based on WebDav.

Install

pip install YaDiskClient

Source code

github

explanatory article

Using API

from YaDiskClient.YaDiskClient import YaDisk
disk = YaDisk(login, password)

disk.df() # show used and available space

disk.ls(path) # list of files/folder with attributes
disk.mkdir(path) # create directory

disk.rm(path) # remove file or directory
disk.cp(src, dst) # copy from src to dst
disk.mv(src, dst) # move from src to dst

disk.upload(src, dst) # upload local file src to remote file dst
disk.download(src, dst) # download remote file src to local file dst

disk.publish_doc(path) # return public url
disk.hide_doc(path) # remove public url form Yandex Disk

Tests

For run tests:
  1. Set Yandex username and password in file tests/test_YaDiskClient.py
  2. python -m unittest discover -s tests -t tests