From 60a90807a86ef484e43fed3e191d7a560d73b024 Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Sun, 10 Apr 2022 13:28:26 +0300 Subject: [PATCH] Add functionality to disable docker stacks with zsh update function --- docker/.gitignore | 1 + home/.config/zsh/03-aliases.zsh | 10 +++++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/docker/.gitignore b/docker/.gitignore index 934c1fb..b5d7ad6 100644 --- a/docker/.gitignore +++ b/docker/.gitignore @@ -1 +1,2 @@ */.env +*/DISABLED diff --git a/home/.config/zsh/03-aliases.zsh b/home/.config/zsh/03-aliases.zsh index 77da1f9..7483365 100644 --- a/home/.config/zsh/03-aliases.zsh +++ b/home/.config/zsh/03-aliases.zsh @@ -162,9 +162,13 @@ update() { docker-update() { for dir in $HOME/git/dotfiles/docker/*; do cd $dir - dct pull - dct up -d - cd .. + if [[ -f "DISABLED" ]]; then + echo "$dir stack is disabled, skipping..." + else + dct pull + dct up -d + cd .. + fi done }