diff options
| author | Tom Christie | 2015-02-06 13:10:48 +0000 | 
|---|---|---|
| committer | Tom Christie | 2015-02-06 13:10:48 +0000 | 
| commit | 0e4d202c5804aea826907fd667b672edea1ef211 (patch) | |
| tree | 4ece69167f3896de57ea6b0f44a2cc2e29f0f69e | |
| parent | 24372ec7787b1b84e46f197b2559011331e2988c (diff) | |
| parent | 750d0c9f2b994af2ba92d2d470bbe079f9d9847c (diff) | |
| download | django-rest-framework-0e4d202c5804aea826907fd667b672edea1ef211.tar.bz2 | |
Merge pull request #2527 from linovia/feature/secured_pypi_upload
Use twine to upload to pypi.
| -rw-r--r-- | requirements.txt | 2 | ||||
| -rwxr-xr-x | setup.py | 7 | 
2 files changed, 7 insertions, 2 deletions
| diff --git a/requirements.txt b/requirements.txt index 00d973cd..32938ab2 100644 --- a/requirements.txt +++ b/requirements.txt @@ -19,6 +19,8 @@ django-oauth2-provider>=0.2.4  # wheel for PyPI installs  wheel==0.24.0 +# twine for secured PyPI uploads +twine==1.4.0  # MkDocs for documentation previews/deploys  mkdocs==0.11.1 @@ -48,8 +48,11 @@ if sys.argv[-1] == 'publish':      if os.system("pip freeze | grep wheel"):          print("wheel not installed.\nUse `pip install wheel`.\nExiting.")          sys.exit() -    os.system("python setup.py sdist upload") -    os.system("python setup.py bdist_wheel upload") +    if os.system("pip freeze | grep twine"): +        print("twine not installed.\nUse `pip install twine`.\nExiting.") +        sys.exit() +    os.system("python setup.py sdist bdist_wheel") +    os.system("twine upload dist/*")      print("You probably want to also tag the version now:")      print("  git tag -a %s -m 'version %s'" % (version, version))      print("  git push --tags") | 
