Skip to main content

学习如何构建python模块,并打包上传pypi

Project description

# -!- coding: utf-8 -!-

# 这是我尝试进行构建的第一个python包

# 配置文件的优先级 setup.py < MANIFEST.in < setup.cfg

#创建.pypirc # windows的用户文件夹目录为: # C:UsersAdministrator.pypirc # .pypirc内容: # # [distutils] # index-servers = pypi # # [pypi] # username: 用户名 # password: 密码

#python setup.py register

#本地打包 #python setup.py sdist build #python setup.py bdist_wheel –universal

#上传到pypi #python setup.py sdist upload #python setup.py bdist_wheel upload

#或者使用twine上传,先安装twine # pip install twine #

rm -rf src/hello_python_demo_demo.egg-info dist build && python setup.py sdist build && python setup.py bdist_wheel –universal twine upload dist/*

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for hello-python-demo, version 1.0.3
Filename, size File type Python version Upload date Hashes
Filename, size hello_python_demo-1.0.3-py2.py3-none-any.whl (4.7 kB) File type Wheel Python version py2.py3 Upload date Hashes View
Filename, size hello_python_demo-1.0.3.tar.gz (3.0 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page