xdgtag: Delete attribute if empty
This commit is contained in:
parent
210ea9aca3
commit
a8688a8978
@ -36,7 +36,11 @@ case ${cmd} in
|
||||
for tag in ${(@)tags}; do
|
||||
taglist=(${(@)taglist:#${tag}})
|
||||
done
|
||||
zsetattr ${file} ${attribute} "${(j/,/)taglist}"
|
||||
if [[ -n ${taglist} ]]; then
|
||||
zsetattr ${file} ${attribute} ${(j/,/)taglist}
|
||||
else
|
||||
zdelattr ${file} ${attribute}
|
||||
fi
|
||||
;;
|
||||
find)
|
||||
setopt LOCAL_OPTIONS GLOB
|
||||
|
Loading…
x
Reference in New Issue
Block a user