Install Script Testing

This commit is contained in:
Dante 2024-03-13 11:42:02 -05:00 committed by GitHub
parent a523ee2b13
commit a11d325a19
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
21 changed files with 1580 additions and 0 deletions

31
Scripts/restore_lnk.sh Normal file
View file

@ -0,0 +1,31 @@
#!/bin/bash
#|---/ /+---------------------------------+---/ /|#
#|--/ /-| Script to fix slinks in .config |--/ /-|#
#|-/ /--| Prasanth Rangan |-/ /--|#
#|/ /---+---------------------------------+/ /---|#
source global_fn.sh
if [ $? -ne 0 ] ; then
echo "Error: unable to source global_fn.sh, please execute from $(dirname "$(realpath "$0")")..."
exit 1
fi
find $CloneDir -type l | while read slink
do
fixd_slink=$(readlink $slink | cut -d '/' -f 4-)
linkd_file=$(echo $slink | awk -F "${CloneDir}/Configs/" '{print $NF}')
echo "linking $HOME/$linkd_file --> $HOME/$fixd_slink..."
ln -fs $HOME/$fixd_slink $HOME/$linkd_file
done
if [ -f $HOME/.config/hyprdots/scripts/globalcontrol.sh ] ; then
sed -i "/^CloneDir=/c\CloneDir=\"$CloneDir\"" $HOME/.config/hyprdots/scripts/globalcontrol.sh
echo "Clone directory globalcontrol updated..."
fi
if printenv HYPRLAND_INSTANCE_SIGNATURE &> /dev/null
then
echo "reloading hyprland..."
hyprctl reload
fi