From b268f84698a2f1557a1a06b0c1aff636b283f9e1 Mon Sep 17 00:00:00 2001 From: Sergey Matveev Date: Tue, 30 Jul 2024 10:18:55 +0300 Subject: [PATCH] Unify redirection operator usage --- passman | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/passman b/passman index 7a0ad40..51177b7 100755 --- a/passman +++ b/passman @@ -45,7 +45,7 @@ tmp=`mktemp`.rec trap "rm -f $tmp ${DB}.tmp" HUP PIPE INT QUIT TERM EXIT finder() { - dec | recsel -e "Name ~ '$1'" > $tmp + dec | recsel -e "Name ~ '$1'" >$tmp [ $(recsel -c $tmp) -eq 1 ] || { recsel -C -P Name $tmp exit 1 @@ -53,7 +53,7 @@ finder() { } commit() { - enc < $tmp > ${DB}.tmp + enc <$tmp >${DB}.tmp fsync ${DB}.tmp mv ${DB}.tmp $DB } @@ -71,11 +71,11 @@ add) [ -n "$dst" ] [ -n "$passwd" ] || passwd=$(generator) echo ${dst}... - dec | recins -t Credential -f Name -v "$dst" -f Passwd -v "$passwd" > $tmp + dec | recins -t Credential -f Name -v "$dst" -f Passwd -v "$passwd" >$tmp commit ;; mod) - dec > $tmp + dec >$tmp $EDITOR $tmp commit ;; -- 2.48.1