1
0
Fork 0
forked from RP1/RaveOS-arch

started to make the code nicer

This commit is contained in:
RP1 2025-02-06 17:21:53 +01:00
parent 7bc26647df
commit da6118a697

View file

@ -28,16 +28,15 @@ if [[ $? -eq 1 ]]; then
exit 1 exit 1
fi fi
sudo echo sudo echo
# locale | grep LANG
# $XDG_CURRENT_DESKTOP
if [[ $user_choice = *"BACKUP All of My Data and Settings"* ]]; then if [[ $user_choice = *"BACKUP All of My Data and Settings"* ]]; then
cd cd
Locale=$(locale | grep "LANG" -c)
Desktop=$XDG_CURRENT_DESKTOP
echo echo
echo ----------------------------------------------------- echo -----------------------------------------------------
echo Copying ${bold}${yellow}$USER Settings and Files${normal} into ${bold}${yellow}$FOLDER/${normal} echo Copying ${bold}${yellow}$USER Settings and Files${normal} into ${bold}${yellow}$FOLDER/${normal}
if [[ "$desktop" == GNOME ]]; then
# GNOME SECTION # GNOME SECTION
dconf dump / > $FOLDER/$USER-ui dconf dump / > $FOLDER/$USER-ui
# HU lang # HU lang
@ -57,8 +56,8 @@ if [[ $user_choice = *"BACKUP All of My Data and Settings"* ]]; then
rsync -ap --info=progress2 /home/$USER/Games/ $FOLDER 2>/dev/null rsync -ap --info=progress2 /home/$USER/Games/ $FOLDER 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.librewolf $FOLDER 2>/dev/null rsync -ap --info=progress2 /home/$USER/.librewolf $FOLDER 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.steam $FOLDER 2>/dev/null rsync -ap --info=progress2 /home/$USER/.steam $FOLDER 2>/dev/null
mkdir -p $FOLDER/.config #mkdir -p $FOLDER/.config
rsync -ap --info=progress2 /home/$USER/.config/Bitwarden $FOLDER/.config 2>/dev/null rsync -ap --info=progress2 --relative /home/$USER/.config/Bitwarden $FOLDER/.config 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.config/heroic $FOLDER/.config 2>/dev/null rsync -ap --info=progress2 /home/$USER/.config/heroic $FOLDER/.config 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.config/input-remapper-2 $FOLDER/.config 2>/dev/null rsync -ap --info=progress2 /home/$USER/.config/input-remapper-2 $FOLDER/.config 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.config/Mumble $FOLDER/.config 2>/dev/null rsync -ap --info=progress2 /home/$USER/.config/Mumble $FOLDER/.config 2>/dev/null
@ -90,8 +89,8 @@ if [[ $user_choice = *"BACKUP All of My Data and Settings"* ]]; then
rsync -ap --info=progress2 /home/$USER/.config/kdeconnect $FOLDER/.config 2>/dev/null rsync -ap --info=progress2 /home/$USER/.config/kdeconnect $FOLDER/.config 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.config/Helvum $FOLDER/.config 2>/dev/null rsync -ap --info=progress2 /home/$USER/.config/Helvum $FOLDER/.config 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.config/calibre $FOLDER/.config 2>/dev/null rsync -ap --info=progress2 /home/$USER/.config/calibre $FOLDER/.config 2>/dev/null
mkdir -p $FOLDER/.local/share/ #mkdir -p $FOLDER/.local/share/
rsync -ap --info=progress2 /home/$USER/.local/share/gnome-shell $FOLDER/.local/share/ 2>/dev/null rsync -ap --info=progress2 --relative /home/$USER/.local/share/gnome-shell $FOLDER/.local/share/ 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.local/share/flatpak/overrides/ $FOLDER/.local/share/flatpak/ 2>/dev/null rsync -ap --info=progress2 /home/$USER/.local/share/flatpak/overrides/ $FOLDER/.local/share/flatpak/ 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.local/share/lutris $FOLDER/.local/share/ 2>/dev/null rsync -ap --info=progress2 /home/$USER/.local/share/lutris $FOLDER/.local/share/ 2>/dev/null
rsync -ap --info=progress2 /home/$USER/.local/share/TelegramDesktop $FOLDER/.local/share/ 2>/dev/null rsync -ap --info=progress2 /home/$USER/.local/share/TelegramDesktop $FOLDER/.local/share/ 2>/dev/null
@ -113,6 +112,8 @@ if [[ $user_choice = *"BACKUP All of My Data and Settings"* ]]; then
fi fi
if [[ $user_choice = *"Restore all of my data and settings"* ]]; then if [[ $user_choice = *"Restore all of my data and settings"* ]]; then
Locale=$(locale | grep "LANG" -c)
Desktop=$XDG_CURRENT_DESKTOP
echo echo
echo ----------------------------------------------------- echo -----------------------------------------------------
echo Copying ${bold}${yellow}Restoring $USER Settings and Files ${normal} into ${bold}${yellow}$FOLDER/${normal} echo Copying ${bold}${yellow}Restoring $USER Settings and Files ${normal} into ${bold}${yellow}$FOLDER/${normal}