def buildDirPath(currentIndex):
    dirPath = ''
    if currentIndex == 1:
        dirPath = amu.getProductionDir() + '/previs/'
    else:
        dirPath = amu.getProductionDir() + '/shots/'

    return dirPath
示例#2
0
def buildDirPath(currentIndex):
    dirPath = ''
    if currentIndex == 1:
        dirPath = amu.getProductionDir() + '/previs/' 
    else:
        dirPath = amu.getProductionDir() + '/shots/'

    return dirPath
def removeFolder(currentlySelected, context):

    # First build path.
    if context == 1:
        dirPath = str(amu.getProductionDir() + '/previs/' + currentlySelected)
    else:
        dirPath = str(amu.getProductionDir() + '/shots/' + currentlySelected)

    if not canRemove(dirPath):
        raise Exception("Cannot remove directory: " + str(dirPath))
    shutil.rmtree(dirPath)
示例#4
0
def removeFolder(currentlySelected, context):

    # First build path.
    if context == 1:
        dirPath = str(amu.getProductionDir() + '/previs/' + currentlySelected)
    else:
        dirPath = str(amu.getProductionDir() + '/shots/' + currentlySelected)

    if not canRemove(dirPath):
        raise Exception ("Cannot remove directory: " + str(dirPath))
    shutil.rmtree(dirPath)