From f2cda233e22a426cb5b657514da0a386d99b289e Mon Sep 17 00:00:00 2001 From: Alexander Vasarab Date: Thu, 9 Jul 2020 14:22:15 -0700 Subject: [PATCH] Implement 'auto-start in GUI' feature --- munter/munter.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/munter/munter.py b/munter/munter.py index 8efe665..062e676 100644 --- a/munter/munter.py +++ b/munter/munter.py @@ -183,6 +183,10 @@ def main(): fitness=fitness, rate=travel_mode, units=units) + # auto-start in GUI mode if the program is not invoked from terminal + if len(sys.argv) == 1 and not sys.stdin.isatty(): + gui = True + if gui: from . import gui gui.startup() -- 2.30.2