From 01248c39f168e1b91e44dc9d3064f88073f52669 Mon Sep 17 00:00:00 2001 From: Trigg Date: Tue, 17 May 2022 14:52:30 +0000 Subject: [PATCH] - Include installed version at start of log - Include installed version in 'about' screen --- discover_overlay/about_settings.py | 3 ++- discover_overlay/discover_overlay.py | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/discover_overlay/about_settings.py b/discover_overlay/about_settings.py index d1b57a1..ae47ac2 100644 --- a/discover_overlay/about_settings.py +++ b/discover_overlay/about_settings.py @@ -58,8 +58,9 @@ class AboutSettingsWindow(Gtk.Grid): self.attach(spacing_box_2, 1, 2, 1, 1) blurb = Gtk.Label.new(None) - message = "%s\n\n%s\n\n%s (https://discord.gg/jRKWMuDy5V) %s (https://github.com/trigg/Discover)\n\n\n\n\n\n" % ( + message = "%s (%s)\n\n%s\n\n%s (https://discord.gg/jRKWMuDy5V) %s (https://github.com/trigg/Discover)\n\n\n\n\n\n" % ( _("Welcome to Discover Overlay"), + pkg_resources.get_distribution('discover_overlay').version, _("Discover-Overlay is a GTK3 overlay written in Python3. It can be configured to show who is currently talking on discord or it can be set to display text and images from a preconfigured channel. It is fully customisable and can be configured to display anywhere on the screen. We fully support X11 and wlroots based environments. We felt the need to make this project due to the shortcomings in support on Linux by the official discord client."), _("Please visit our discord"), _(" for support. Or open an issue on our GitHub ") diff --git a/discover_overlay/discover_overlay.py b/discover_overlay/discover_overlay.py index 9f1c54c..534aa18 100755 --- a/discover_overlay/discover_overlay.py +++ b/discover_overlay/discover_overlay.py @@ -316,7 +316,7 @@ def entrypoint(): pid_file = os.path.join(config_dir, "discover_overlay.pid") rpc_file = os.path.join(config_dir, "discover_overlay.rpc") debug_file = os.path.join(config_dir, "output.txt") - logging.getLogger().setLevel(logging.WARNING) + logging.getLogger().setLevel(logging.INFO) FORMAT = "%(levelname)s - %(name)s - %(message)s" if "--debug" in sys.argv or "-v" in sys.argv: logging.getLogger().setLevel(logging.DEBUG) @@ -324,6 +324,8 @@ def entrypoint(): else: logging.basicConfig(format=FORMAT) log = logging.getLogger(__name__) + log.info("Starting Discover Overlay: %s", + pkg_resources.get_distribution('discover_overlay').version) # Flatpak compat mode try: