Did I find the right examples for you? yes no

All Samples(2)  |  Call(2)  |  Derive(0)  |  Import(0)
Make a directory if it doesn't already exist.

        def make_dir(dirname):
    """
    Make a directory if it doesn't already exist.
    """
    try:
        os.makedirs(dirname)
    except OSError as exc:
        if exc.errno == errno.EEXIST:
            pass
        else:
            raise Exception("Unable to create directory: " + dirname)
        


src/g/a/gala-0.1.1/gala/pixel.py   gala(Download)
    """
    if options.temp_dir is not None:
        util.make_dir(options.temp_dir)
 
 

src/g/a/gala-HEAD/gala/pixel.py   gala(Download)
    """
    if options.temp_dir is not None:
        util.make_dir(options.temp_dir)