1
0
Fork 0

update reactiontag

This commit is contained in:
tastytea 2023-10-05 17:28:29 +02:00
parent 4f0843110b
commit 3e9f1d8c94
Signed by: tastytea
SSH Key Fingerprint: SHA256:FBkvrOlhq5use1XEttyUGT4bUTDVA1ar9SgIc9P03cM
1 changed files with 7 additions and 4 deletions

View File

@ -3,7 +3,7 @@
setopt LOCAL_OPTIONS ERR_RETURN NO_UNSET PIPE_FAIL
if [[ ! -v 1]]; then
if [[ ! -v 1 ]]; then
print -u 2 "usage: ${0} <FILE>"
return 1
fi
@ -11,8 +11,11 @@ file=${1}
zmodload zsh/attr
read -r -d  '?source: ' source
read -r '?source: ' source
zsetattr ${file} user.source ${source}
read -r -d  '?description: ' description
zsetattr ${file} user.description ${description}
tmpfile==()
print "enter description, save and exit editor" > ${tmpfile}
eval ${VISUAL} ${tmpfile}
zsetattr ${file} user.description "$(<${tmpfile})"
rm ${tmpfile}