diff options
author | Christian Neukirchen <chneukirchen@gmail.com> | 2016-07-28 13:57:18 +0200 |
---|---|---|
committer | Christian Neukirchen <chneukirchen@gmail.com> | 2016-07-28 13:57:18 +0200 |
commit | dc43475d7641ad4d410279a9d80ec2b5a838c8ce (patch) | |
tree | a521509a764f6bccb36c17bace501138da445f27 /mless | |
parent | ddf275fa83238242a3f84736197d8fc8e56eeded (diff) | |
download | mblaze-dc43475d7641ad4d410279a9d80ec2b5a838c8ce.tar.gz mblaze-dc43475d7641ad4d410279a9d80ec2b5a838c8ce.tar.xz mblaze-dc43475d7641ad4d410279a9d80ec2b5a838c8ce.zip |
mless: tone down footers and pgp armor
Diffstat (limited to 'mless')
-rwxr-xr-x | mless | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/mless b/mless index c4bdc53..2feaf03 100755 --- a/mless +++ b/mless @@ -9,9 +9,15 @@ function fg(c, s) { return sprintf("\033[38;5;%03dm%s\033[0m", c, s) } function so(s) { return sprintf("\033[1m%s\033[0m", s) } BEGIN { hdr = 1 } /^$/ { hdr = 0 } +/^-- $/ { ftr = 1 } +/^--- .* ---/ { print fg(242, $0); ftr = 0; sig = 0; next } +/^-----BEGIN .* SIGNATURE-----/ { sig = 1 } hdr && /^From:/ { print so(fg(119, $0)); next } hdr { print fg(120, $0); next } -/^--- .* ---/ { print fg(242, $0); next } +ftr { print fg(244, $0); next } +/^-----BEGIN .* MESSAGE-----/ || +/^-----END .* SIGNATURE-----/ { print fg(244, $0); sig = 0; next } +sig { print fg(244, $0); next } /^>/ { print fg(151, $0); next } { print }' } |