obs: reset kata_version

We've changed `-rc` to `~rc` for rpmbuild. But we need to change
it back when doing comparision.

Signed-off-by: Peng Tao <bergwolf@gmail.com>
This commit is contained in:
Peng Tao 2018-12-24 16:50:25 +08:00
parent dcd3bd0476
commit f4994f4531

View File

@ -138,6 +138,7 @@ main() {
if [ -n "$compareOnly" ]; then
source "./${versions_txt}" || exit 1
kata_version=${kata_version/\~/-}
[ -n "${kata_version}" ] || die "${version_file} does not contain a valid kata_version variable"
[ "$(get_kata_version $branch)" = "${kata_version}" ] && compare_result="matches" || compare_result="is different from"
echo "${kata_version} in ${versions_txt} ${compare_result} the version at branch ${branch}"