GoldyBot.paths
1import os 2import sys 3import GoldyBot 4 5MODULE_NAME = "PATHS" 6"""This module contains all the variables with paths to Goldy Bot folders and files.""" 7 8# Creating Path to module 9module_path = "" 10platform = sys.platform 11 12if platform == "win32": 13 module_path_list = os.path.abspath(GoldyBot.__file__).split("\\"); module_path_list.pop(-1) 14 15 for file in module_path_list: module_path += f"{file}/" 16 17else: 18 module_path_list = GoldyBot.__file__.split("/"); module_path_list.pop(-1) 19 20 for file in module_path_list: module_path += f"{file}/" 21 22# Goldy Bot Module Path 23GOLDY_BOT = module_path[:-1] 24"""Path to Goldy Bot module.""" 25 26# Folders 27LOGS = "./logs" 28CONFIG = "./config" 29MODULES = "./modules" 30 31ASSETS = f"{GOLDY_BOT}/assets" 32INTERNAL_COGS_V4 = f"{GOLDY_BOT}/internal_modules/v4" 33INTERNAL_MODULES_V4 = INTERNAL_COGS_V4 34INTERNAL_COGS_V3 = f"{GOLDY_BOT}/internal_modules/v3" 35TEMPLATES = f"{GOLDY_BOT}/templates" 36 37# Files 38TOKEN = CONFIG + "/BOT_TOKEN.txt" 39DATABASE_TOKEN = CONFIG + "/DATABASE_TOKEN.txt" 40GOLDY_CONFIG_JSON = CONFIG + "/goldy.json" 41DATA_JSON = "./data.json" 42 43# Templates 44GOLDY_CONFIG_JSON_TEMPLATE = f"{TEMPLATES}/goldy_config.json"
MODULE_NAME = 'PATHS'
This module contains all the variables with paths to Goldy Bot folders and files.
GOLDY_BOT = 'D:/all_my_projects/Python/.goldy_bot/Goldy-Bot-V4/src/GoldyBot'
Path to Goldy Bot module.