Avoid warning 'stdin not a tty' in some cases

Signed-off-by: Tanya Degurechaff <34323200+TanyaEleventhGoddess@users.noreply.github.com>
This commit is contained in:
Tanya Degurechaff
2020-07-07 09:52:41 +02:00
parent c1552e32f2
commit f91a618e02
2 changed files with 10 additions and 0 deletions
+5
View File
@@ -594,6 +594,11 @@ EOF
# Re-enable service startup # Re-enable service startup
rm "${rootfs}/usr/sbin/policy-rc.d" rm "${rootfs}/usr/sbin/policy-rc.d"
# Fix by Greg Olsen, avoid warning 'stdin not a tty' in some cases
if [[ -f "${rootfs}/root/.profile" ]]; then
sed -i -e 's/^mesg n/test -t 0 \&\& mesg n/g' ${rootfs}/root/.profile
fi
# end # end
} }
+5
View File
@@ -570,6 +570,11 @@ EOF
# Re-enable service startup # Re-enable service startup
rm "${rootfs}/usr/sbin/policy-rc.d" rm "${rootfs}/usr/sbin/policy-rc.d"
# Fix by Greg Olsen, avoid warning 'stdin not a tty' in some cases
if [[ -f "${rootfs}/root/.profile" ]]; then
sed -i -e 's/^mesg n/test -t 0 \&\& mesg n/g' ${rootfs}/root/.profile
fi
# end # end
} }