reverted config changes

This commit is contained in:
Hellow
2023-08-28 21:08:42 +02:00
parent 2da7459595
commit c66b021ecc
25 changed files with 17 additions and 48 deletions

View File

@@ -1 +1 @@
from .old_config import config, read_config, write_config
from .config import config, read_config, write_config

View File

@@ -1,40 +0,0 @@
from dynaconf import Dynaconf
from dynaconf import settings
from dynaconf.utils import object_merge
# from .path_manager import LOCATIONS
"""
https://www.dynaconf.com/settings_files/
This file is there to load the settings.
How I will structure this programm exactly is in the stars.
The concept is that I package a config file, with this programm, and then load it.
Then I check if there is a config file at the LOCATIONS.CONFIG_FILE, and if yes they get merged
"""
settings.happy_message = [
"Support the artist.",
"Star Me: https://github.com/HeIIow2/music-downloader",
"🏳️‍⚧️🏳️‍⚧️ Trans rights are human rights. 🏳️‍⚧️🏳️‍⚧️",
"🏳️‍⚧️🏳️‍⚧️ Trans women are women, trans men are men, and enbies are enbies. 🏳️‍⚧️🏳️‍⚧️",
"🏴‍☠️🏴‍☠️ Unite under one flag, fck borders. 🏴‍☠️🏴‍☠️",
"Join my Matrix Space: https://matrix.to/#/#music-kraken:matrix.org",
"Gotta love the BPJM ;-;",
"🏳️‍⚧️🏳️‍⚧️ Protect trans youth. 🏳️‍⚧️🏳️‍⚧️",
"Nonstop Progressive Marxism.",
]
dynacont_object = Dynaconf(
settings_files=[str(LOCATIONS.CONFIG_FILE)]
)
class Settings:
def __init__(self) -> None:

View File

@@ -19,7 +19,7 @@ class Locations:
self.CONFIG_DIRECTORY = get_config_directory(str(application_name))
self.CONFIG_DIRECTORY.mkdir(exist_ok=True, parents=True)
self.CONFIG_FILE = Path(self.CONFIG_DIRECTORY, f"{application_name}.toml")
self.CONFIG_FILE = Path(self.CONFIG_DIRECTORY, f"{application_name}.conf")
self.LEGACY_CONFIG_FILE = Path(self.CONFIG_DIRECTORY, f"{application_name}.conf")
self.FFMPEG_BIN = Path(FFmpeg(enable_log=False).get_ffmpeg_bin())

View File

@@ -5,7 +5,7 @@ from typing import List, Tuple, Set, Dict
from urllib.parse import ParseResult
from .path_manager import LOCATIONS
from .old_config import LOGGING_SECTION, AUDIO_SECTION, CONNECTION_SECTION, MISC_SECTION, PATHS_SECTION
from .config import LOGGING_SECTION, AUDIO_SECTION, CONNECTION_SECTION, MISC_SECTION, PATHS_SECTION
from .enums.album import AlbumType
CONFIG_FILE = LOCATIONS.CONFIG_FILE