def subdir(self): subdir = self.store.subdir if subdir != None: subdir = fileutils.str2path(subdir) subdir = fileutils.ensureRelDirPath(subdir) return fileutils.cleanupPath(subdir) subdir = fileutils.str2filename(self.store.name) return fileutils.ensureDirPath(subdir)
def __init__(self, profCtx, targStore): base.BaseStoreContext.__init__(self, profCtx, targStore) self._variables.addVar("targetName", self.name) subdir = self.store.subdir or "" subdir = fileutils.str2path(subdir) subdir = fileutils.ensureRelDirPath(subdir) subdir = fileutils.cleanupPath(subdir) self._variables.addVar("targetSubdir", subdir) targPath = (fileutils.joinPath(self._variables["sourceDir"], subdir) + self._variables["sourceFile"]) self._variables.addFileVars(fileutils.ensureRelPath(targPath), "target", extension=self.extension)