From b3ef9ea209dfdc59680c2296912a8c28f7c2a47a Mon Sep 17 00:00:00 2001 From: Puneeth Chaganti Date: Wed, 16 Feb 2022 20:55:08 +0530 Subject: [PATCH] lib/helpers: Don't rm "$profile_path" before writing to it When the file is being re-created, we write to it, instead of appending to it. So, the rm here is unnecessary and prevents users from linking the profile file to another location that is potentially under version control. For instance, once could link to a profile file located at "$BASH_IT_CUSTOM/profiles/*.bash_it". --- lib/helpers.bash | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/helpers.bash b/lib/helpers.bash index 4728541a..abcbc675 100644 --- a/lib/helpers.bash +++ b/lib/helpers.bash @@ -511,7 +511,6 @@ function _bash-it-profile-save() { case "$RESP" in [yY]) echo -e "${echo_green?}Overwriting profile '$name'...${echo_reset_color?}" - rm "$profile_path" break ;; [nN] | "")