Last active
March 11, 2016 08:35
-
-
Save minstrel271/c85591c5e3280aa24493 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
def ensure_dir(path): | |
d = os.path.dirname(path) | |
if not os.path.exists(d): | |
os.makedirs(d) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment