mirror of
https://github.com/DictXiong/dotfiles.git
synced 2025-07-30 02:50:29 +08:00
bug fix
This commit is contained in:
parent
b6d9c805fe
commit
6208adec3f
@ -20,7 +20,8 @@ def get_uuid_raw() -> str:
|
||||
if os.path.exists(i):
|
||||
with open(i, "r") as f:
|
||||
return f.read().strip()
|
||||
os.mkdir(os.path.dirname(possible_uuid_files[-1]))
|
||||
if not os.path.exists(os.path.dirname(possible_uuid_files[-1])):
|
||||
os.mkdir(os.path.dirname(possible_uuid_files[-1]))
|
||||
with open(possible_uuid_files[-1], 'w') as f:
|
||||
ans = str(uuid.uuid4())
|
||||
f.write(ans)
|
||||
|
Loading…
x
Reference in New Issue
Block a user