diff options
Diffstat (limited to 'src/local/pager.nim')
-rw-r--r-- | src/local/pager.nim | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/local/pager.nim b/src/local/pager.nim index 388c5448..6977a4eb 100644 --- a/src/local/pager.nim +++ b/src/local/pager.nim @@ -1122,6 +1122,7 @@ proc checkMailcap(pager: Pager, container: Container): (EmptyPromise, bool) = tempfile var canpipe = true let cmd = unquoteCommand(entry.cmd, contentType, outpath, url, cs, canpipe) + putEnv("MAILCAP_URL", $url) if {COPIOUSOUTPUT, HTMLOUTPUT} * entry.flags == {}: # no output. if canpipe: @@ -1133,6 +1134,7 @@ proc checkMailcap(pager: Pager, container: Container): (EmptyPromise, bool) = return pager.runMailcapReadPipe(container, entry[], cmd) else: return pager.runMailcapReadFile(container, entry[], cmd, outpath) + delEnv("MAILCAP_URL") return (nil, true) proc handleEvent0(pager: Pager, container: Container, event: ContainerEvent): bool = |