aboutsummaryrefslogtreecommitdiff
path: root/bin/list-contacts
diff options
context:
space:
mode:
Diffstat (limited to 'bin/list-contacts')
-rwxr-xr-xbin/list-contacts7
1 files changed, 7 insertions, 0 deletions
diff --git a/bin/list-contacts b/bin/list-contacts
new file mode 100755
index 0000000..1492773
--- /dev/null
+++ b/bin/list-contacts
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+# Search in contact list built by khard, outputs the search results as
+# NAME <ADDRESS>
+khard email --remove-first-line --parsable $@ \
+ | cut -f 1,2 \
+ | awk -F "\t" '{printf "%s <%s>\n", $2, $1}'