Page MenuHomeFreeBSD

Allow upgrade from -BETA and -RC releases
ClosedPublic

Authored by aryeeteygerald_rogers.com on Jan 17 2019, 10:50 PM.

Details

Summary

Update to Revision 343122 to include -BETA and -RC releases
as upgrade-able via freebsd-update

Test Plan

None

Diff Detail

Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 22032
Build 21262: arc lint + arc unit

Event Timeline

usr.sbin/freebsd-update/freebsd-update.sh
669–670

The case body is executed upon a match, so is this not backwards? Also typical FreeBSD style puts the cases on a separate line, so something like:

case ${RELNUM} in
*-RELEASE | *-ALPHA* | *-BETA* | *-RC*)
        ;;
*)
        # error and exit
       ;;
esac

(also adding *-ALPHA* as noted on the svn mailing list)

usr.sbin/freebsd-update/freebsd-update.sh
669–670

Since we're going to add -ALPHA in here too I might drop the explicit -RELEASE form and make the text read more naturally with something along the lines of "is not a release (or alpha, beta or release candidate)." or "is not a release (including alpha, beta and release candidates)."

  • Include support for upgrading from alpha releases

Also fix reversed check for illegal releases

LGTM in principal (except the style issue raised by @emaste which is minor and I think he would take care of it when committing).

The two "NO ACTION REQUESTED FOR THIS CHANGESET" comments are issues that beyond the scope of this changeset, but something that we should do.

usr.sbin/freebsd-update/freebsd-update.sh
665

[NO ACTION REQUESTED FOR THIS CHANGESET] We could potentially remove this compatibility shim now.

684

[NO ACTION REQUESTED FOR THIS CHANGESET] We should consider adding a --force option to bypass this kind of checks in a separate changeset.

This revision is now accepted and ready to land.Jan 18 2019, 6:08 PM

Need to add export UNAME_r to config_SourceRelease. Will create new review with fix.

This revision was automatically updated to reflect the committed changes.