setuptools: ALL source tree?
Trying to put setuptools to work, from the svn workspace, with no previous experience of distutils or setuptools (previously had a script making a tarball). As often happens with very good tools, very well documented, some very simple, yet vital pieces of information is missing for the newcomer. my source tree: root setup.py package scripts test doc I dont want to distribute test: internal non-regression tools and data. dont want to distribute doc either. I found NO WAY, with setup.py at the top, to get these files out of the tarball. Am I supposed to make ONE tree with all I want to distribute, and all I dont want distributed in some other tree? Like: root dist setup.py package scripts test doc Its no big deal, Im redesigning the layering. But then, the only way to say: "I dont want this distributed any more" is by moving the file? Or did I miss some point? Thanks for answering
At 04:14 PM 10/10/2006 -0400, Pierre Imbaud wrote:
Trying to put setuptools to work, from the svn workspace, with no previous experience of distutils or setuptools (previously had a script making a tarball). As often happens with very good tools, very well documented, some very simple, yet vital pieces of information is missing for the newcomer. my source tree: root setup.py package scripts test doc
I dont want to distribute test: internal non-regression tools and data. dont want to distribute doc either. I found NO WAY, with setup.py at the top, to get these files out of the tarball.
See: http://python.org/doc/2.4.1/dist/manifest.html and: http://python.org/doc/2.4.1/dist/sdist-cmd.html#sdist-cmd for the full doc on this. The short version: create a MANIFEST.in file in 'root' with these two lines: prune test prune doc Setuptools will then remove anything under those subdirectories from its source lists. The files will not then be included in source distributions. If you do this, by the way, you should make sure that there is nothing your setup.py needs that is in those directories. Otherwise, source distribution tarballs built with the 'sdist' command will not be buildable or installable.
Phillip J. Eby wrote :
At 04:14 PM 10/10/2006 -0400, Pierre Imbaud wrote:
Trying to put setuptools to work, from the svn workspace, with no previous experience of distutils or setuptools (previously had a script making a tarball). As often happens with very good tools, very well documented, some very simple, yet vital pieces of information is missing for the newcomer. ...
See:
http://python.org/doc/2.4.1/dist/manifest.html
and:
http://python.org/doc/2.4.1/dist/sdist-cmd.html#sdist-cmd
for the full doc on this.
The short version: create a MANIFEST.in file in 'root' with these two lines:
prune test prune doc
Setuptools will then remove anything under those subdirectories from its source lists. The files will not then be included in source distributions. Works fine! thanks a lot!
participants (2)
-
Phillip J. Eby
-
Pierre Imbaud