]> arthur.barton.de Git - bup.git/commit
Fix release archives and add tests
authorRob Browning <rlb@defaultvalue.org>
Fri, 27 May 2016 00:30:40 +0000 (19:30 -0500)
committerRob Browning <rlb@defaultvalue.org>
Fri, 3 Jun 2016 00:13:05 +0000 (19:13 -0500)
commit861984616a20aed9d232a40a6b8055b105c48171
treebb0d303a07deecc1383f7d0d75bb6a6682f0e3b9
parentcfe9151391104782b50355982348ab4a62cca378
Fix release archives and add tests

Previously, an archive created by "git archive" would fail to build,
because the versioning code was broken (in part by
03d35993b87f49753542e705e37949a46964be17) for any build outside a git
clone.  Although "bup version" may not really have been quite right
since the switch from "bup-VERSION" to "VERSION release tags.

Fix the problem by reintroducing the content of the older
_version.py.pre as a permanent _release.py file, which (as with the
previous incarnation) is a template that's expanded during "git archive"
via export-subst (cf. gitattributes(5)).

Add a version module as the public interface to versioning, and have it
sort out whether or not the current tree is an official release.  Adjust
configure-version to manage _checkout.py instead of _version.py (drop
_version.py), so that the version module is effectively just
disambiguating between _release.py and _checkout.py.

Adjust "bup version" to use the new version module and to handle
unprefixed VERSION tags.

Finally, add test-release-archive.sh, invoked via "make distcheck", so
we (hopefully) don't unknowingly break this again.

Signed-off-by: Rob Browning <rlb@defaultvalue.org>
Tested-by: Rob Browning <rlb@defaultvalue.org>
Makefile
cmd/version-cmd.py
configure-version
lib/bup/.gitattributes
lib/bup/_release.py [new file with mode: 0644]
lib/bup/version.py [new file with mode: 0644]
t/test-release-archive.sh [new file with mode: 0755]
wvtest