Bug#852171: debcheckout: warn when checkout is older than sid?

Daniel Shahaf danielsh at apache.org
Sun Jan 22 10:34:32 UTC 2017


Package: devscripts
Version: 2.17.0
Severity: wishlist
Tags: upstream

Dear Maintainer,

Since NMUs may not be committed to the repository of the package being
NMU'd, 'debcheckout' of a package that had been NMU'd wouldn't fetch the
latest source of that package.

Would it be useful for debcheckout to detect that case and warn about
it?  For example, debcheckout could, after checking out a working tree
but before exiting, compare the version at the top of the checked out
debian/changelog to the version in sid, and warn if sid is newer.

This presumes that the default branch is the one that sid development
happens on, which is a "should" in policy.

Something along these lines:

    debcheckout() {
      local package="$1"
      command debcheckout "$package"
      if ! dpkg --compare-versions \
               $(cd ${package} && dpkg-parsechangelog -SVersion) \
               ge \
               $(rmadison "$1" | grep -w sid | tail -1 | cut -d\| -f2);
      then
          echo >&2 "debcheckout: warning: ..."
      fi
    }

Cheers,

Daniel



More information about the devscripts-devel mailing list