No description
- Python 100%
er156524ili 51,29",2ull2555ilater22iliserter1103"; ilater64500047,44ili443eller3,156eli,1,ull2 113illarrili1ili41,11传奇2ilili [["2iles225, 1614ullili 1ili2ili1iler11celeai40ili4leriili1112ili11ili传奇ina11leri2нер25ilipliers461,ullili42ili2ili2,ili2112121*11leri4201ili212ili2132ili"; ili3252erili, 4"; iliili0 # Previous message: refactor: move sonarr modules to thwap.sonarr namespace Co-authored-by: aider (deepseek/deepseek-reasoner) <aider@aider.chat> |
||
|---|---|---|
| thwap | ||
| .gitignore | ||
| directory-structure.txt | ||
| pyproject.toml | ||
| README.md | ||
| setup.py | ||
| sonarr-mover.py | ||
thwap-sonarr: Sonarr Utilities
A Python package for managing Sonarr shows and root folders.
Installation
From source
git clone <repository>
cd thwap-sonarr
pip install -e .
As a standalone script
You can run sonarr-mover.py directly:
chmod +x sonarr-mover.py
./sonarr-mover.py --help
Configuration
Set environment variables:
SONARR_API_KEY: Your Sonarr API key (required)SONARR_URL: Sonarr base URL (default:http://localhost:8989)
Usage
Command Line
# List available root folders
sonarr-mover -l
# List shows in a specific folder
sonarr-mover -l "/path/to/root/folder"
# Move all shows from one root folder to another
sonarr-mover "/source/share" "/target/share"
# Move a specific show by its exact path
sonarr-mover "/path/to/show" "/target/share"
Options
-v, --verbose: Enable verbose debug output-n, --dry-run: Perform a dry run without making changes-y, --assume-yes: Assume "yes" to all prompts (use with caution!)-l [FOLDER]: List root folders, or shows in a given folder
Python API
from thwap.sonarr import SonarrClient, get_sonarr_config
# Get configuration from environment
base_url, api_key = get_sonarr_config()
# Create client
client = SonarrClient(base_url, api_key, verbose=True)
# Get root folders
folders = client.get_root_folders()
# Get all series
series = client.get_series()
Development
Project follows Python conventions as described in conventions/python.md.
Run tests (if any) with pytest:
pytest
License
MIT