python check if dir exists else create

25

from pathlib import Path
Path("/my/directory").mkdir(parents=True, exist_ok=True)
from pathlib import Path
Path("/my/directory").mkdir(parents=True, exist_ok=True)

Comments

Submit
0 Comments