Python setuptools 简介
来源:互联网 发布:mysql存储过程实例 编辑:程序博客网 时间:2024/05/29 18:59
setuptools 官方文档
https://setuptools.readthedocs.io/en/latest/setuptools.html#id3
完整代码 :
https://code.csdn.net/lijiecong/examples/tree/master/python/setuptest
from setuptools import *setup( name='clicktest', version='0.1', packages=find_packages(), py_modules=['clicktest', 'clicktest2'], install_requires=['click'], entry_points={ 'console_scripts': [ 'clicktest = clicktest:hunt', 'clicktestpp = clicktest:test', ], },)
python setup.py install
egg相当于java的jar包,可以用压缩工具打开查看,egg部署以后,在site-packages/easy-install.pth 文件中户包含该egg。
egg中的所有py和package都可以直接导入使用,为避免namespace污染,可以在你的egg里面再加一层包。
不正是发布的时候,只要把egg加到sys.path里面即可,例如:
>>> import sys
>>> sys.path.append('D:\code\python\setuptest\dist\clicktest-0.1-py3.6.egg')
>>> import clicktest
阅读全文
0 0
- Python深入:setuptools简介
- Python setuptools 简介
- Python中setuptools的简介
- Python中setuptools的简介
- Python中setuptools的简介
- Python中setuptools的简介
- Python中setuptools的简介
- Python中setuptools的简介
- Python打包分发工具setuptools简介
- python Setuptools
- 几个Python配置工具简介:setuptools、pip、virtualenv
- 几个Python配置工具简介:setuptools、pip、virtualenv
- python安装python-setuptools
- 使用setuptools自动安装python模块(setuptools)
- python安装之setuptools
- python的setuptools
- cygwin 安装 python setuptools
- Python--Setuptools的安装
- centos 7 linux 安装与卸载 tomcat 7
- linux内核的三种主要调度策略
- 1032. 挖掘机技术哪家强(20)
- 2017-10-19的订餐库脚本与SQL 语句
- Linux增加虚拟内存的配置方案
- Python setuptools 简介
- 谈谈malloc()和free()
- (Android)react-native签名打包
- Linux的sleep()和usleep()的使用和区别
- Work Like Alibaba第三期:数据驱动研发效能提升实践
- msf 学习笔记(1)
- 转载部分代码,窗口点击问题,顺序,初始化数组,简单结构体
- 函数指针
- Spring 框架学习(一):设计理念、整体架构