mirror of
https://github.com/arkenfox/user.js.git
synced 2025-02-23 02:43:56 +00:00
make updater.sh check explicitly for Y/y instead of N/n (#1511)
thanks @infinitewarp
This commit is contained in:
parent
a5e75c4bd3
commit
4b4248157a
@ -2,9 +2,9 @@
|
|||||||
|
|
||||||
## arkenfox user.js updater for macOS and Linux
|
## arkenfox user.js updater for macOS and Linux
|
||||||
|
|
||||||
## version: 3.4
|
## version: 3.5
|
||||||
## Author: Pat Johnson (@overdodactyl)
|
## Author: Pat Johnson (@overdodactyl)
|
||||||
## Additional contributors: @earthlng, @ema-pe, @claustromaniac
|
## Additional contributors: @earthlng, @ema-pe, @claustromaniac, @infinitewarp
|
||||||
|
|
||||||
## DON'T GO HIGHER THAN VERSION x.9 !! ( because of ASCII comparison in update_updater() )
|
## DON'T GO HIGHER THAN VERSION x.9 !! ( because of ASCII comparison in update_updater() )
|
||||||
|
|
||||||
@ -195,7 +195,7 @@ update_updater() {
|
|||||||
echo -e "There is a newer version of updater.sh available. ${RED}Update and execute Y/N?${NC}"
|
echo -e "There is a newer version of updater.sh available. ${RED}Update and execute Y/N?${NC}"
|
||||||
read -p "" -n 1 -r
|
read -p "" -n 1 -r
|
||||||
echo -e "\n\n"
|
echo -e "\n\n"
|
||||||
[[ $REPLY =~ ^[Nn]$ ]] && return 0 # Update available, but user chooses not to update
|
! [[ $REPLY =~ ^[Yy]$ ]] && return 0 # Update available, but user chooses not to update
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
return 0 # No update available
|
return 0 # No update available
|
||||||
@ -253,7 +253,7 @@ update_userjs() {
|
|||||||
echo -e "This script will update to the latest user.js file and append any custom configurations from user-overrides.js. ${RED}Continue Y/N? ${NC}"
|
echo -e "This script will update to the latest user.js file and append any custom configurations from user-overrides.js. ${RED}Continue Y/N? ${NC}"
|
||||||
read -p "" -n 1 -r
|
read -p "" -n 1 -r
|
||||||
echo -e "\n"
|
echo -e "\n"
|
||||||
if [[ $REPLY =~ ^[Nn]$ ]]; then
|
if ! [[ $REPLY =~ ^[Yy]$ ]]; then
|
||||||
echo -e "${RED}Process aborted${NC}"
|
echo -e "${RED}Process aborted${NC}"
|
||||||
rm "$newfile"
|
rm "$newfile"
|
||||||
return 1
|
return 1
|
||||||
|
Loading…
x
Reference in New Issue
Block a user