Améliorations et migration vers bureau GNOME
This commit is contained in:
11
udib.py
11
udib.py
@@ -7,7 +7,7 @@ from tempfile import TemporaryDirectory
|
||||
|
||||
from cli.clibella import Printer
|
||||
from cli.parser import get_argument_parser
|
||||
from core.utils import assert_system_dependencies_installed, download_and_verify_debian_iso, download_and_verify_debian_testing_iso
|
||||
from core.utils import assert_system_dependencies_installed, download_debian_iso_simple, download_debian_testing_iso_simple
|
||||
from iso.injection import inject_files_into_iso
|
||||
from net.download import download_file
|
||||
from net.scrape import get_debian_preseed_file_urls, get_debian_iso_urls, get_debian_testing_iso_urls
|
||||
@@ -30,8 +30,8 @@ def main():
|
||||
path_to_output_file = path_to_output_file.expanduser()
|
||||
path_to_output_file = path_to_output_file.resolve()
|
||||
|
||||
if path_to_output_file.exists():
|
||||
p.error(f"Output file already exists: '{path_to_output_file}'.")
|
||||
if path_to_output_file.exists() and not args.force:
|
||||
p.error(f"Output file already exists: '{path_to_output_file}'. Use --force to overwrite.")
|
||||
exit(1)
|
||||
else:
|
||||
path_to_output_file = None
|
||||
@@ -105,7 +105,7 @@ def main():
|
||||
else:
|
||||
path_to_output_file = Path.cwd() / output_file_name
|
||||
|
||||
download_and_verify_debian_iso(path_to_output_file, printer=p)
|
||||
download_debian_iso_simple(path_to_output_file, printer=p, force=args.force)
|
||||
p.success(f"Debian ISO saved to '{path_to_output_file}'.")
|
||||
exit(0)
|
||||
|
||||
@@ -120,10 +120,11 @@ def main():
|
||||
else:
|
||||
path_to_output_file = Path.cwd() / output_file_name
|
||||
|
||||
download_and_verify_debian_testing_iso(path_to_output_file, printer=p)
|
||||
download_debian_testing_iso_simple(path_to_output_file, printer=p, force=args.force)
|
||||
p.success(f"Debian testing ISO saved to '{path_to_output_file}'.")
|
||||
exit(0)
|
||||
|
||||
|
||||
elif args.subparser_name == "inject":
|
||||
|
||||
# verify image file path if set by user or download fresh iso if unset
|
||||
|
||||
Reference in New Issue
Block a user