summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2021-03-23 17:47:03 +0100
committerFlorian Pritz <bluewind@xinu.at>2021-03-23 17:47:03 +0100
commitdc486d6710ae5ae4bccd913eeb75c67694c7da4e (patch)
treeabc7585f31366891727bb7029e58c6f276931e85
parent6ea239f916c95e0b862c6f9e3a33ce1bf13c3840 (diff)
downloadbin-dc486d6710ae5ae4bccd913eeb75c67694c7da4e.tar.gz
bin-dc486d6710ae5ae4bccd913eeb75c67694c7da4e.tar.xz
term-open: Support mailto links without recipient
Signed-off-by: Florian Pritz <bluewind@xinu.at>
-rwxr-xr-xterm-open8
1 files changed, 7 insertions, 1 deletions
diff --git a/term-open b/term-open
index e61c7fc..d47367c 100755
--- a/term-open
+++ b/term-open
@@ -1,10 +1,16 @@
#!/bin/bash
+logger "Running term-open with args: $*"
+
cmd=$1; shift
term=termite
if [[ $cmd = "mutt" ]]; then
- exec termite -e "mutt -e 'set autoedit=yes' -- $*"
+ if [[ "$*" = 'mailto:?'* ]]; then
+ exec termite -e "mutt -- $*"
+ else
+ exec termite -e "mutt -e 'set autoedit=yes' -- $*"
+ fi
fi
exec termite -e "$cmd -- $*"