version hooks

This commit is contained in:
Paolo Denti 2024-01-27 08:33:00 -08:00
parent 70857a4a95
commit 793b9f8a23
3 changed files with 6 additions and 6 deletions

View File

@ -1,13 +1,13 @@
# ------------------------------------------------------
# Copy dotfiles
# ------------------------------------------------------
if [ -f ~/dotfiles-versions/post-version-hook.sh ]; then
if [ -f ~/dotfiles-versions/$version/post-version-hook.sh ]; then
echo -e "${GREEN}"
figlet "Post Version Hook"
echo -e "${NONE}"
echo ":: The script has detected a post-version-hook.sh script."
if gum confirm "Do you want to run the script now?"; then
source ~/dotfiles-versions/post-version-hook.sh
source ~/dotfiles-versions/$version/post-version-hook.sh
echo ":: post-version-hook.sh executed!"
else
echo ":: Execution of post-version-hook.sh skipped."

View File

@ -1,13 +1,13 @@
# ------------------------------------------------------
# Copy dotfiles
# ------------------------------------------------------
if [ -f ~/dotfiles-versions/pre-version-hook.sh ]; then
if [ -f ~/dotfiles-versions/$version/pre-version-hook.sh ]; then
echo -e "${GREEN}"
figlet "Pre Version Hook"
echo -e "${NONE}"
echo ":: The script has detected a pre-version-hook.sh script."
if gum confirm "Do you want to run the script now?"; then
source ~/dotfiles-versions/pre-version-hook.sh
source ~/dotfiles-versions/$version/pre-version-hook.sh
echo ":: pre-version-hook.sh executed!"
else
echo ":: Execution of pre-version-hook.sh skipped."

View File

@ -1,13 +1,13 @@
# ------------------------------------------------------
# Copy dotfiles
# ------------------------------------------------------
if [ -f ~/dotfiles-versions/version-hook.sh ]; then
if [ -f ~/dotfiles-versions/$version/version-hook.sh ]; then
echo -e "${GREEN}"
figlet "Version Hook"
echo -e "${NONE}"
echo ":: The script has detected a version-hook.sh script."
if gum confirm "Do you want to run the script now?"; then
source ~/dotfiles-versions/version-hook.sh
source ~/dotfiles-versions/$version/version-hook.sh
echo ":: version-hook.sh executed!"
else
echo ":: Execution of version-hook.sh skipped."