summaryrefslogtreecommitdiff
path: root/share/rcm.sh.in
diff options
context:
space:
mode:
Diffstat (limited to 'share/rcm.sh.in')
-rw-r--r--share/rcm.sh.in16
1 files changed, 9 insertions, 7 deletions
diff --git a/share/rcm.sh.in b/share/rcm.sh.in
index 36b6762..e01ec59 100644
--- a/share/rcm.sh.in
+++ b/share/rcm.sh.in
@@ -106,11 +106,13 @@ run_hooks() {
local when=$1
local direction=$2
- for dotfiles_dir in $DOTFILES_DIRS; do
- $DEBUG "hook: $dotfiles_dir/hooks/$when-$direction"
- if [ -x "$dotfiles_dir/hooks/$when-$direction" ]; then
- $VERBOSE "running $when-$direction hooks for $dotfiles_dir"
- $dotfiles_dir/hooks/$when-$direction
- fi
- done
+ if [ $RUN_HOOKS -eq 1 ]; then
+ for dotfiles_dir in $DOTFILES_DIRS; do
+ $DEBUG "hook: $dotfiles_dir/hooks/$when-$direction"
+ if [ -x "$dotfiles_dir/hooks/$when-$direction" ]; then
+ $VERBOSE "running $when-$direction hooks for $dotfiles_dir"
+ $dotfiles_dir/hooks/$when-$direction
+ fi
+ done
+ fi
}