mirror of
https://github.com/frappe/gunicorn.git
synced 2026-01-14 11:09:11 +08:00
28 lines
622 B
Python
28 lines
622 B
Python
# -*- coding: utf-8 -
|
|
#
|
|
# This file is part of gunicorn released under the MIT license.
|
|
# See the NOTICE for more information.
|
|
|
|
|
|
import os
|
|
|
|
if os.environ.get('release') != "true":
|
|
|
|
minor_tag = ""
|
|
try:
|
|
from gunicorn.util import popen3
|
|
|
|
stdin, stdout, stderr = popen3("git rev-parse --short HEAD --")
|
|
error = stderr.read()
|
|
if not error:
|
|
git_tag = stdout.read()[:-1]
|
|
minor_tag = ".%s-git" % git_tag
|
|
except OSError:
|
|
pass
|
|
else:
|
|
minor_tag = ""
|
|
|
|
|
|
version_info = (0, 11, "1%s" % minor_tag)
|
|
__version__ = ".".join(map(str, version_info))
|