if for_release: assert '.dev' not in VERSION and '.post' not in VERSION else: # add datestamp if doing a snapshot dstr = time.strftime("%Y%m%d") if VERSION.endswith(".dev0") or VERSION.endswith(".post0"): VERSION = VERSION[:-1] + dstr else: assert '.dev' not in VERSION and '.post' not in VERSION VERSION += ".post" + dstr # subclass build_py & sdist so they rewrite passlib/__init__.py # to have the correct version string from passlib._setup.stamp import stamp_distutils_output stamp_distutils_output(opts, VERSION) #========================================================= #static text #========================================================= SUMMARY = "comprehensive password hashing framework supporting over 20 schemes" DESCRIPTION = """\ Passlib is a password hashing library for Python 2 & 3, which provides cross-platform implementations of over 20 password hashing algorithms, as well as a framework for managing existing password hashes. It's designed to be useful for a wide range of tasks, from verifying a hash found in /etc/shadow, to providing full-strength password hashing for multi-user application. * See the `online documentation <http://packages.python.org/passlib>`_
# append hg revision to builds stamp_build = False if stamp_build: from passlib._setup.stamp import (as_bool, append_hg_revision, stamp_distutils_output, install_build_py_exclude, set_command_options) # add HG revision to end of version if as_bool(os.environ.get("SETUP_TAG_RELEASE", "yes")): version = append_hg_revision(version) # subclass build_py & sdist to rewrite source version string, # and clears stamp_build flag so this doesn't run again. stamp_distutils_output(opts, version) # exclude 'passlib._setup' from builds, only needed for sdist install_build_py_exclude(opts) set_command_options( opts, "build_py", exclude_packages=["passlib._setup"], ) opts['version'] = version #============================================================================= # set release status #=============================================================================
if for_release: assert '.dev' not in VERSION and '.post' not in VERSION else: # add datestamp if doing a snapshot dstr = time.strftime("%Y%m%d") if VERSION.endswith(".dev0") or VERSION.endswith(".post0"): VERSION = VERSION[:-1] + dstr else: assert '.dev' not in VERSION and '.post' not in VERSION VERSION += ".post" + dstr # subclass build_py & sdist so they rewrite passlib/__init__.py # to have the correct version string from passlib._setup.stamp import stamp_distutils_output stamp_distutils_output(opts, VERSION) #============================================================================= # static text #============================================================================= SUMMARY = "comprehensive password hashing framework supporting over 30 schemes" DESCRIPTION = """\ Passlib is a password hashing library for Python 2 & 3, which provides cross-platform implementations of over 30 password hashing algorithms, as well as a framework for managing existing password hashes. It's designed to be useful for a wide range of tasks, from verifying a hash found in /etc/shadow, to providing full-strength password hashing for multi-user application. * See the `online documentation <http://packages.python.org/passlib>`_ for details, installation instructions, and examples.