mirror of
https://github.com/jorgebucaran/fisher
synced 2024-09-10 15:07:40 +02:00
Do not return 1 if fisher
succeeds.
Other * Better logic when leaving early in case of a fail install. * Colorize task completion duration.
This commit is contained in:
parent
15cb59d25f
commit
028beda098
1 changed files with 7 additions and 5 deletions
12
fisher.fish
12
fisher.fish
|
@ -168,12 +168,12 @@ function fisher
|
||||||
|
|
||||||
switch "$cmd"
|
switch "$cmd"
|
||||||
case install
|
case install
|
||||||
if __fisher_install $items
|
if not __fisher_install $items
|
||||||
__fisher_log okay "Done in "(__fisher_get_epoch_in_ms $elapsed | __fisher_humanize_duration) $__fisher_stderr
|
|
||||||
else
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
__fisher_log okay "Done in @"(__fisher_get_epoch_in_ms $elapsed | __fisher_humanize_duration)"@" $__fisher_stderr
|
||||||
|
|
||||||
case update
|
case update
|
||||||
if isatty
|
if isatty
|
||||||
if test -z "$items"
|
if test -z "$items"
|
||||||
|
@ -188,7 +188,7 @@ function fisher
|
||||||
|
|
||||||
__fisher_update $items
|
__fisher_update $items
|
||||||
|
|
||||||
__fisher_log okay "Done in "(__fisher_get_epoch_in_ms $elapsed | __fisher_humanize_duration) $__fisher_stderr
|
__fisher_log okay "Done in @"(__fisher_get_epoch_in_ms $elapsed | __fisher_humanize_duration)"@" $__fisher_stderr
|
||||||
|
|
||||||
case ls
|
case ls
|
||||||
if test "$argv" -ge 0 -o "$argv" = -
|
if test "$argv" -ge 0 -o "$argv" = -
|
||||||
|
@ -224,7 +224,7 @@ function fisher
|
||||||
__fisher_show_spinner
|
__fisher_show_spinner
|
||||||
end
|
end
|
||||||
|
|
||||||
__fisher_log okay "Done in "(__fisher_get_epoch_in_ms $elapsed | __fisher_humanize_duration) $__fisher_stderr
|
__fisher_log okay "Done in @"(__fisher_get_epoch_in_ms $elapsed | __fisher_humanize_duration)"@" $__fisher_stderr
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -273,6 +273,8 @@ function fisher
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
return 0
|
||||||
end
|
end
|
||||||
|
|
||||||
function __fisher_install
|
function __fisher_install
|
||||||
|
|
Loading…
Reference in a new issue