commit ab7790094d7d836f64a532c542278321e803628c parent d445d2295652a9a5eb3936151f70824c85ff0831 Author: William Casarin <jb55@jb55.com> Date: Sun, 15 Nov 2020 11:07:45 -0800 notmuch: improve show pretty script Diffstat:
M | bin/notmuch-show-pretty | | | 10 | +++++++++- |
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/bin/notmuch-show-pretty b/bin/notmuch-show-pretty @@ -1,2 +1,10 @@ #!/usr/bin/env sh -exec sed 's,,-----------------------------\n,g' + +script=$(cat <<EOS +s//\n/g; +/^[[:space:]]*(part|header|body|message)}$/d; +/^[[:space:]]*(part|header|body)\{.*$/d +EOS +) + +exec sed -E "$script"