Abstract • Install • Usage • Setup Virtual Environment • Configure • Contributing
## Abstract Create a deluge python client for interfacing with deluge for common tasks like listing, adding, removing and setting download directory for torrents. ## Install Install from source: ```bash python3 setup.py install ``` Install from pip: ```bash pip3 install delugeClient-kevin ``` ## Usage View delugeClient cli options with `delugeclient --help`: ``` Usage: python -m delugeclient [OPTIONS] COMMAND [ARGS]... ╭─ Options ───────────────────────────────────────────────────────────────╮ │ --debug Set log level to debug │ │ --info Set log level to info │ │ --warning Set log level to warning │ │ --error Set log level to error │ │ --install-completion Install completion for the current shell. │ │ --show-completion Show completion for the current shell │ │ --help Show this message and exit. │ ╰─────────────────────────────────────────────────────────────────────────╯ ╭─ Commands ──────────────────────────────────────────────────────────────╮ │ add Add magnet torrent │ │ disk Get free disk space │ │ get Get torrent by id or hash │ │ ls List all torrents │ │ remove Remove torrent by id or hash │ │ rm Remove torrent by name │ │ search Search for string segment in torrent name │ │ toggle Toggle torrent download state │ │ version Print package version │ ╰─────────────────────────────────────────────────────────────────────────╯ ``` ### Running from source Run from source for fun or during development using module flag: ``` python3 -m delugeClient --help ``` ## Setup Virtual Environment Virtual environment allows us to create a local environment for the requirements needed. Because pip does not download packages already downloaded to your system, we can use virtualenv to save our packages in the project folder. ### Installation To install virtualenv, simply run: ``` $ pip install virutalenv ``` ### Virtualenv setup After you have downloaded this project go to it in your terminal by going to the folder you downloaded and typing the following: ``` $ cd delugeClient/ ``` The to setup a virtual environment enter this: ``` $ virtualenv -p python3.10 env ``` > If you get an error now it might be because you don't have python3.10, please make sure you have python version 3.10 if else you can download it from [here](https://www.python.org/downloads/) Then we use the ```virtualenv``` command to create a ```env``` subdirectory in our project. This is where pip will download everything to and where we can add other specific python versions. Then we need to *activate* our virtual environment by doing: ``` $ source env/bin/activate ``` You should now see a ```(env)``` appear at the beginning of your terminal prompt indicating that you are working from within the virtual environment. Now when you install something: ``` $ pip install