rev 1.7.9a2 updated exit_screen function to re-source $HOME/nameofshellrc on exit

This commit is contained in:
Dewalt 2024-02-14 03:45:15 -06:00
parent b6f2c28feb
commit c82b310018
2 changed files with 7 additions and 2 deletions

View File

@ -45,6 +45,9 @@ sudo ./pimpmykali.sh
# Writeups / Honorable Mentions # Writeups / Honorable Mentions
- ip3c4c_n00b https://ip3c4c.com/2202_homelab_vmware/ - ip3c4c_n00b https://ip3c4c.com/2202_homelab_vmware/
# Revision 1.7.9a2 - updated exit_screen function
- function modified to re-source logged in user ~/nameofshellrc
# Revision 1.7.9a1 - netexec # Revision 1.7.9a1 - netexec
- updated installation to use pipx - updated installation to use pipx
- created new function to ensure symlinks are created - created new function to ensure symlinks are created

View File

@ -9,7 +9,7 @@
# Standard Disclaimer: Author assumes no liability for any damage # Standard Disclaimer: Author assumes no liability for any damage
# revision var # revision var
revision="1.7.9a1" revision="1.7.9a2"
# unicorn puke: # unicorn puke:
red=$'\e[1;31m' red=$'\e[1;31m'
@ -2479,6 +2479,9 @@ exit_screen() {
eval apt -y --fix-broken install >/dev/null 2>&1 eval apt -y --fix-broken install >/dev/null 2>&1
echo -e "$asciiart" echo -e "$asciiart"
echo -e "\n\n All Done! Happy Hacking! \n" echo -e "\n\n All Done! Happy Hacking! \n"
findrealuser=$(logname)
getshell=$(echo $SHELL | cut -d "/" -f4)
runuser $findrealuser $getshell -c 'subshell=$(echo $SHELL | cut -d "/" -f4); source $HOME/.$subshell"rc"'
exit exit
} }
@ -2486,4 +2489,3 @@ check_for_root
check_distro check_distro
check_arg "$1" check_arg "$1"
exit_screen exit_screen