<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
On 04/03/2011 17:07, Barry Warsaw wrote:
<blockquote cite="mid:20110304120743.22042ded@neurotica.wooz.org"
type="cite">
<pre wrap="">On Mar 04, 2011, at 11:22 AM, Fred Drake wrote:
</pre>
<blockquote type="cite">
<pre wrap="">On Fri, Mar 4, 2011 at 10:59 AM, <a class="moz-txt-link-rfc2396E" href="mailto:exarkun@twistedmatrix.com"><exarkun@twistedmatrix.com></a> wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Something to consider here is how this will interact with Python files which
are _not_ modules. I'm a little uneasy about having sys.modules["trial"]
refer to the module defined by /usr/bin/trial.
</pre>
</blockquote>
<pre wrap="">
I've long held the position that modules and scripts are distinct, and
should never share a source file. All the work that's going into
dealing with this just reinforces my position.
</pre>
</blockquote>
<pre wrap="">
I agree. In fact, so do the distribution tools. I don't even include actual
scripts in my packages any more, I just add the right goo to setup.py and let
distutils DTRT:
</pre>
</blockquote>
<br>
That (below) is not distutils it is setuptools. distutils just uses
`scripts=[...]`, which annoyingly *doesn't* work with setuptools.<br>
<br>
Michael Foord<br>
<br>
<blockquote cite="mid:20110304120743.22042ded@neurotica.wooz.org"
type="cite">
<pre wrap="">setup(
# ...
entry_points = {
'console_scripts' : list(scripts),
},
# ...
)
-Barry
</pre>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Python-Dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Python-Dev@python.org">Python-Dev@python.org</a>
<a class="moz-txt-link-freetext" href="http://mail.python.org/mailman/listinfo/python-dev">http://mail.python.org/mailman/listinfo/python-dev</a>
Unsubscribe: <a class="moz-txt-link-freetext" href="http://mail.python.org/mailman/options/python-dev/fuzzyman%40voidspace.org.uk">http://mail.python.org/mailman/options/python-dev/fuzzyman%40voidspace.org.uk</a>
</pre>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="72">--
<a class="moz-txt-link-freetext" href="http://www.voidspace.org.uk/">http://www.voidspace.org.uk/</a>
May you do good and not evil
May you find forgiveness for yourself and forgive others
May you share freely, never taking more than you give.
-- the sqlite blessing <a class="moz-txt-link-freetext" href="http://www.sqlite.org/different.html">http://www.sqlite.org/different.html</a>
</pre>
</body>
</html>