From e62ee8ba1d5d783f29c9b30101b8ba68874c6b12 Mon Sep 17 00:00:00 2001 From: Xiao Pan Date: Mon, 1 Apr 2024 18:14:26 -0700 Subject: better comment location --- sh/prp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sh/prp') diff --git a/sh/prp b/sh/prp index 9726ce4..27950e0 100755 --- a/sh/prp +++ b/sh/prp @@ -12,10 +12,10 @@ read_pass () { } pass_name="${1:-practice_password2}" +# `| { IFS= read -r p; printf %s "$p"; }` steal from , GPL-2.0-or-later; I use this because it is much faster than `| head -n1` correct_pass="$(pass "$pass_name" | { IFS= read -r p; printf %s "$p";})" echo "Enter password \"$pass_name\":" read_pass -# `| { IFS= read -r p; printf %s "$p"; }` steal from , GPL-2.0-or-later; I use this because it is much faster than `| head -n1` while ! [ "$entered_pass" = "$correct_pass" ]; do echo "Wrong password, enter again:" read_pass -- cgit v1.2.3-70-g09d2