创建一个可以通过Pip& amp;安装的简单软件包虚拟环境 [英] creating a simple package that can be install via Pip & virtualenv
问题描述
我想创建一个最简单的(hello world软件包)软件包,可以使用pip在本地压缩文件的virtualenv中安装它.
在python中我会做
>> from myinstallpackage import mymodule
>> mymodule.sayhello()
hello !
setup.py和包文件夹中会有什么?
谢谢
您必须在 http://pypi.python.org/上创建帐户.然后,您可以将模块上传到 http://pypi.python.org/pypi?%3Aaction=submit_form
此站点上的文档包含所有命令,例如
如何创建可以在pipy上上传的模块?
如何从pip下载?
等...
您将在 http://docs.python.org/distutils/index.html 上获得帮助/p>
您还可以直接在 http://docs.python.org/distutils/packageindex.html 上注册
I would like to create the simplest (hello world package) package that I could install using pip in a virtualenv from a local zip file.
In python i would do
>> from myinstallpackage import mymodule
>> mymodule.sayhello()
hello !
What would be in the setup.py and in the package folder ?
Thanks
You have to create account on http://pypi.python.org/. Then you can upload the module on http://pypi.python.org/pypi?%3Aaction=submit_form.
Doc on this site contains all commands like
How to create module which can be upload on pipy?
How to download fro pip?
etc...
You will get help on http://docs.python.org/distutils/index.html
Also you can directly register on http://docs.python.org/distutils/packageindex.html
这篇关于创建一个可以通过Pip& amp;安装的简单软件包虚拟环境的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!