UBUNTU: [Packaging] update helper scripts

BugLink: https://bugs.launchpad.net/bugs/1786013Signed-off-by: default avatarMarcelo Henrique Cerri <marcelo.cerri@canonical.com>
parent 3f550603
...@@ -109,15 +109,20 @@ if [ "$series" != 'UNRELEASED' ]; then ...@@ -109,15 +109,20 @@ if [ "$series" != 'UNRELEASED' ]; then
fi fi
# Update configs # Update configs
chroot_run fakeroot debian/rules clean updateconfigs if [ -d "$DEBIAN/config" ]; then
changes=$(git diff HEAD -- "./$DEBIAN/config/") chroot_run fakeroot debian/rules clean updateconfigs
if [ "$commit_configs" -eq 0 ] && [ -n "$changes" ]; then changes=$(git diff HEAD -- "./$DEBIAN/config/")
echo "Config has changed! please, review it and commit." if [ "$commit_configs" -eq 0 ] && [ -n "$changes" ]; then
exit 1 echo "Config has changed! please, review it and commit."
exit 1
fi
fi fi
# Derivatives and backports have a master kernel directory (DEBIAN_MASTER). # Derivatives and backports have a master kernel directory (DEBIAN_MASTER).
if [ "$DEBIAN" != 'debian.master' ] && [ $skip_master_entries == 0 ]; then case "$DEBIAN" in
debian.master|debian.uc20-efi) skip_master_entries=1 ;;
esac
if [ $skip_master_entries == 0 ]; then
if [ "$DEBIAN_MASTER" = "" ]; then if [ "$DEBIAN_MASTER" = "" ]; then
echo "DEBIAN_MASTER should be defined either in $DEBIAN/etc/update.conf or the environment" echo "DEBIAN_MASTER should be defined either in $DEBIAN/etc/update.conf or the environment"
exit 1 exit 1
......
...@@ -56,6 +56,18 @@ while getopts "r:b:l:d" opt; do ...@@ -56,6 +56,18 @@ while getopts "r:b:l:d" opt; do
done done
shift $((OPTIND - 1)) shift $((OPTIND - 1))
case "$DEBIAN" in
debian.master|debian.uc20-efi)
echo "This is not a rebase kernel, no rebase should be needed, please report if otherwise"
exit 0
;;
esac
if [ "$DEBIAN_MASTER" = "" ]; then
echo "DEBIAN_MASTER should be defined either in ${DEBIAN}/etc/update.conf or the environment"
exit 1
fi
if [ -z "${LOCAL_BRANCH}" ]; then if [ -z "${LOCAL_BRANCH}" ]; then
if [ -z "${RELEASE_REPO}" ] || [ -z "${SOURCE_RELEASE_BRANCH}" ]; then if [ -z "${RELEASE_REPO}" ] || [ -z "${SOURCE_RELEASE_BRANCH}" ]; then
echo Missing update.conf or missing parameters for remote repo and branch. echo Missing update.conf or missing parameters for remote repo and branch.
...@@ -69,16 +81,6 @@ if [ -z "${LOCAL_BRANCH}" ]; then ...@@ -69,16 +81,6 @@ if [ -z "${LOCAL_BRANCH}" ]; then
LOCAL_BRANCH=FETCH_HEAD LOCAL_BRANCH=FETCH_HEAD
fi fi
if [ "$DEBIAN" = "debian.master" ]; then
echo "This is a master kernel, no rebase should be needed, please report if otherwise"
exit 0
fi
if [ "$DEBIAN_MASTER" = "" ]; then
echo "DEBIAN_MASTER should be defined either in ${DEBIAN}/etc/update.conf or the environment"
exit 1
fi
# #
# Find the most recent tag on given upstream branch, then # Find the most recent tag on given upstream branch, then
# rebase against it. This avoids the case where there have been some # rebase against it. This avoids the case where there have been some
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment