summaryrefslogtreecommitdiff
path: root/xii
diff options
context:
space:
mode:
authorJohn Ankarström <john@ankarstrom.se>2020-11-22 01:30:55 +0100
committerJohn Ankarström <john@ankarstrom.se>2020-11-22 01:31:32 +0100
commit850f917b6aaea6f25bab8860ede290eb66fe958b (patch)
tree469403bd96d4ea98bc0e0288c7f763457aed51e9 /xii
parent8b4e99e55b54b61a9b0c7063e9ee8482f99537b0 (diff)
downloadweb-850f917b6aaea6f25bab8860ede290eb66fe958b.tar.gz
blq: Add -r option
The -r option processes the search results with blm and opens the mbox file in a given mail reader.
Diffstat (limited to 'xii')
-rwxr-xr-xxii5
1 files changed, 2 insertions, 3 deletions
diff --git a/xii b/xii
index dc4a620..c79e967 100755
--- a/xii
+++ b/xii
@@ -8,13 +8,12 @@
dir=/tmp/$RANDOM
mkdir $dir
-grep '^X-Image: ' |
-sed 's/^X-Image: //' |
+sed -n 's/^X-Image: //p' |
while read url
do
curl "$url" > $dir/$RANDOM
done
# Display images and delete them afterwards
-$VIEWER $dir/* < /dev/tty
+eval $VIEWER $dir/* < /dev/tty
rm -r $dir