Onionr/onionr/utils/createdirs.py

13 lines
281 B
Python
Raw Normal View History

2019-07-18 17:40:48 +00:00
from . import identifyhome
import dbcreator, filepaths
home = identifyhome.identify_home()
if not os.path.exists(home):
os.mkdir(home)
os.mkdir(filepaths.block_data_location)
for db in dbcreator.create_funcs:
try:
db()
except FileExistsError:
pass