refactor(KIAUH): add application root to sys path

shortens imports and helps with auto imports from IDE

Signed-off-by: Dominik Willner <th33xitus@gmail.com>
This commit is contained in:
dw-0
2024-02-18 22:30:28 +01:00
parent 573dc7c3c9
commit 2a4fcf3a3a
43 changed files with 215 additions and 210 deletions

View File

@@ -9,7 +9,11 @@
# This file may be distributed under the terms of the GNU GPLv3 license #
# ======================================================================= #
import sys
from pathlib import Path
APPLICATION_ROOT = Path(__file__).resolve().parent.parent
KIAUH_CFG = APPLICATION_ROOT.joinpath("kiauh.cfg")
PROJECT_ROOT = Path(__file__).resolve().parent.parent
KIAUH_CFG = PROJECT_ROOT.joinpath("kiauh.cfg")
APPLICATION_ROOT = Path(__file__).resolve().parent
sys.path.append(str(APPLICATION_ROOT))