From 8025cdd789bde686d66542a316ad9b0d151e6c6c Mon Sep 17 00:00:00 2001 From: Michael Weinberger Date: Wed, 2 May 2018 16:11:33 +0200 Subject: [PATCH] switched to the _create_dirs function --- dotdrop/installer.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/dotdrop/installer.py b/dotdrop/installer.py index 747d45a..386e102 100644 --- a/dotdrop/installer.py +++ b/dotdrop/installer.py @@ -59,9 +59,10 @@ class Installer: if self.dry: self.log.dry('would link %s to %s' % (dst, src)) return [] - dstDir = os.path.dirname(dst) - if not os.path.exists(dstDir): - os.makedirs(dstDir) + base = os.path.dirname(dst) + if not self._create_dirs(base): + self.log.err('creating directory for \"%s\"' % (dst)) + return [] os.symlink(src, dst) self.log.sub('linked %s to %s' % (dst, src)) # Follows original developer's behavior