From cbdabe048531bdbfd857619de863010099938bc7 Mon Sep 17 00:00:00 2001 From: Jordi Pakey-Rodriguez Date: Sun, 30 Sep 2018 23:04:15 -0700 Subject: Make sure shell hook doesn't overwrite config Addresses #8 --- hook/rofi.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'hook/rofi.sh') diff --git a/hook/rofi.sh b/hook/rofi.sh index 816aac7..ca739bd 100755 --- a/hook/rofi.sh +++ b/hook/rofi.sh @@ -1,9 +1,10 @@ #!/usr/bin/env bash + rofi_config_file=$HOME/.config/rofi/config rofi_themes_dir=$HOME/sources/base16-rofi/themes - rofi_theme_file=$rofi_themes_dir/base16-$BASE16_THEME.config -if [ -f "$rofi_theme_file" ] && [ -f $rofi_config_file ]; then + +if ![ -f $rofi_config_file ] && [ -f "$rofi_theme_file" ]; then cp "$rofi_theme_file" "$rofi_config_file" echo 'Rofi theme updated' fi -- cgit v1.2.3