[pgrouting-dev] Version, version, who has the version
Stephen Woodbridge
woodbri at swoodbridge.com
Mon May 27 21:16:23 PDT 2013
I have made a bunch of changes that are all version related.
1. I have added three functions (not documented)
pgr_test=# select pgr_version();
pgr_version
-------------
2.0.0-dev
(1 row)
pgr_test=# select pgr_full_version();
pgr_full_version
----------------------------------------------
2.0.0-dev v2.0dev-271-g6eeef9b sew-devel-2_0
(1 row)
pgr_test=# select pgr_build_version();
pgr_build_version
------------------------------------
v2.0dev-271-g6eeef9b sew-devel-2_0
(1 row)
Here is what all this means:
2.0.0-dev v2.0dev-271-g6eeef9b sew-devel-2_0
--------- ------- --- ------- -------------
VERSION TAG BUILD HASH BRANCH
2. I have added a top-level file VERSION and tools/pre-commit hook to
keep it updated. Daniel you will have to copy tools/pre-commit to
.git/hooks/pre-commit
I'm not sure how much I like this. I have tried a post-commit hook which
updates the local file with the hash and build info after the commit in
the local copy but not the copy send to github and the pre-commit hook
updates the file with the has BEFORE the commit so it always reflects
and state before the commit, but that also means the number in the file
will match what is on the server.
BTW, It is not possible to set the hash of a current commit into a file
that is getting committed because the hash IS based on the content of
the files committed, so you get infinite recursion!
3. I also modified CMakeLists.txt to read the version info from the
VERSION file and commented out the FindGit stuff. This means that if
someone grabs a tarball, it will have the VERSION file and cmake will
set its variables based on that file which will be more accurate.
4. I have set the pgrouting version number 2.0.0-dev and I have set a
tags v2.0dev at approximately the point that I branced sew-devel-2_0 off
of master.
We can remove the pre-commit hook if you don't like that and manually
set it at appropriate points in the process, but this makes for errors.
-Steve
More information about the pgrouting-dev
mailing list