Browse Source

Add backup to setup.sh

battaglia01 7 years ago
parent
commit
1a0c61c2ef
1 changed files with 3 additions and 3 deletions
  1. 3 3
      setup.sh

+ 3 - 3
setup.sh

@@ -32,7 +32,7 @@ read -rp "Press enter if this is correct, or CTRL-C to cancel." cont;echo
 echo "\nContinuing setup...\n"
 echo "\nContinuing setup...\n"
 
 
 echo "Coping the config files under root to where they belong...\n"
 echo "Coping the config files under root to where they belong...\n"
-cp -R root/* /
+cp -Rb root/* /
 
 
 echo "Making /lib/systemd/system-sleep/sleep executable...\n"
 echo "Making /lib/systemd/system-sleep/sleep executable...\n"
 chmod a+x /lib/systemd/system-sleep/sleep
 chmod a+x /lib/systemd/system-sleep/sleep
@@ -42,10 +42,10 @@ read -rp "Do you want to replace suspend with hibernate? (type yes or no) " useh
 if [ "$usehibernate" = "yes" ]; then
 if [ "$usehibernate" = "yes" ]; then
 	if [ "$LX_BASE" = "ubuntu" ] && [ 1 -eq "$(echo "${LX_VERSION} >= 17.10" | bc)" ]; then
 	if [ "$LX_BASE" = "ubuntu" ] && [ 1 -eq "$(echo "${LX_VERSION} >= 17.10" | bc)" ]; then
 		echo "Using Hibernate instead of Suspend...\n"
 		echo "Using Hibernate instead of Suspend...\n"
-		ln -sf /lib/systemd/system/hibernate.target /etc/systemd/system/suspend.target && sudo ln -sf /lib/systemd/system/systemd-hibernate.service /etc/systemd/system/systemd-suspend.service
+		ln -sfb /lib/systemd/system/hibernate.target /etc/systemd/system/suspend.target && sudo ln -sfb /lib/systemd/system/systemd-hibernate.service /etc/systemd/system/systemd-suspend.service
 	else
 	else
 		echo "Using Hibernate instead of Suspend...\n"
 		echo "Using Hibernate instead of Suspend...\n"
-		ln -sf /usr/lib/systemd/system/hibernate.target /etc/systemd/system/suspend.target && sudo ln -sf /usr/lib/systemd/system/systemd-hibernate.service /etc/systemd/system/systemd-suspend.service
+		ln -sfb /usr/lib/systemd/system/hibernate.target /etc/systemd/system/suspend.target && sudo ln -sfb /usr/lib/systemd/system/systemd-hibernate.service /etc/systemd/system/systemd-suspend.service
 	fi
 	fi
 else
 else
 	echo "Not touching Suspend\n"
 	echo "Not touching Suspend\n"