summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Stoelp <johannes.stoelp@gmail.com>2022-06-12 14:14:40 +0200
committerJohannes Stoelp <johannes.stoelp@gmail.com>2022-06-12 14:14:40 +0200
commite3350af5b8d7fdfba49f7ec692cd8a95aeb3f9a9 (patch)
tree6c71733971541e57b3733d3114ff2492caf16486
parentd2824f7ea91a0297a4ed2b35af4e38bdc0d04faa (diff)
downloaddotfiles-e3350af5b8d7fdfba49f7ec692cd8a95aeb3f9a9.tar.gz
dotfiles-e3350af5b8d7fdfba49f7ec692cd8a95aeb3f9a9.zip
[zshrc]: add helper to update zsh plugins
-rw-r--r--zshrc9
1 files changed, 9 insertions, 0 deletions
diff --git a/zshrc b/zshrc
index c5eca53..991b5cd 100644
--- a/zshrc
+++ b/zshrc
@@ -11,6 +11,15 @@ ZDOTDIR=$HOME/.cache/zsh
function zshPlug() {
local install=$HOME/.zshplug
+ if [[ $1 == "update" ]]; then
+ for dir in $install/**/.git; do
+ local repo=$(dirname $dir)
+ echo "=> Updating $repo"
+ git -C $repo pull
+ done
+ return
+ fi
+
# Positinal:
# $1: Github repository.
# Arguments: