File: register.py

package info (click to toggle)
python-setuptools 40.8.0-1
  • links: PTS
  • area: main
  • in suites: buster
  • size: 3,488 kB
  • sloc: python: 23,834; ansic: 195; makefile: 99; xml: 14
file content (18 lines) | stat: -rw-r--r-- 534 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
from distutils import log
import distutils.command.register as orig


class register(orig.register):
    __doc__ = orig.register.__doc__

    def run(self):
        try:
            # Make sure that we are using valid current name/version info
            self.run_command('egg_info')
            orig.register.run(self)
        finally:
            self.announce(
                "WARNING: Registering is deprecated, use twine to "
                "upload instead (https://pypi.org/p/twine/)",
                log.WARN
            )