diff --git a/maloja/proccontrol/control.py b/maloja/proccontrol/control.py index fb04517..14b059b 100644 --- a/maloja/proccontrol/control.py +++ b/maloja/proccontrol/control.py @@ -4,6 +4,7 @@ from doreah.control import mainfunction from doreah.io import col import os import signal +from ipaddress import ip_address from .setup import setup from . import tasks @@ -94,6 +95,8 @@ def print_info(): print_header_info() print("Configuration Directory:",globalconf.dir_settings['config']) print("Data Directory: ",globalconf.dir_settings['state']) + print("Network: ",f"IPv{ip_address(globalconf.malojaconfig['host']).version}, Port {globalconf.malojaconfig['port']}") + print("Timezone: ",f"UTC{globalconf.malojaconfig['timezone']:+d}") print() print("#####") print() diff --git a/maloja/proccontrol/setup.py b/maloja/proccontrol/setup.py index 867f86e..af2ed2f 100644 --- a/maloja/proccontrol/setup.py +++ b/maloja/proccontrol/setup.py @@ -8,13 +8,12 @@ from ..globalconf import data_dir, dir_settings, malojaconfig # EXTERNAL API KEYS -apikeys = { - "LASTFM_API_KEY":"Last.fm API Key", - #"FANARTTV_API_KEY":"Fanart.tv API Key", - "SPOTIFY_API_ID":"Spotify Client ID", - "SPOTIFY_API_SECRET":"Spotify Client Secret", - "AUDIODB_API_KEY":"TheAudioDB API Key" -} +apikeys = [ + "LASTFM_API_KEY", + "SPOTIFY_API_ID", + "SPOTIFY_API_SECRET", + "AUDIODB_API_KEY" +] @@ -35,15 +34,16 @@ def setup(): print("Various external services can be used to display images. If not enough of them are set up, only local images will be used.") for k in apikeys: + keyname = malojaconfig.get_setting_info(k)['name'] key = malojaconfig[k] if key is False: - print("\t" + "Currently not using a " + col['red'](apikeys[k]) + " for image display.") + print("\t" + "Currently not using a " + col['red'](keyname) + " for image display.") elif key is None or key == "ASK": - print("\t" + "Please enter your " + col['gold'](apikeys[k]) + ". If you do not want to use one at this moment, simply leave this empty and press Enter.") + print("\t" + "Please enter your " + col['gold'](keyname) + ". If you do not want to use one at this moment, simply leave this empty and press Enter.") key = prompt("",types=(str,),default=False,skip=SKIP) malojaconfig[k] = key else: - print("\t" + col['lawngreen'](apikeys[k]) + " found.") + print("\t" + col['lawngreen'](keyname) + " found.") # OWN API KEY diff --git a/pyproject.toml b/pyproject.toml index 74a224b..a1e2f50 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -21,7 +21,7 @@ classifiers = [ dependencies = [ "bottle>=0.12.16", "waitress>=1.3", - "doreah>=1.7.1", + "doreah>=1.7.2", "nimrodel>=0.7.0", "setproctitle>=1.1.10", "wand>=0.5.4",