示例#1
0
def removeSVGFile(svgFilePath):
    'Remove svg file.'
    if archive.getEndsWithList(svgFilePath, [
            '_bottom.svg', '_carve.svg', '_chop.svg', '_cleave.svg',
            '_scale.svg', '_vectorwrite.svg'
    ]):
        os.remove(svgFilePath)
        print('removeGeneratedFiles deleted ' + svgFilePath)
示例#2
0
文件: prepare.py 项目: folksjos/RepG
def removeGeneratedFiles():
	'Remove generated files.'
	gcodeFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(['gcode'])
	for gcodeFilePath in gcodeFilePaths:
		if 'alterations' not in gcodeFilePath:
			os.remove(gcodeFilePath)
			print('removeGeneratedFiles deleted ' + gcodeFilePath)
	svgFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(['svg'])
	for svgFilePath in svgFilePaths:
		if archive.getEndsWithList(svgFilePath, ['_bottom.svg', '_carve.svg', '_chop.svg', '_cleave.svg']):
			os.remove(svgFilePath)
			print('removeGeneratedFiles deleted ' + svgFilePath)
	xmlFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(['xml'])
	for xmlFilePath in xmlFilePaths:
		if archive.getEndsWithList(xmlFilePath, ['_interpret.xml']):
			os.remove(xmlFilePath)
			print('removeGeneratedFiles deleted ' + xmlFilePath)
	archive.removeBackupFilesByTypes(['gcode', 'svg', 'xml'])
示例#3
0
def removeGeneratedFiles():
    "Remove generated files."
    gcodeFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(["gcode"])
    for gcodeFilePath in gcodeFilePaths:
        if "alterations" not in gcodeFilePath:
            os.remove(gcodeFilePath)
            print("removeGeneratedFiles deleted " + gcodeFilePath)
    svgFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(["svg"])
    for svgFilePath in svgFilePaths:
        if archive.getEndsWithList(svgFilePath, ["_bottom.svg", "_carve.svg", "_chop.svg", "_cleave.svg"]):
            os.remove(svgFilePath)
            print("removeGeneratedFiles deleted " + svgFilePath)
    xmlFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(["xml"])
    for xmlFilePath in xmlFilePaths:
        if archive.getEndsWithList(xmlFilePath, ["_interpret.xml"]):
            os.remove(xmlFilePath)
            print("removeGeneratedFiles deleted " + xmlFilePath)
    archive.removeBackupFilesByTypes(["gcode", "svg", "xml"])
示例#4
0
文件: prepare.py 项目: folksjos/RepG
def removeGeneratedFiles():
    'Remove generated files.'
    gcodeFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(
        ['gcode'])
    for gcodeFilePath in gcodeFilePaths:
        if 'alterations' not in gcodeFilePath:
            os.remove(gcodeFilePath)
            print('removeGeneratedFiles deleted ' + gcodeFilePath)
    svgFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(
        ['svg'])
    for svgFilePath in svgFilePaths:
        if archive.getEndsWithList(
                svgFilePath,
            ['_bottom.svg', '_carve.svg', '_chop.svg', '_cleave.svg']):
            os.remove(svgFilePath)
            print('removeGeneratedFiles deleted ' + svgFilePath)
    xmlFilePaths = archive.getFilesWithFileTypesWithoutWordsRecursively(
        ['xml'])
    for xmlFilePath in xmlFilePaths:
        if archive.getEndsWithList(xmlFilePath, ['_interpret.xml']):
            os.remove(xmlFilePath)
            print('removeGeneratedFiles deleted ' + xmlFilePath)
    archive.removeBackupFilesByTypes(['gcode', 'svg', 'xml'])
示例#5
0
def removeXMLFile(xmlFilePath):
    'Remove xml file.'
    if archive.getEndsWithList(xmlFilePath, ['_interpret.xml']):
        os.remove(xmlFilePath)
        print('removeGeneratedFiles deleted ' + xmlFilePath)
示例#6
0
文件: prepare.py 项目: 3DNogi/SFACT
def removeXMLFile(xmlFilePath):
	'Remove xml file.'
	if archive.getEndsWithList(xmlFilePath, ['_interpret.xml']):
		os.remove(xmlFilePath)
		print('removeGeneratedFiles deleted ' + xmlFilePath)
示例#7
0
文件: prepare.py 项目: 3DNogi/SFACT
def removeSVGFile(svgFilePath):
	'Remove svg file.'
	if archive.getEndsWithList(svgFilePath, ['_bottom.svg', '_carve.svg', '_chop.svg', '_cleave.svg', '_scale.svg', '_vectorwrite.svg']):
		os.remove(svgFilePath)
		print('removeGeneratedFiles deleted ' + svgFilePath)