Skip to content

Commit e22c0d5

Browse files
authored
Major v1.2 update
Changelog: -Script asks user to download ROMs repo -Script asks user to sync sources -Removed uneccesary 'exit' command
1 parent 6c6af52 commit e22c0d5

File tree

1 file changed

+29
-1
lines changed

1 file changed

+29
-1
lines changed

tools-installation-script.sh

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,4 +57,32 @@ mkdir -p $Var_Dir && cd $Var_Dir # source code location
5757
NAME="rm -r $Var_Dir" && dest=$HOME/tools-uninstallation-script.sh
5858
echo "$NAME" >> "$dest"
5959
printf "${GREEN}$Var_Dir folder was successfully created at $HOME\n${NO_COLOR}"
60-
exit
60+
61+
# repo download and source sync
62+
SYNC=repo sync -c -j$(nproc --all) --force-sync --no-clone-bundle --no-tags &> /dev/null # source sync variable
63+
while true; do
64+
read -r -p "Do you want to download ROMs repo right now? " yn
65+
case "$yn" in
66+
[Yy]* )
67+
printf "Please insert ROMs repo link\n"
68+
read REPO # enter repo link here
69+
$REPO
70+
while true; do
71+
read -r -p "Do you want to sync ROMs source code? " yn
72+
case "$yn" in
73+
[Yy]* )
74+
$SYNC # source sync
75+
printf "Done\n"
76+
exit;;
77+
[Nn]* )
78+
echo "Exiting"
79+
exit;;
80+
esac
81+
done
82+
exit;;
83+
[Nn]* )
84+
echo "Exiting"
85+
exit;;
86+
* ) "Please enter a valid answer (Yy/Nn)";;
87+
esac
88+
done

0 commit comments

Comments
 (0)