summaryrefslogtreecommitdiff
path: root/src/verbs/install.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/verbs/install.py')
-rw-r--r--src/verbs/install.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/verbs/install.py b/src/verbs/install.py
index 3ddd88c..60e1809 100644
--- a/src/verbs/install.py
+++ b/src/verbs/install.py
@@ -321,8 +321,13 @@ def install(args, options, config):
if util.ask_confirmation(colors.BLUE + "Continue?", no_confirm=options["y"]):
for package in to_install:
- install_single(package, options, config, verbose=v, unsafe=unsafe)
- util.fill_line(f"Installed {package}", colors.BG_CYAN + colors.LIGHT_BLACK, end="\n")
+ try:
+ install_single(package, options, config, verbose=v, unsafe=unsafe)
+ util.fill_line(f"Installed {package}", colors.BG_CYAN + colors.LIGHT_BLACK, end="\n")
+ except Exception as e:
+ util.fill_line(f"Failed to install {package}", colors.BG_RED + colors.LIGHT_BLACK, end="\n")
+ util.fill_line(str(e), colors.CLEAR_LINE + colors.RESET + colors.RED, end="\n")
+
else:
print(colors.RED + "Action cancelled by user")