22 lines
724 B
Diff
22 lines
724 B
Diff
|
--- mblaze-1.1/mcom 2021-01-14 15:45:22.000000000 -0000
|
||
|
+++ mblaze-1.1f/mcom 2021-08-22 00:08:04.418851752 -0000
|
||
|
@@ -133,6 +133,18 @@ case "$0" in
|
||
|
"$draft" 1>&2
|
||
|
exit 1
|
||
|
fi
|
||
|
+ outbox=$(mhdr -h outbox "$MBLAZE/profile" | sed "s:^~/:$HOME/:")
|
||
|
+ if [ -n "$(dirname "$draft" | grep "$outbox/cur")" ]; then
|
||
|
+ newdraft=$(true | mdeliver -v -c -XD "$outbox")
|
||
|
+ if [ -z "$newdraft" ]; then
|
||
|
+ printf '%s\n' "$0: failed to load draft for editing." 1>&2
|
||
|
+ exit 1
|
||
|
+ fi
|
||
|
+ sed "s/^\(Message-Id: \).*/\1$(mgenmid 2>/dev/null)/" $draft \
|
||
|
+ > $newdraft
|
||
|
+ sed -i "s/^\(Date: \).*/\1$(mdate)/" $newdraft
|
||
|
+ draft=$newdraft
|
||
|
+ fi
|
||
|
echo "using draft $draft"
|
||
|
shift
|
||
|
fi
|