$ sudo apt-get install uudeview
$ echo -e "From: myaddress@mydomain.com\nTo: youraddress@yourdomain.com\nSubject: mySubject\n\nBody-Text"|uuenview -a -bo MyAttachment|sendmail -t
Возможно, небольшой конечный автомат:
tac file |
awk '/End of script/ {p=1} p {print} p && /Start of script/ {exit}' |
tac
Возможно проще, чем ответ Гленна (хотя для этого нужно дважды ввести «Начало сценария»):
tac logfile | awk '/End of script/,/Start of script/{print} /Start of script/{exit}' | tac
или
tac logfile | sed -n '/End of script/,/Start of script/p; /Start of script/q' | tac