Browse files

Clean up entry point definition is setup.py.

  • Loading branch information...
1 parent 87eb19d commit df417106f4047d3ce98ded8e880975ebdadac56a epatters committed May 10, 2011
Showing with 8 additions and 27 deletions.
  1. +2 −6 setup.py
  2. +6 −21 setupbase.py
View
8 setup.py
@@ -58,7 +58,6 @@
find_packages,
find_package_data,
find_scripts,
- find_gui_scripts,
find_data_files,
check_for_dependencies,
record_commit_info,
@@ -211,10 +210,7 @@ def cleanup():
if 'setuptools' in sys.modules:
setuptools_extra_args['zip_safe'] = False
- setuptools_extra_args['entry_points'] = {
- 'console_scripts': find_scripts(True),
- 'gui_scripts': find_gui_scripts(True),
- }
+ setuptools_extra_args['entry_points'] = find_scripts(True)
setup_args['extras_require'] = dict(
parallel = 'pyzmq>=2.1.4',
zmq = 'pyzmq>=2.0.10.1',
@@ -247,7 +243,7 @@ def cleanup():
# check for dependencies an inform the user what is needed. This is
# just to make life easy for users.
check_for_dependencies()
- setup_args['scripts'] = find_scripts(False) + find_gui_scripts(False)
+ setup_args['scripts'] = find_scripts(False)
#---------------------------------------------------------------------------
# Do the actual setup now
View
27 setupbase.py
@@ -269,7 +269,7 @@ def find_scripts(entry_points=False):
return file paths of plain scripts [default]
"""
if entry_points:
- scripts = [
+ console_scripts = [
'ipython = IPython.frontend.terminal.ipapp:launch_new_instance',
'pycolor = IPython.utils.PyColorize:main',
'ipcontroller = IPython.parallel.apps.ipcontrollerapp:launch_new_instance',
@@ -279,6 +279,10 @@ def find_scripts(entry_points=False):
'iptest = IPython.testing.iptest:main',
'irunner = IPython.lib.irunner:main'
]
+ gui_scripts = [
+ 'ipython-qtconsole = IPython.frontend.qt.console.ipythonqt:main',
+ ]
+ scripts = dict(console_scripts=console_scripts, gui_scripts=gui_scripts)
else:
parallel_scripts = pjoin('IPython','parallel','scripts')
main_scripts = pjoin('IPython','scripts')
@@ -288,32 +292,13 @@ def find_scripts(entry_points=False):
pjoin(parallel_scripts, 'ipcluster'),
pjoin(parallel_scripts, 'iplogger'),
pjoin(main_scripts, 'ipython'),
+ pjoin(main_scripts, 'ipython-qtconsole'),
pjoin(main_scripts, 'pycolor'),
pjoin(main_scripts, 'irunner'),
pjoin(main_scripts, 'iptest')
]
return scripts
-def find_gui_scripts(entry_points=False):
- """Find IPython's GUI scripts.
-
- if entry_points is True:
- return setuptools entry_point-style definitions
- else:
- return file paths of plain scripts [default]
- """
- if entry_points:
- scripts = [
- 'ipython-qtconsole = IPython.frontend.qt.console.ipythonqt:main',
- ]
- else:
- parallel_scripts = pjoin('IPython','parallel','scripts')
- main_scripts = pjoin('IPython','scripts')
- scripts = [
- pjoin(main_scripts, 'ipython-qtconsole'),
- ]
- return scripts
-
#---------------------------------------------------------------------------
# Verify all dependencies
#---------------------------------------------------------------------------

0 comments on commit df41710

Please sign in to comment.