This commit is contained in:
Stephan Raabe
2023-11-12 14:16:53 +01:00
parent 339d7b8411
commit 86dff9bf64
4 changed files with 34 additions and 9 deletions
+20 -3
View File
@@ -1,11 +1,28 @@
# ------------------------------------------------------
# Install .bashrc
# ------------------------------------------------------
cat <<"EOF"
_ _
| |__ __ _ ___| |__ _ __ ___
| '_ \ / _` / __| '_ \| '__/ __|
_| |_) | (_| \__ \ | | | | | (__
(_)_.__/ \__,_|___/_| |_|_| \___|
EOF
echo "-> Install .bashrc"
echo "PLEASE BACKUP YOUR .bashrc file in case you want to keep your local configuration and aliases."
while true; do
read -p "Do you want to install the .bashrc file? (Yy/Nn): " yn
if [ -f ~/.bashrc ]; then
echo "The script has detected an existing .bashrc file. "
fi
if [ -f ~/dotfiles-versions/backups/$datets/.bashrc-old ]; then
echo "Backup is available here ~/dotfiles-versions/backups/$datets/.bashrc-old"
fi
if [ -f ~/.bashrc ]; then
echo "Do you want to replace your existing .bashrc file with the dotfiles .bashrc file?"
else
echo "Do you want to install the dotfiles .bashrc file now?"
fi
read -p "Please confirm (Yy/Nn): " yn
case $yn in
[Yy]* )
_installSymLink .bashrc ~/.bashrc ~/dotfiles/.bashrc ~/.bashrc