added rough opus.temp.remove
This commit is contained in:
parent
dbbd2fbf15
commit
5a669ae0cf
@ -18,4 +18,15 @@ def _mainExecPy(_scriptPath):
|
|||||||
|
|
||||||
opus.main.output("done.",2)
|
opus.main.output("done.",2)
|
||||||
return _return
|
return _return
|
||||||
opus.script.execute = _mainExecPy
|
opus.script.execute = _mainExecPy
|
||||||
|
|
||||||
|
opus.temp = Munch()
|
||||||
|
def _tempRemove():
|
||||||
|
if os.path.isdir(opus.path.temp):
|
||||||
|
opus.main.output("clearing temp directory...",1)
|
||||||
|
try:
|
||||||
|
opus.reg.unmount()
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
rtn = subprocess.call(["rmdir","/s","/q",opus.path.temp],shell=True)
|
||||||
|
opus.temp.remove = _tempRemove
|
@ -57,13 +57,7 @@ opus.script.execute(pJoin(opus.path.main,"scripts","path.py"))
|
|||||||
|
|
||||||
opus.main.output("",1)
|
opus.main.output("",1)
|
||||||
|
|
||||||
if os.path.isdir(opus.path.temp):
|
opus.temp.remove()
|
||||||
opus.main.output("clearing temp directory...",1)
|
|
||||||
try:
|
|
||||||
opus.reg.unmount()
|
|
||||||
except:
|
|
||||||
pass
|
|
||||||
shutil.rmtree(opus.path.temp)
|
|
||||||
|
|
||||||
os.makedirs(pJoin(opus.path.temp,"wim"))
|
os.makedirs(pJoin(opus.path.temp,"wim"))
|
||||||
opus.wim.location = pJoin(opus.path.target,"sources","install.wim")
|
opus.wim.location = pJoin(opus.path.target,"sources","install.wim")
|
||||||
@ -90,4 +84,5 @@ for tag in opus.os.tags:
|
|||||||
|
|
||||||
opus.main.output("\nif you'd like to make manual changes, please do so now. press enter to finalize or ctrl+c to cancel.")
|
opus.main.output("\nif you'd like to make manual changes, please do so now. press enter to finalize or ctrl+c to cancel.")
|
||||||
input()
|
input()
|
||||||
opus.wim.update()
|
opus.wim.update()
|
||||||
|
opus.temp.remove()
|
Loading…
Reference in New Issue
Block a user