added password confirmation
This commit is contained in:
parent
8dfcd980a6
commit
f0925ebabc
2 changed files with 16 additions and 2 deletions
|
@ -2,7 +2,14 @@
|
||||||
# Variables
|
# Variables
|
||||||
read -p "Enter your archive server ip address: " server
|
read -p "Enter your archive server ip address: " server
|
||||||
read -p "Enter your user for rsync daemon credentials: " user
|
read -p "Enter your user for rsync daemon credentials: " user
|
||||||
read -p "Enter your password: " -s password
|
while true; do
|
||||||
|
read -s -p "Enter your password: " password
|
||||||
|
echo
|
||||||
|
read -s -p "Password (again): " password2
|
||||||
|
echo
|
||||||
|
[ "$password" = "$password2" ] && break
|
||||||
|
echo "Please try again"
|
||||||
|
done
|
||||||
|
|
||||||
# Hooks
|
# Hooks
|
||||||
mkdir /etc/pacman.d/hooks/
|
mkdir /etc/pacman.d/hooks/
|
||||||
|
|
|
@ -4,7 +4,14 @@ arch=$(uname -m)
|
||||||
server="$(ip addr show | grep "inet " | grep -v 127.0.0. | head -1 | cut -d" " -f6 | cut -d/ -f1)"
|
server="$(ip addr show | grep "inet " | grep -v 127.0.0. | head -1 | cut -d" " -f6 | cut -d/ -f1)"
|
||||||
## Rsync credentials
|
## Rsync credentials
|
||||||
read -p "Enter your user for rsync daemon credentials: " user
|
read -p "Enter your user for rsync daemon credentials: " user
|
||||||
read -p "Enter your password: " -s password
|
while true; do
|
||||||
|
read -s -p "Enter your password: " password
|
||||||
|
echo
|
||||||
|
read -s -p "Password (again): " password2
|
||||||
|
echo
|
||||||
|
[ "$password" = "$password2" ] && break
|
||||||
|
echo "Please try again"
|
||||||
|
done
|
||||||
|
|
||||||
# Hooks
|
# Hooks
|
||||||
mkdir /etc/pacman.d/hooks/
|
mkdir /etc/pacman.d/hooks/
|
||||||
|
|
Loading…
Reference in a new issue