summaryrefslogtreecommitdiff
path: root/tidal_dl_ng/helper
diff options
context:
space:
mode:
authorexislow <exislow@users.noreply.github.com>2024-02-01 07:42:08 +0100
committerGitHub <noreply@github.com>2024-02-01 07:42:08 +0100
commit2ec3314b0714bc938b068084723d31ff1a854f16 (patch)
treef84ec117c3ef57f7513ceb434c9e55835c0e441c /tidal_dl_ng/helper
parent7c0d2ab2eabfc8574f569752465035557baa2875 (diff)
parentce9afc1629c5fdb7ef74f2c5fcd9f9bdde527efc (diff)
downloadtidal-dl-ng-2ec3314b0714bc938b068084723d31ff1a854f16.tar.gz
Merge pull request #25 from exislow/pkce
Pkce
Diffstat (limited to 'tidal_dl_ng/helper')
-rw-r--r--tidal_dl_ng/helper/path.py20
1 files changed, 10 insertions, 10 deletions
diff --git a/tidal_dl_ng/helper/path.py b/tidal_dl_ng/helper/path.py
index a2ce98c..373f78c 100644
--- a/tidal_dl_ng/helper/path.py
+++ b/tidal_dl_ng/helper/path.py
@@ -23,7 +23,7 @@ def path_home() -> str:
return os.path.abspath("./")
-def path_base() -> str:
+def path_config_base() -> str:
path_config: str = ".config"
path_base: str = os.path.join(path_home(), path_config, __name_display__)
@@ -34,30 +34,30 @@ def path_file_log() -> str:
# TODO: Remove this soon. Only for migration to new dir.
old = os.path.join(path_home(), ".tidal-dl-ng.log")
if os.path.isfile(old):
- os.makedirs(path_base(), exist_ok=True)
- os.rename(old, os.path.join(path_base(), "app.log"))
+ os.makedirs(path_config_base(), exist_ok=True)
+ os.rename(old, os.path.join(path_config_base(), "app.log"))
- return os.path.join(path_base(), "app.log")
+ return os.path.join(path_config_base(), "app.log")
def path_file_token() -> str:
# TODO: Remove this soon. Only for migration to new dir.
old = os.path.join(path_home(), ".tidal-dl-ng_token.json")
if os.path.isfile(old):
- os.makedirs(path_base(), exist_ok=True)
- os.rename(old, os.path.join(path_base(), "token.json"))
+ os.makedirs(path_config_base(), exist_ok=True)
+ os.rename(old, os.path.join(path_config_base(), "token.json"))
- return os.path.join(path_base(), "token.json")
+ return os.path.join(path_config_base(), "token.json")
def path_file_settings() -> str:
# TODO: Remove this soon. Only for migration to new dir.
old = os.path.join(path_home(), ".tidal-dl-ng_settings.json")
if os.path.isfile(old):
- os.makedirs(path_base(), exist_ok=True)
- os.rename(old, os.path.join(path_base(), "settings.json"))
+ os.makedirs(path_config_base(), exist_ok=True)
+ os.rename(old, os.path.join(path_config_base(), "settings.json"))
- return os.path.join(path_base(), "settings.json")
+ return os.path.join(path_config_base(), "settings.json")
def format_path_media(fmt_template: str, media: Track | Album | Playlist | UserPlaylist | Video | Mix) -> str: