Use ${PAGER} (or `more' if not defined) instead of w3m - plumb - Open certain URL patterns with an ad-hoc opener (plumber)
(HTM) hg clone https://bitbucket.org/iamleot/plumb
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
---
(DIR) changeset 9866274c50dc049599221fe5d123e55822006abd
(DIR) parent e89f98c6d54347754d8d8abbf4084850717658d7
(HTM) Author: Leonardo Taccari <iamleot@gmail.com>
Date: Sat, 1 Sep 2018 16:15:54
Use ${PAGER} (or `more' if not defined) instead of w3m
It is probably handier for text files.
Diffstat:
openers/txt | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff -r e89f98c6d543 -r 9866274c50dc openers/txt
--- a/openers/txt Tue Aug 14 02:15:13 2018 +0200
+++ b/openers/txt Sat Sep 01 16:15:54 2018 +0200
@@ -1,5 +1,7 @@
#!/bin/sh
+: ${PAGER:=more}
+
for u in "$@"; do
- tmux new-window "w3m \"$u\""
+ tmux new-window "curl -gLs \"$u\" | ${PAGER}"
done