Add kitty, rofi, zsh, hyprland, clang_format to configs

This commit is contained in:
Thraix
2026-05-19 22:47:43 +02:00
parent aecdb34116
commit 8e28f60c91
14 changed files with 1372 additions and 5 deletions
+25 -3
View File
@@ -1,11 +1,16 @@
parameter=$1
keep_backup=1
install() {
if [[ $parameter == "all" ]] || [[ $parameter == $1 ]]; then
echo "Installing $1 config in $2"
rm -rf $2_backup/
mv $2/ $2_backup/
cp -r $1 $2/
if [[ $keep_backup -eq 1 ]]; then
rm -rf $2_backup
mv $2 $2_backup
else
rm -rf $2
fi
cp -rf $1 $2
fi
}
@@ -18,6 +23,23 @@ if [[ $parameter == '' ]]; then
exit
fi
read -p "Do you want to back up your old config files? (y/n) " yn
case $yn in
[Nn]*)
keep_backup=0
break
;;
[Yy]*)
keep_backup=1
break
;;
*)
echo "Unknown answer, treating it as yes"
keep_backup=1
break
;;
esac
while read name path; do
eval "name=$name" # re-evaluate the string as a path
eval "path=$path" # re-evaluate the string as a path