[issue12394] packaging: generate scripts from callable (dotted paths)
Vinay Sajip
report at bugs.python.org
Sat Jun 25 09:33:11 CEST 2011
Vinay Sajip <vinay_sajip at yahoo.co.uk> added the comment:
> In the setup.cfg files, scripts will now be a mapping of names to
> callables, like the setuptools scripts and gui_scripts entry points:
>
> scripts =
> sphinx-build = sphinx.build.run
> On UNIX, a Python script named sphinx-build will be created, on
> Windows, a binary sphinx-build.exe will be created.
Perhaps some mechanism needs to be provided to indicate additional processing options per script line:
scripts =
script-name = path.to.callable opt1 opt2 opt3
One specific practical use of this is to determine whether the Windows version will launch using the text mode launcher or the GUI mode launcher. For example:
scripts =
sphinx-build = sphinx.build.run # No options => text-mode
sphinx-gui = sphinx.gui.run win # Option "win" => gui-mode
This seems more future proof than an approach like providing for a separate gui-scripts entry.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue12394>
_______________________________________
More information about the Python-bugs-list
mailing list