More Related Content
Similar to パッケージングの今と未来 (20)
More from Atsushi Odagiri
More from Atsushi Odagiri (20)
パッケージングの今と未来
- 16. メタデータ
(hello) $ python setup.py egg_info
(hello) $ cat hello.egg-info/PKG-INFO
(hello) $ cat hello.egg-info/entry_points.txt
- 22. リリース
$ hg commit
$ hg tag hello-0.1 # egg name
$ hg push --new-branch
https://bitbucket.org/aodag/python-
hello/get/hello-0.1.zip
- 36. 未来を感じてみよう
Python3.3は入ってますよね?
$ mkdir hello33; cd hello33
$ pyvenv env
$ . env/bin/activate
(hello33) $ wget https://bitbucket.
org/pypa/setuptools/downloads/ez_setup.py
(hello33) $ wget https://raw.github.
com/pypa/pip/master/contrib/get-pip.py
- 37. Don't think FEEL
$ pip install -U setuptools==0.8
$ pip install -U https://github.
com/pypa/pip/archive/1.4rc2.tar.gz
$ pip install wheel
準備完了
- 38. wheeling!
C拡張あり
$ pip wheel Pillow
$ ls wheelhouse
Pillow-2.1.0-cp33-cp33m-linux_x86_64.whl
C拡張なし
$ pip wheel webob
$ ls wheelhouse
WebOb-1.2.3-py33-none-any.whl
- 39. use it!
インストールして使う
$ pip install wheelhouse/WebOb-1.2.3-py33-
none-any.whl
マウントして使う
import distlib.wheel
distlib.wheel.Wheel('wheelhouse/Pillow-2.1.0-
cp33-cp33m-linux_x86_64.whl')
import PIL