config: Just ignore if we can't create the directory
This commit is contained in:
+6
-1
@@ -90,8 +90,13 @@ class Config(object):
|
|||||||
|
|
||||||
def subdir(self, path):
|
def subdir(self, path):
|
||||||
subdir = pisi.util.join_path(self.dest_dir(), path)
|
subdir = pisi.util.join_path(self.dest_dir(), path)
|
||||||
if os.access(os.path.dirname(subdir), os.W_OK):
|
|
||||||
|
# If the directory does not exist, try to create it.
|
||||||
|
try:
|
||||||
pisi.util.ensure_dirs(subdir)
|
pisi.util.ensure_dirs(subdir)
|
||||||
|
except OSError:
|
||||||
|
pass
|
||||||
|
|
||||||
return subdir
|
return subdir
|
||||||
|
|
||||||
def log_dir(self):
|
def log_dir(self):
|
||||||
|
|||||||
Reference in New Issue
Block a user