diff options
| author | Robert Honz <exislow+github@gmail.com> | 2024-01-13 11:57:11 +0100 |
|---|---|---|
| committer | Robert Honz <exislow+github@gmail.com> | 2024-01-13 11:57:11 +0100 |
| commit | 14483a162949dcdffc1fe36b5c4962f1926beaa3 (patch) | |
| tree | 7902058e3218d5b05eb1a5c14f8ae726bd429edf /tidal_dl_ng/model | |
| parent | 0cba5d83b1bfa212d3bdb7719f90740f513f01c2 (diff) | |
| download | tidal-dl-ng-14483a162949dcdffc1fe36b5c4962f1926beaa3.tar.gz | |
♻️ Some refactoring started within download.py.
✨ Track extension can be ignored while skipping files. Closes #11.
✨ Started to implement MPEG DASH download support.
Diffstat (limited to 'tidal_dl_ng/model')
| -rw-r--r-- | tidal_dl_ng/model/cfg.py | 6 | ||||
| -rw-r--r-- | tidal_dl_ng/model/tidal.py | 11 |
2 files changed, 14 insertions, 3 deletions
diff --git a/tidal_dl_ng/model/cfg.py b/tidal_dl_ng/model/cfg.py index 74e0305..ee0a856 100644 --- a/tidal_dl_ng/model/cfg.py +++ b/tidal_dl_ng/model/cfg.py @@ -3,13 +3,14 @@ from dataclasses import dataclass from dataclasses_json import dataclass_json from tidalapi import Quality -from tidal_dl_ng.constants import QualityVideo +from tidal_dl_ng.constants import QualityVideo, SkipExisting @dataclass_json @dataclass class Settings: - skip_existing: bool = False + skip_existing: SkipExisting = SkipExisting.Disabled + skip_existing_ignore_extension: bool = False album_cover_save: bool = True lyrics_save: bool = False # TODO: Implement API KEY selection. @@ -32,7 +33,6 @@ class Settings: metadata_cover_height: int = 320 -@dataclass_json @dataclass class HelpSettings: skip_existing: str = "Do not download, if file already exists." diff --git a/tidal_dl_ng/model/tidal.py b/tidal_dl_ng/model/tidal.py new file mode 100644 index 0000000..a5fbae9 --- /dev/null +++ b/tidal_dl_ng/model/tidal.py @@ -0,0 +1,11 @@ +from dataclasses import dataclass + + +@dataclass +class StreamManifest: + stream_url: str + codecs: str + mime_type: str + file_extension: str + encryption_type: str | None = None + encryption_key: str | None = None |
