mirror of
https://github.com/relativemodder/aegnux.git
synced 2025-12-10 05:29:38 +05:00
refactoring
This commit is contained in:
@@ -35,11 +35,8 @@ class InstallationThread(ProcessThread):
|
||||
|
||||
def run(self):
|
||||
try:
|
||||
try:
|
||||
shutil.rmtree(get_aegnux_installation_dir(), True)
|
||||
except:
|
||||
self.log_signal.emit(f'[WARNING] Can\'t remove existing installation.')
|
||||
|
||||
self.try_cleanup_installation()
|
||||
|
||||
self.progress_signal.emit(10)
|
||||
|
||||
if self.download_method == DownloadMethod.ONLINE:
|
||||
@@ -129,6 +126,12 @@ class InstallationThread(ProcessThread):
|
||||
self.log_signal.emit(f'[ERROR] {e}')
|
||||
self.finished_signal.emit(False)
|
||||
|
||||
def try_cleanup_installation(self):
|
||||
try:
|
||||
shutil.rmtree(get_aegnux_installation_dir(), True)
|
||||
except:
|
||||
self.log_signal.emit(f'[WARNING] Can\'t remove existing installation.')
|
||||
|
||||
def install_vcr(self):
|
||||
self.log_signal.emit(f'[DEBUG] Unpacking VCR to {get_vcr_dir_path()}...')
|
||||
self.unpack_zip(VCR_ZIP, get_vcr_dir_path().as_posix())
|
||||
|
||||
Reference in New Issue
Block a user