subiquity/bin/console-conf-wrapper

19 lines
417 B
Bash
Executable File

#!/bin/sh
set -e
trap true HUP INT QUIT TSTP
# agetty only sets ICRNL if it has read the username and seen whether
# it was terminated by CR or NL. We pass -n to agetty so that hasn't
# happened and need to force it on. Yay UNIX!
stty icrnl
if [ "$(snap managed)" = "true" ]; then
touch /var/lib/console-conf/complete
exit 0
fi
cat /usr/share/subiquity/console-conf-wait
read REPLY
exec console-conf "$@"