Exemplo n.º 1
0
def update_deb_command():
    import email.utils
    import time
    changelog_entry_template = """mapproxy (%(version)s) unstable; urgency=low

  * New upstream release.

 -- %(user)s <%(email)s>  %(time)s

"""
    with open('debian/changelog') as f:
        old_changelog = f.read()

    changelog = changelog_entry_template % {
        'version': version(),
        'user': backtick_('git config --get user.name').strip(),
        'email': backtick_('git config --get user.email').strip(),
        'time': email.utils.formatdate(time.time(), True),
    }
    changelog += old_changelog
    with open('debian/changelog', 'w') as f:
        f.write(changelog)
Exemplo n.º 2
0
def update_deb_command():
    import email.utils
    import time

    changelog_entry_template = """mapproxy (%(version)s) unstable; urgency=low

  * New upstream release.

 -- %(user)s <%(email)s>  %(time)s

"""
    with open("debian/changelog") as f:
        old_changelog = f.read()

    changelog = changelog_entry_template % {
        "version": version(),
        "user": backtick_("git config --get user.name").strip(),
        "email": backtick_("git config --get user.email").strip(),
        "time": email.utils.formatdate(time.time(), True),
    }
    changelog += old_changelog
    with open("debian/changelog", "w") as f:
        f.write(changelog)
Exemplo n.º 3
0
def version():
    package_name = PACKAGE_NAME
    version = backtick_('grep Version: %(package_name)s.egg-info/PKG-INFO' % locals())
    version = version.split(':')[-1].strip()
    return version
Exemplo n.º 4
0
def upload_test_sdist_command():
    date = backtick_('date +%Y%m%d').strip()
    print(
        'python setup.py egg_info -R -D -b ".dev%s" register -r testpypi sdist upload -r testpypi'
        % (date, ))
Exemplo n.º 5
0
def upload_test_sdist_command():
    date = backtick_("date +%Y%m%d").strip()
    print ('python setup.py egg_info -R -D -b ".dev%s" register -r testpypi sdist upload -r testpypi' % (date,))