spotify / dh-virtualenv

Python virtualenvs in Debian packages

Home Page:http://dh-virtualenv.readthedocs.io/en/latest/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

installation of .deb

bee-mere opened this issue · comments

Hi,

I'm new to packaging for debian, so please excuse me if this is a stupid question.

I closely followed the getting started tutorial, which helped me to successfully build a debian package from a bare minimum python package.

Installing it using the command sudo dpkg -i ../hello-pack_0.1-1_amd64.deb also worked fine (i.e. no errors). Now I would like to be able to run the script from the python package from anywhere.
To achieve this, I think that something like what is described in "Making executables available" is necessary. However, neither debian/«pkgname»/opt/venvs/«venvname»/bin nor any other directory under debian/«pkgname» contains the executable from my python package, so I don't know what link to add.
In another tutorial on packaging, the python executable is copied to debian/«pkgname»/usr/bin by a command in debian/rules.

So now my question: what is the correct way to do this for a package built with dh-virtualenv, also s.t. the executable is executed in the created virtualenv? Here is a link to the repository, in which I am trying this. Any hint would be greatly appreciated!

It seems to me that this is a pretty standard use case for dh-virtualenv. Therefore, maybe, it would be worth to extend the Getting Started with information on what I try to find out with this.

Thanks in advance.

The tutorial assumes you followed common Python patterns, which in this case means to have setuptools console entry points. Then there is something in "bin".

Thank you!