##// END OF EJS Templates
commands: create a "mercurial.cmd_impls" module to host graft...
commands: create a "mercurial.cmd_impls" module to host graft The "mercurial.commands" have been overweight for a while. We create a namespace dedicated to host smaller modules containing code revelant to a specific command. This should result in more isolated snd manageable module. We start with moving the code for "hg graft" in "mercurial.cmd_impls.graft" before doing more work on it. Since that code was about 5% of "commands.py" this seems like a success.

File last commit:

r43346:2372284d default
r53225:f2fc0a91 default
Show More
pypi.py
21 lines | 551 B | text/x-python | PythonLexer
# pypi.py - Automation around PyPI
#
# Copyright 2019 Gregory Szorc <gregory.szorc@gmail.com>
#
# This software may be used and distributed according to the terms of the
# GNU General Public License version 2 or any later version.
# no-check-code because Python 3 native.
from twine.commands.upload import upload as twine_upload
from twine.settings import Settings
def upload(paths):
"""Upload files to PyPI.
`paths` is an iterable of `pathlib.Path`.
"""
settings = Settings()
twine_upload(settings, [str(p) for p in paths])