mirror of https://github.com/leahneukirchen/mblaze
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
372 B
Plaintext
13 lines
372 B
Plaintext
8 years ago
|
#!/bin/sh
|
||
|
# mquote MSG - format MSG as a quotation
|
||
|
|
||
|
: ${from=$(mhdr -d -h x-original-from "$1")}
|
||
|
: ${from=$(mhdr -d -h from "$1")}
|
||
|
: ${from=Someone}
|
||
|
|
||
|
echo "$from wrote:"
|
||
|
mshow -R "$1" |
|
||
|
sed -n '/^-- $/!p;//q' | # strip signature
|
||
|
sed -e :a -e '/^\n*$/{$d;N;ba' -e '}' | # strip empty lines
|
||
|
sed 's/^/> /' # prefix with >
|