ui changes, loan quit with hotkey q if no lineedit in focus

This commit is contained in:
WorldTeacher
2024-07-31 10:02:27 +02:00
parent a0fce94298
commit 6d4b274b30
5 changed files with 102 additions and 7 deletions

View File

@@ -1,6 +1,6 @@
import omegaconf
import sys
# import argparse
__version__ = "0.0.1"
__author__ = "Alexander Kirchner"
@@ -9,5 +9,55 @@ config = omegaconf.OmegaConf.load("config/settings.yaml")
# if programm launched with argument --debug, set debug to True
if "--debug" in sys.argv:
config.debug = True
# if programm launched with argument --log, set log_debug
if "--log" in sys.argv:
config.log_debug = True
config.log_debug = True
# arguments = argparse.ArgumentParser(
# prog="Ausleihsystem",
# description="Ein Ausleihsystem für Handbibliotheken",
# epilog="Version: {}".format(__version__),
# )
# arguments.add_argument(
# "-d",
# "--debug",
# action="store_true",
# help="Display debug messages in terminal",
# default=False,
# required=False,
# )
# arguments.add_argument(
# "-v",
# "--version",
# action="store_true",
# help="Display version number",
# default=False,
# required=False,
# )
# arguments.add_argument(
# "-l",
# "--log",
# action="store_true",
# help="Log debug messages to logfile",
# default=False,
# required=False,
# )
# arguments.add_argument(
# "--no-backup",
# action="store_true",
# help="Disable backup",
# default=False,
# required=False,
# )
# args = arguments.parse_args()
# # based on the arguments, set the config values
# if args.debug:
# config.debug = True
# if args.version:
# print(f"Version: {__version__}")
# sys.exit()
# if args.log:
# config.log_debug = True
# if args.no_backup:
# config.database.do_backup = False