Compare commits
No commits in common. "22ae8e095f4b9e9336cddf75e3bb7ae8f3a48616" and "391d60822a6eb42394d99b49e34261254e3203b2" have entirely different histories.
22ae8e095f
...
391d60822a
2 changed files with 4 additions and 2 deletions
|
@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "wallman"
|
name = "wallman"
|
||||||
version = "1.3.3.1"
|
version = "1.3.3.0"
|
||||||
authors = [
|
authors = [
|
||||||
{name = "Emma Nora Theuer", email = "wallman@entheuer.de"},
|
{name = "Emma Nora Theuer", email = "wallman@entheuer.de"},
|
||||||
]
|
]
|
||||||
|
|
|
@ -19,6 +19,8 @@ class _ConfigLib:
|
||||||
with open("wallman.toml", "rb") as config_file:
|
with open("wallman.toml", "rb") as config_file:
|
||||||
data = tomllib.load(config_file)
|
data = tomllib.load(config_file)
|
||||||
return data
|
return data
|
||||||
|
# a = list(data["changing_times"].values())
|
||||||
|
# print(a[0])
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.config_file: dict = self._initialize_config() # Full config
|
self.config_file: dict = self._initialize_config() # Full config
|
||||||
|
@ -37,7 +39,6 @@ class _ConfigLib:
|
||||||
self.config_notify = False
|
self.config_notify = False
|
||||||
logger.warning("'notify' is not set in dictionary general in the config file, defaulting to 'false'.")
|
logger.warning("'notify' is not set in dictionary general in the config file, defaulting to 'false'.")
|
||||||
|
|
||||||
# Setup logging
|
|
||||||
self._set_log_level()
|
self._set_log_level()
|
||||||
|
|
||||||
def _set_log_level(self):
|
def _set_log_level(self):
|
||||||
|
@ -182,6 +183,7 @@ class WallpaperLogic(_ConfigLib):
|
||||||
logger.info(f"The wallpaper {self.wallpaper_list[self.current_time_range]} has been set.")
|
logger.info(f"The wallpaper {self.wallpaper_list[self.current_time_range]} has been set.")
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
||||||
def _notify_user(self):
|
def _notify_user(self):
|
||||||
system("notify-send 'Wallman' 'A new Wallpaper has been set.'")
|
system("notify-send 'Wallman' 'A new Wallpaper has been set.'")
|
||||||
logger.debug("Sent desktop notification.")
|
logger.debug("Sent desktop notification.")
|
||||||
|
|
Loading…
Reference in a new issue