]> arthur.barton.de Git - ax-zsh.git/commitdiff
axzshctl: Only rebuild cache when action succeeded
authorAlexander Barton <alex@barton.de>
Mon, 23 Apr 2018 21:40:07 +0000 (23:40 +0200)
committerAlexander Barton <alex@barton.de>
Mon, 23 Apr 2018 21:40:07 +0000 (23:40 +0200)
bin/axzshctl

index a75ebb3db750e0d483c1de6047bd4fd07d6ba3e4..62121d8b0e0a5b3a160cfb7b1bd35719e1aa92ba 100755 (executable)
@@ -377,8 +377,7 @@ case "$cmd" in
                ;;
        "enable-default-plugins")
                [[ $# -eq 0 ]] || Usage
-               EnableDefaultPlugins
-               UpdatePluginCache
+               EnableDefaultPlugins && UpdatePluginCache
                ;;
        "check-plugins")
                [[ $# -eq 0 ]] || Usage
@@ -386,8 +385,7 @@ case "$cmd" in
                ;;
        "set-theme")
                [[ $# -eq 1 ]] || Usage
-               SetTheme "$1"
-               UpdatePluginCache
+               SetTheme "$1" && UpdatePluginCache
                ;;
        "upgrade")
                [[ $# -eq 0 ]] || Usage