#!/bin/sh set -eu export LC_ALL=C.UTF-8 trap "rm -rf /tmp/debian-chroot /tmp/log /tmp/trimmed" EXIT INT TERM # we check the full log to also prevent debug printfs to accidentally make it into a commit {{ CMD }} --mode=root --variant=apt --logfile=/tmp/log {{ DIST }} /tmp/debian-chroot {{ MIRROR }} # omit the last line which should contain the runtime head --lines=-1 /tmp/log >/tmp/trimmed cat <