Add existing scripts

This commit is contained in:
chris committed 2026-09-29 15:24:09 -04:00
1 parent 2ab5a42c2b
commit 3c05d74104
31 files changed
+1138

No files matched your search

+15
View File
@@ -0,0 +1,15 @@
#!/usr/bin/env bash
# Restore the real history file after running book examples
# Check for a backup file
if [ -f ~/.bash_history.backup ]; then
# Rename the backukp file as the current file
mv ~/.bash_history.backup ~/.bash_history
# Clear the example history
history -c
# Reload the history from the restored file
history -r
echo -e "\e[1;36mThe original history has been restored\e[0m"
else
echo -e "\e[1;33mThere is no backup history to restore\e[0m"
fi