Move python scripts outside of game dir

This commit is contained in:
OleSTEEP 2024-01-15 18:17:04 +03:00
parent 6b717a39f7
commit 8ea7a858d0
2 changed files with 2 additions and 2 deletions

View file

@ -5,7 +5,7 @@ import os
import time import time
SKIPLIST = ('_DIRECTORY.json',) SKIPLIST = ('_DIRECTORY.json',)
DIRECTORIES_SUPPLIED = ['img', 'audio', 'maps', 'data'] DIRECTORIES_SUPPLIED = ['www/img', 'www/audio', 'www/maps', 'www/data']
def legal_file_name(fname: str) -> bool: def legal_file_name(fname: str) -> bool:

View file

@ -7,7 +7,7 @@ def replace_special_symbols(s: str) -> str:
return s.replace('!', '_PIDOR_').replace('[', '_SUPER_').replace(']', '_PEDIK_').replace('$', '_SEMENCUM_').replace('%', '_RAZRABI_PIDORASI').replace('(', '_SOSI_').replace(')', '_BEBRA_') return s.replace('!', '_PIDOR_').replace('[', '_SUPER_').replace(']', '_PEDIK_').replace('$', '_SEMENCUM_').replace('%', '_RAZRABI_PIDORASI').replace('(', '_SOSI_').replace(')', '_BEBRA_')
DIRECTORY = Path('img') DIRECTORY = Path('www/img')
def cast_symbols(dir_: Path, indent: int = 0) -> int: def cast_symbols(dir_: Path, indent: int = 0) -> int:
renamed = 0 renamed = 0
for file_name in os.listdir(dir_): for file_name in os.listdir(dir_):