Prevent getting hung-up on the following prompt (found while testing with

`chflags schg /etc/ttys'):

override rw-r--r--  root/wheel for /etc/ttys? (y/n [n])

Simply by adding `-f' flag to mv(1).
This commit is contained in:
Devin Teske 2013-06-08 20:43:13 +00:00
parent 5e66bd88c9
commit f5e1223b85
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=251553

View File

@ -153,7 +153,7 @@ ttys_set_type()
printf "%s%s%s\n", left, consterm, right
}
' "$ETC_TTYS" > "$tmpfile" || return $FAILURE
f_quietly mv "$tmpfile" "$ETC_TTYS" || return $FAILURE
f_quietly mv -f "$tmpfile" "$ETC_TTYS" || return $FAILURE
return $SUCCESS
}