Skip to content

Commit

Permalink
bugfix - tried to fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
OcelotWalrus authored Jan 7, 2024
1 parent 478ea39 commit f5c32fd
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions source/logger_sys.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,15 @@ def log_message(message):
program_dir = str(appdirs.user_config_dir(appname='Bane-Of-Wargs'))

# Create log file
os.mkdir(f'{program_dir}')
os.mkdir(f'{program_dir}/game')
os.mkdir(f'{program_dir}/game/data')
os.mkdir(f'{program_dir}/game/schemas')
os.mkdir(f'{program_dir}/game/imgs')
os.mkdir(f'{program_dir}/logs')
os.mkdir(f'{program_dir}/plugins')
os.mkdir(f'{program_dir}/saves')
if not os.path.exists(f'{program_dir}'):
os.mkdir(f'{program_dir}')
os.mkdir(f'{program_dir}/game')
os.mkdir(f'{program_dir}/game/data')
os.mkdir(f'{program_dir}/game/schemas')
os.mkdir(f'{program_dir}/game/imgs')
os.mkdir(f'{program_dir}/logs')
os.mkdir(f'{program_dir}/plugins')
os.mkdir(f'{program_dir}/saves')
with open(f'{program_dir}/logs/{date.today()}.log', 'w') as f:
f.write("LOG")

Expand Down

0 comments on commit f5c32fd

Please sign in to comment.