From 0a6cfbf398e5e0e0481562928da4c65c6a753757 Mon Sep 17 00:00:00 2001 From: Roee Shapira Date: Sun, 14 May 2023 20:13:36 +0300 Subject: [PATCH 1/4] Made "update all" update all parts, and "update plugins" update only the plugins --- zap.zsh | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/zap.zsh b/zap.zsh index 5ee2f85..77ac3cb 100644 --- a/zap.zsh +++ b/zap.zsh @@ -75,8 +75,17 @@ function _zap_update() { local _plugin _plug _status - [[ $1 = "self" ]] && { _pull $ZAP_DIR; return } - [[ $1 == "all" ]] && { echo "\nUpdating All Plugins\n"; for _plug in ${ZAP_INSTALLED_PLUGINS[@]}; do _pull "$ZAP_PLUGIN_DIR/$_plug"; done; return } + [[ $1 == "all" || $1 == "self" ]] && { + _pull $ZAP_DIR + [[ $1 == "self" ]] && return + } + [[ $1 == "all" || $1 == "plugins" ]] && { + echo "\nUpdating All Plugins\n" + for _plug in ${ZAP_INSTALLED_PLUGINS[@]}; do + _pull "$ZAP_PLUGIN_DIR/$_plug" + done + return + } function _check() { git -C "$1" remote update &> /dev/null From bbdec958b2a5b21bcd427d5b5a3e8548f8866619 Mon Sep 17 00:00:00 2001 From: Roee Shapira Date: Sun, 14 May 2023 20:13:44 +0300 Subject: [PATCH 2/4] Add docs --- zap.zsh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/zap.zsh b/zap.zsh index 77ac3cb..079d3f8 100644 --- a/zap.zsh +++ b/zap.zsh @@ -139,8 +139,9 @@ COMMANDS: version Show version information OPTIONS: - update self Update Zap itself - update all Update all plugins" + update self Update Zap itself + update plugins Update all plugins + update all Update Zap and all plugins" } function _zap_version() { From 24b9817baa35a768c1e839d0234c3c8d4baaa470 Mon Sep 17 00:00:00 2001 From: Roee Shapira Date: Mon, 15 May 2023 08:15:33 +0300 Subject: [PATCH 3/4] Update `README.md` with new updating commands --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index eee5f47..ec6cbcb 100644 --- a/README.md +++ b/README.md @@ -105,7 +105,9 @@ Zap provided commands for updating and cleaning up plugins - To update plugins or Zap: ```zsh - zap update + zap update self # Update the Zap installation + zap update plugins # Update your specified plugins + zap update all # Update both the Zap installation and its plugins ``` - To list all plugins you are using: From 485b689e407b0e1b7f94b7a36dd9e581e94074be Mon Sep 17 00:00:00 2001 From: Marco <82162277+mamaraddio@users.noreply.github.com> Date: Mon, 15 May 2023 13:49:15 +0200 Subject: [PATCH 4/4] Fix explanation detail --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ec6cbcb..f588ae5 100644 --- a/README.md +++ b/README.md @@ -106,7 +106,7 @@ Zap provided commands for updating and cleaning up plugins ```zsh zap update self # Update the Zap installation - zap update plugins # Update your specified plugins + zap update plugins # Update all your plugins but not Zap zap update all # Update both the Zap installation and its plugins ```