Skip to content
Snippets Groups Projects

Try hard to find a git revision to use as cache key

Merged Andreas Klöckner requested to merge use-git-rev-as-cache-key into master
Files
3
+ 23
5
from __future__ import division, absolute_import
__copyright__ = "Copyright (C) 2014 Andreas Kloeckner"
__license__ = """
@@ -20,13 +22,29 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
"""
# {{{ find install- or run-time git revision
import os
if os.environ.get("AKPYTHON_EXEC_FROM_WITHIN_WITHIN_SETUP_PY") is not None:
# We're just being exec'd by setup.py. We can't import anything.
_git_rev = None
else:
import sumpy._git_rev as _git_rev_mod
_git_rev = _git_rev_mod.GIT_REVISION
# If we're running from a dev tree, the last install (and hence the most
# recent update of the above git rev) could have taken place very long ago.
from pytools import find_module_git_revision
_runtime_git_rev = find_module_git_revision(__file__, n_levels_up=1)
if _runtime_git_rev is not None:
_git_rev = _runtime_git_rev
# }}}
VERSION = (2016, 1)
VERSION_STATUS = "beta1"
VERSION_TEXT = ".".join(str(x) for x in VERSION) + VERSION_STATUS
# When developing on a branch, set the first element of this tuple to your
# branch name, so as to avoid conflicts with the master branch. Make sure
# to reset this to the next number up with "master" before merging into
# master.
KERNEL_VERSION = ("master", 31)
KERNEL_VERSION = (VERSION, _git_rev, 0)
Loading