onedrive.cli module¶
CLI interfaces for this package.
- class onedrive.cli.CopyWorker(client, src, dst, recursive=False, overwrite=False, show_progress=False)[source]¶
Bases: multiprocessing.context.Process
A worker for copying an item on OneDrive.
Parameters: client : onedrive.api.OneDriveAPIClient
src, dst : str
Source and destination of the copy operation. Passed to onedrive.api.OneDriveAPIClient.copy.
recursive : bool, optional
Whether to allow recursive copying of a directory. Default is False.
overwrite, show_progress : bool, optional
Passed to onedrive.api.OneDriveAPIClient.copy. Defaults are False.
Attributes
src, dst (str)
- class onedrive.cli.Downloader(client, download_kwargs)[source]¶
Bases: builtins.object
Downloader that downloads files from OneDrive.
- class onedrive.cli.Uploader(client, directory, upload_kwargs)[source]¶
Bases: builtins.object
Uploader that uploads files to a given OneDrive directory.
Parameters: client : onedrive.api.OneDriveAPIClient
directory : str
Remote directory to upload to.
upload_kwargs : str
Keyword arguments directly passed to onedrive.api.OneDriveAPIClient.upload.