-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun.sh
More file actions
37 lines (35 loc) · 797 Bytes
/
run.sh
File metadata and controls
37 lines (35 loc) · 797 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# https://stackoverflow.com/questions/19950620/how-to-hide-password-in-command-line-with-and-get-the-value-into-bat-file
echo "Welcome to the FileCommitAnimator! You'll need a Github account to continue."
echo ""
prompt="Enter Github Email: "
while IFS= read -p "$prompt" -r -s -n 1 char
do
if [[ $char == $'\0' ]]; then
break
fi
if [[ $char == $'\177' ]]; then
prompt=$'\b \b'
password="${username%?}"
else
prompt="$char"
username+="$char"
fi
done
echo " "
prompt="Enter Password: "
while IFS= read -p "$prompt" -r -s -n 1 char
do
if [[ $char == $'\0' ]]; then
break
fi
if [[ $char == $'\177' ]]; then
prompt=$'\b \b'
password="${password%?}"
else
prompt='*'
password+="$char"
fi
done
echo " "
echo " "
php create.php "$username" "$password"