##// END OF EJS Templates
Merge pull request #5450 from minrk/no-codename...
Thomas Kluyver -
r16047:536b1842 merge
parent child Browse files
Show More
@@ -1,148 +1,149 b''
1 # -*- coding: utf-8 -*-
1 # -*- coding: utf-8 -*-
2 """Release data for the IPython project."""
2 """Release data for the IPython project."""
3
3
4 #-----------------------------------------------------------------------------
4 #-----------------------------------------------------------------------------
5 # Copyright (c) 2008, IPython Development Team.
5 # Copyright (c) 2008, IPython Development Team.
6 # Copyright (c) 2001, Fernando Perez <fernando.perez@colorado.edu>
6 # Copyright (c) 2001, Fernando Perez <fernando.perez@colorado.edu>
7 # Copyright (c) 2001, Janko Hauser <jhauser@zscout.de>
7 # Copyright (c) 2001, Janko Hauser <jhauser@zscout.de>
8 # Copyright (c) 2001, Nathaniel Gray <n8gray@caltech.edu>
8 # Copyright (c) 2001, Nathaniel Gray <n8gray@caltech.edu>
9 #
9 #
10 # Distributed under the terms of the Modified BSD License.
10 # Distributed under the terms of the Modified BSD License.
11 #
11 #
12 # The full license is in the file COPYING.txt, distributed with this software.
12 # The full license is in the file COPYING.txt, distributed with this software.
13 #-----------------------------------------------------------------------------
13 #-----------------------------------------------------------------------------
14
14
15 # Name of the package for release purposes. This is the name which labels
15 # Name of the package for release purposes. This is the name which labels
16 # the tarballs and RPMs made by distutils, so it's best to lowercase it.
16 # the tarballs and RPMs made by distutils, so it's best to lowercase it.
17 name = 'ipython'
17 name = 'ipython'
18
18
19 # IPython version information. An empty _version_extra corresponds to a full
19 # IPython version information. An empty _version_extra corresponds to a full
20 # release. 'dev' as a _version_extra string means this is a development
20 # release. 'dev' as a _version_extra string means this is a development
21 # version
21 # version
22 _version_major = 2
22 _version_major = 2
23 _version_minor = 0
23 _version_minor = 0
24 _version_patch = 0
24 _version_patch = 0
25 _version_extra = 'dev'
25 _version_extra = 'dev'
26 # _version_extra = 'rc1'
26 # _version_extra = 'rc1'
27 # _version_extra = '' # Uncomment this for full releases
27 # _version_extra = '' # Uncomment this for full releases
28
28
29 codename = 'Work in Progress'
29 # release.codename is deprecated in 2.0, will be removed in 3.0
30 codename = ''
30
31
31 # Construct full version string from these.
32 # Construct full version string from these.
32 _ver = [_version_major, _version_minor, _version_patch]
33 _ver = [_version_major, _version_minor, _version_patch]
33
34
34 __version__ = '.'.join(map(str, _ver))
35 __version__ = '.'.join(map(str, _ver))
35 if _version_extra:
36 if _version_extra:
36 __version__ = __version__ + '-' + _version_extra
37 __version__ = __version__ + '-' + _version_extra
37
38
38 version = __version__ # backwards compatibility name
39 version = __version__ # backwards compatibility name
39 version_info = (_version_major, _version_minor, _version_patch, _version_extra)
40 version_info = (_version_major, _version_minor, _version_patch, _version_extra)
40
41
41 # Change this when incrementing the kernel protocol version
42 # Change this when incrementing the kernel protocol version
42 kernel_protocol_version_info = (4, 1)
43 kernel_protocol_version_info = (4, 1)
43
44
44 description = "IPython: Productive Interactive Computing"
45 description = "IPython: Productive Interactive Computing"
45
46
46 long_description = \
47 long_description = \
47 """
48 """
48 IPython provides a rich toolkit to help you make the most out of using Python
49 IPython provides a rich toolkit to help you make the most out of using Python
49 interactively. Its main components are:
50 interactively. Its main components are:
50
51
51 * Powerful interactive Python shells (terminal- and Qt-based).
52 * Powerful interactive Python shells (terminal- and Qt-based).
52 * A web-based interactive notebook environment with all shell features plus
53 * A web-based interactive notebook environment with all shell features plus
53 support for embedded figures, animations and rich media.
54 support for embedded figures, animations and rich media.
54 * Support for interactive data visualization and use of GUI toolkits.
55 * Support for interactive data visualization and use of GUI toolkits.
55 * Flexible, embeddable interpreters to load into your own projects.
56 * Flexible, embeddable interpreters to load into your own projects.
56 * A high-performance library for high level and interactive parallel computing
57 * A high-performance library for high level and interactive parallel computing
57 that works in multicore systems, clusters, supercomputing and cloud scenarios.
58 that works in multicore systems, clusters, supercomputing and cloud scenarios.
58
59
59 The enhanced interactive Python shells have the following main features:
60 The enhanced interactive Python shells have the following main features:
60
61
61 * Comprehensive object introspection.
62 * Comprehensive object introspection.
62
63
63 * Input history, persistent across sessions.
64 * Input history, persistent across sessions.
64
65
65 * Caching of output results during a session with automatically generated
66 * Caching of output results during a session with automatically generated
66 references.
67 references.
67
68
68 * Extensible tab completion, with support by default for completion of python
69 * Extensible tab completion, with support by default for completion of python
69 variables and keywords, filenames and function keywords.
70 variables and keywords, filenames and function keywords.
70
71
71 * Extensible system of 'magic' commands for controlling the environment and
72 * Extensible system of 'magic' commands for controlling the environment and
72 performing many tasks related either to IPython or the operating system.
73 performing many tasks related either to IPython or the operating system.
73
74
74 * A rich configuration system with easy switching between different setups
75 * A rich configuration system with easy switching between different setups
75 (simpler than changing $PYTHONSTARTUP environment variables every time).
76 (simpler than changing $PYTHONSTARTUP environment variables every time).
76
77
77 * Session logging and reloading.
78 * Session logging and reloading.
78
79
79 * Extensible syntax processing for special purpose situations.
80 * Extensible syntax processing for special purpose situations.
80
81
81 * Access to the system shell with user-extensible alias system.
82 * Access to the system shell with user-extensible alias system.
82
83
83 * Easily embeddable in other Python programs and GUIs.
84 * Easily embeddable in other Python programs and GUIs.
84
85
85 * Integrated access to the pdb debugger and the Python profiler.
86 * Integrated access to the pdb debugger and the Python profiler.
86
87
87 The parallel computing architecture has the following main features:
88 The parallel computing architecture has the following main features:
88
89
89 * Quickly parallelize Python code from an interactive Python/IPython session.
90 * Quickly parallelize Python code from an interactive Python/IPython session.
90
91
91 * A flexible and dynamic process model that be deployed on anything from
92 * A flexible and dynamic process model that be deployed on anything from
92 multicore workstations to supercomputers.
93 multicore workstations to supercomputers.
93
94
94 * An architecture that supports many different styles of parallelism, from
95 * An architecture that supports many different styles of parallelism, from
95 message passing to task farming.
96 message passing to task farming.
96
97
97 * Both blocking and fully asynchronous interfaces.
98 * Both blocking and fully asynchronous interfaces.
98
99
99 * High level APIs that enable many things to be parallelized in a few lines
100 * High level APIs that enable many things to be parallelized in a few lines
100 of code.
101 of code.
101
102
102 * Share live parallel jobs with other users securely.
103 * Share live parallel jobs with other users securely.
103
104
104 * Dynamically load balanced task farming system.
105 * Dynamically load balanced task farming system.
105
106
106 * Robust error handling in parallel code.
107 * Robust error handling in parallel code.
107
108
108 The latest development version is always available from IPython's `GitHub
109 The latest development version is always available from IPython's `GitHub
109 site <http://github.com/ipython>`_.
110 site <http://github.com/ipython>`_.
110 """
111 """
111
112
112 license = 'BSD'
113 license = 'BSD'
113
114
114 authors = {'Fernando' : ('Fernando Perez','fperez.net@gmail.com'),
115 authors = {'Fernando' : ('Fernando Perez','fperez.net@gmail.com'),
115 'Janko' : ('Janko Hauser','jhauser@zscout.de'),
116 'Janko' : ('Janko Hauser','jhauser@zscout.de'),
116 'Nathan' : ('Nathaniel Gray','n8gray@caltech.edu'),
117 'Nathan' : ('Nathaniel Gray','n8gray@caltech.edu'),
117 'Ville' : ('Ville Vainio','vivainio@gmail.com'),
118 'Ville' : ('Ville Vainio','vivainio@gmail.com'),
118 'Brian' : ('Brian E Granger', 'ellisonbg@gmail.com'),
119 'Brian' : ('Brian E Granger', 'ellisonbg@gmail.com'),
119 'Min' : ('Min Ragan-Kelley', 'benjaminrk@gmail.com'),
120 'Min' : ('Min Ragan-Kelley', 'benjaminrk@gmail.com'),
120 'Thomas' : ('Thomas A. Kluyver', 'takowl@gmail.com'),
121 'Thomas' : ('Thomas A. Kluyver', 'takowl@gmail.com'),
121 'Jorgen' : ('Jorgen Stenarson', 'jorgen.stenarson@bostream.nu'),
122 'Jorgen' : ('Jorgen Stenarson', 'jorgen.stenarson@bostream.nu'),
122 'Matthias' : ('Matthias Bussonnier', 'bussonniermatthias@gmail.com'),
123 'Matthias' : ('Matthias Bussonnier', 'bussonniermatthias@gmail.com'),
123 }
124 }
124
125
125 author = 'The IPython Development Team'
126 author = 'The IPython Development Team'
126
127
127 author_email = 'ipython-dev@scipy.org'
128 author_email = 'ipython-dev@scipy.org'
128
129
129 url = 'http://ipython.org'
130 url = 'http://ipython.org'
130
131
131 download_url = 'https://github.com/ipython/ipython/downloads'
132 download_url = 'https://github.com/ipython/ipython/downloads'
132
133
133 platforms = ['Linux','Mac OSX','Windows XP/Vista/7/8']
134 platforms = ['Linux','Mac OSX','Windows XP/Vista/7/8']
134
135
135 keywords = ['Interactive','Interpreter','Shell','Parallel','Distributed',
136 keywords = ['Interactive','Interpreter','Shell','Parallel','Distributed',
136 'Web-based computing', 'Qt console', 'Embedding']
137 'Web-based computing', 'Qt console', 'Embedding']
137
138
138 classifiers = [
139 classifiers = [
139 'Intended Audience :: Developers',
140 'Intended Audience :: Developers',
140 'Intended Audience :: Science/Research',
141 'Intended Audience :: Science/Research',
141 'License :: OSI Approved :: BSD License',
142 'License :: OSI Approved :: BSD License',
142 'Programming Language :: Python',
143 'Programming Language :: Python',
143 'Programming Language :: Python :: 2',
144 'Programming Language :: Python :: 2',
144 'Programming Language :: Python :: 2.7',
145 'Programming Language :: Python :: 2.7',
145 'Programming Language :: Python :: 3',
146 'Programming Language :: Python :: 3',
146 'Topic :: System :: Distributed Computing',
147 'Topic :: System :: Distributed Computing',
147 'Topic :: System :: Shells'
148 'Topic :: System :: Shells'
148 ]
149 ]
@@ -1,171 +1,170 b''
1 # encoding: utf-8
1 # encoding: utf-8
2 """
2 """
3 Utilities for getting information about IPython and the system it's running in.
3 Utilities for getting information about IPython and the system it's running in.
4 """
4 """
5
5
6 #-----------------------------------------------------------------------------
6 #-----------------------------------------------------------------------------
7 # Copyright (C) 2008-2011 The IPython Development Team
7 # Copyright (C) 2008-2011 The IPython Development Team
8 #
8 #
9 # Distributed under the terms of the BSD License. The full license is in
9 # Distributed under the terms of the BSD License. The full license is in
10 # the file COPYING, distributed as part of this software.
10 # the file COPYING, distributed as part of this software.
11 #-----------------------------------------------------------------------------
11 #-----------------------------------------------------------------------------
12
12
13 #-----------------------------------------------------------------------------
13 #-----------------------------------------------------------------------------
14 # Imports
14 # Imports
15 #-----------------------------------------------------------------------------
15 #-----------------------------------------------------------------------------
16
16
17 import os
17 import os
18 import platform
18 import platform
19 import pprint
19 import pprint
20 import sys
20 import sys
21 import subprocess
21 import subprocess
22
22
23 from IPython.core import release
23 from IPython.core import release
24 from IPython.utils import py3compat, _sysinfo, encoding
24 from IPython.utils import py3compat, _sysinfo, encoding
25
25
26 #-----------------------------------------------------------------------------
26 #-----------------------------------------------------------------------------
27 # Code
27 # Code
28 #-----------------------------------------------------------------------------
28 #-----------------------------------------------------------------------------
29
29
30 def pkg_commit_hash(pkg_path):
30 def pkg_commit_hash(pkg_path):
31 """Get short form of commit hash given directory `pkg_path`
31 """Get short form of commit hash given directory `pkg_path`
32
32
33 We get the commit hash from (in order of preference):
33 We get the commit hash from (in order of preference):
34
34
35 * IPython.utils._sysinfo.commit
35 * IPython.utils._sysinfo.commit
36 * git output, if we are in a git repository
36 * git output, if we are in a git repository
37
37
38 If these fail, we return a not-found placeholder tuple
38 If these fail, we return a not-found placeholder tuple
39
39
40 Parameters
40 Parameters
41 ----------
41 ----------
42 pkg_path : str
42 pkg_path : str
43 directory containing package
43 directory containing package
44 only used for getting commit from active repo
44 only used for getting commit from active repo
45
45
46 Returns
46 Returns
47 -------
47 -------
48 hash_from : str
48 hash_from : str
49 Where we got the hash from - description
49 Where we got the hash from - description
50 hash_str : str
50 hash_str : str
51 short form of hash
51 short form of hash
52 """
52 """
53 # Try and get commit from written commit text file
53 # Try and get commit from written commit text file
54 if _sysinfo.commit:
54 if _sysinfo.commit:
55 return "installation", _sysinfo.commit
55 return "installation", _sysinfo.commit
56
56
57 # maybe we are in a repository
57 # maybe we are in a repository
58 proc = subprocess.Popen('git rev-parse --short HEAD',
58 proc = subprocess.Popen('git rev-parse --short HEAD',
59 stdout=subprocess.PIPE,
59 stdout=subprocess.PIPE,
60 stderr=subprocess.PIPE,
60 stderr=subprocess.PIPE,
61 cwd=pkg_path, shell=True)
61 cwd=pkg_path, shell=True)
62 repo_commit, _ = proc.communicate()
62 repo_commit, _ = proc.communicate()
63 if repo_commit:
63 if repo_commit:
64 return 'repository', repo_commit.strip()
64 return 'repository', repo_commit.strip()
65 return '(none found)', '<not found>'
65 return '(none found)', '<not found>'
66
66
67
67
68 def pkg_info(pkg_path):
68 def pkg_info(pkg_path):
69 """Return dict describing the context of this package
69 """Return dict describing the context of this package
70
70
71 Parameters
71 Parameters
72 ----------
72 ----------
73 pkg_path : str
73 pkg_path : str
74 path containing __init__.py for package
74 path containing __init__.py for package
75
75
76 Returns
76 Returns
77 -------
77 -------
78 context : dict
78 context : dict
79 with named parameters of interest
79 with named parameters of interest
80 """
80 """
81 src, hsh = pkg_commit_hash(pkg_path)
81 src, hsh = pkg_commit_hash(pkg_path)
82 return dict(
82 return dict(
83 ipython_version=release.version,
83 ipython_version=release.version,
84 ipython_path=pkg_path,
84 ipython_path=pkg_path,
85 codename=release.codename,
86 commit_source=src,
85 commit_source=src,
87 commit_hash=hsh,
86 commit_hash=hsh,
88 sys_version=sys.version,
87 sys_version=sys.version,
89 sys_executable=sys.executable,
88 sys_executable=sys.executable,
90 sys_platform=sys.platform,
89 sys_platform=sys.platform,
91 platform=platform.platform(),
90 platform=platform.platform(),
92 os_name=os.name,
91 os_name=os.name,
93 default_encoding=encoding.DEFAULT_ENCODING,
92 default_encoding=encoding.DEFAULT_ENCODING,
94 )
93 )
95
94
96 def get_sys_info():
95 def get_sys_info():
97 """Return useful information about IPython and the system, as a dict."""
96 """Return useful information about IPython and the system, as a dict."""
98 p = os.path
97 p = os.path
99 path = p.dirname(p.abspath(p.join(__file__, '..')))
98 path = p.dirname(p.abspath(p.join(__file__, '..')))
100 return pkg_info(path)
99 return pkg_info(path)
101
100
102 @py3compat.doctest_refactor_print
101 @py3compat.doctest_refactor_print
103 def sys_info():
102 def sys_info():
104 """Return useful information about IPython and the system, as a string.
103 """Return useful information about IPython and the system, as a string.
105
104
106 Examples
105 Examples
107 --------
106 --------
108 ::
107 ::
109
108
110 In [2]: print sys_info()
109 In [2]: print sys_info()
111 {'commit_hash': '144fdae', # random
110 {'commit_hash': '144fdae', # random
112 'commit_source': 'repository',
111 'commit_source': 'repository',
113 'ipython_path': '/home/fperez/usr/lib/python2.6/site-packages/IPython',
112 'ipython_path': '/home/fperez/usr/lib/python2.6/site-packages/IPython',
114 'ipython_version': '0.11.dev',
113 'ipython_version': '0.11.dev',
115 'os_name': 'posix',
114 'os_name': 'posix',
116 'platform': 'Linux-2.6.35-22-generic-i686-with-Ubuntu-10.10-maverick',
115 'platform': 'Linux-2.6.35-22-generic-i686-with-Ubuntu-10.10-maverick',
117 'sys_executable': '/usr/bin/python',
116 'sys_executable': '/usr/bin/python',
118 'sys_platform': 'linux2',
117 'sys_platform': 'linux2',
119 'sys_version': '2.6.6 (r266:84292, Sep 15 2010, 15:52:39) \\n[GCC 4.4.5]'}
118 'sys_version': '2.6.6 (r266:84292, Sep 15 2010, 15:52:39) \\n[GCC 4.4.5]'}
120 """
119 """
121 return pprint.pformat(get_sys_info())
120 return pprint.pformat(get_sys_info())
122
121
123 def _num_cpus_unix():
122 def _num_cpus_unix():
124 """Return the number of active CPUs on a Unix system."""
123 """Return the number of active CPUs on a Unix system."""
125 return os.sysconf("SC_NPROCESSORS_ONLN")
124 return os.sysconf("SC_NPROCESSORS_ONLN")
126
125
127
126
128 def _num_cpus_darwin():
127 def _num_cpus_darwin():
129 """Return the number of active CPUs on a Darwin system."""
128 """Return the number of active CPUs on a Darwin system."""
130 p = subprocess.Popen(['sysctl','-n','hw.ncpu'],stdout=subprocess.PIPE)
129 p = subprocess.Popen(['sysctl','-n','hw.ncpu'],stdout=subprocess.PIPE)
131 return p.stdout.read()
130 return p.stdout.read()
132
131
133
132
134 def _num_cpus_windows():
133 def _num_cpus_windows():
135 """Return the number of active CPUs on a Windows system."""
134 """Return the number of active CPUs on a Windows system."""
136 return os.environ.get("NUMBER_OF_PROCESSORS")
135 return os.environ.get("NUMBER_OF_PROCESSORS")
137
136
138
137
139 def num_cpus():
138 def num_cpus():
140 """Return the effective number of CPUs in the system as an integer.
139 """Return the effective number of CPUs in the system as an integer.
141
140
142 This cross-platform function makes an attempt at finding the total number of
141 This cross-platform function makes an attempt at finding the total number of
143 available CPUs in the system, as returned by various underlying system and
142 available CPUs in the system, as returned by various underlying system and
144 python calls.
143 python calls.
145
144
146 If it can't find a sensible answer, it returns 1 (though an error *may* make
145 If it can't find a sensible answer, it returns 1 (though an error *may* make
147 it return a large positive number that's actually incorrect).
146 it return a large positive number that's actually incorrect).
148 """
147 """
149
148
150 # Many thanks to the Parallel Python project (http://www.parallelpython.com)
149 # Many thanks to the Parallel Python project (http://www.parallelpython.com)
151 # for the names of the keys we needed to look up for this function. This
150 # for the names of the keys we needed to look up for this function. This
152 # code was inspired by their equivalent function.
151 # code was inspired by their equivalent function.
153
152
154 ncpufuncs = {'Linux':_num_cpus_unix,
153 ncpufuncs = {'Linux':_num_cpus_unix,
155 'Darwin':_num_cpus_darwin,
154 'Darwin':_num_cpus_darwin,
156 'Windows':_num_cpus_windows,
155 'Windows':_num_cpus_windows,
157 # On Vista, python < 2.5.2 has a bug and returns 'Microsoft'
156 # On Vista, python < 2.5.2 has a bug and returns 'Microsoft'
158 # See http://bugs.python.org/issue1082 for details.
157 # See http://bugs.python.org/issue1082 for details.
159 'Microsoft':_num_cpus_windows,
158 'Microsoft':_num_cpus_windows,
160 }
159 }
161
160
162 ncpufunc = ncpufuncs.get(platform.system(),
161 ncpufunc = ncpufuncs.get(platform.system(),
163 # default to unix version (Solaris, AIX, etc)
162 # default to unix version (Solaris, AIX, etc)
164 _num_cpus_unix)
163 _num_cpus_unix)
165
164
166 try:
165 try:
167 ncpus = max(1,int(ncpufunc()))
166 ncpus = max(1,int(ncpufunc()))
168 except:
167 except:
169 ncpus = 1
168 ncpus = 1
170 return ncpus
169 return ncpus
171
170
@@ -1,249 +1,248 b''
1 # -*- coding: utf-8 -*-
1 # -*- coding: utf-8 -*-
2 #
2 #
3 # IPython documentation build configuration file.
3 # IPython documentation build configuration file.
4
4
5 # NOTE: This file has been edited manually from the auto-generated one from
5 # NOTE: This file has been edited manually from the auto-generated one from
6 # sphinx. Do NOT delete and re-generate. If any changes from sphinx are
6 # sphinx. Do NOT delete and re-generate. If any changes from sphinx are
7 # needed, generate a scratch one and merge by hand any new fields needed.
7 # needed, generate a scratch one and merge by hand any new fields needed.
8
8
9 #
9 #
10 # This file is execfile()d with the current directory set to its containing dir.
10 # This file is execfile()d with the current directory set to its containing dir.
11 #
11 #
12 # The contents of this file are pickled, so don't put values in the namespace
12 # The contents of this file are pickled, so don't put values in the namespace
13 # that aren't pickleable (module imports are okay, they're removed automatically).
13 # that aren't pickleable (module imports are okay, they're removed automatically).
14 #
14 #
15 # All configuration values have a default value; values that are commented out
15 # All configuration values have a default value; values that are commented out
16 # serve to show the default value.
16 # serve to show the default value.
17
17
18 import sys, os
18 import sys, os
19
19
20 ON_RTD = os.environ.get('READTHEDOCS', None) == 'True'
20 ON_RTD = os.environ.get('READTHEDOCS', None) == 'True'
21
21
22 if ON_RTD:
22 if ON_RTD:
23 # Mock the presence of matplotlib, which we don't have on RTD
23 # Mock the presence of matplotlib, which we don't have on RTD
24 # see
24 # see
25 # http://read-the-docs.readthedocs.org/en/latest/faq.html
25 # http://read-the-docs.readthedocs.org/en/latest/faq.html
26 tags.add('rtd')
26 tags.add('rtd')
27
27
28 # If your extensions are in another directory, add it here. If the directory
28 # If your extensions are in another directory, add it here. If the directory
29 # is relative to the documentation root, use os.path.abspath to make it
29 # is relative to the documentation root, use os.path.abspath to make it
30 # absolute, like shown here.
30 # absolute, like shown here.
31 sys.path.insert(0, os.path.abspath('../sphinxext'))
31 sys.path.insert(0, os.path.abspath('../sphinxext'))
32
32
33 # We load the ipython release info into a dict by explicit execution
33 # We load the ipython release info into a dict by explicit execution
34 iprelease = {}
34 iprelease = {}
35 execfile('../../IPython/core/release.py',iprelease)
35 execfile('../../IPython/core/release.py',iprelease)
36
36
37 # General configuration
37 # General configuration
38 # ---------------------
38 # ---------------------
39
39
40 # Add any Sphinx extension module names here, as strings. They can be extensions
40 # Add any Sphinx extension module names here, as strings. They can be extensions
41 # coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
41 # coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
42 extensions = [
42 extensions = [
43 'matplotlib.sphinxext.mathmpl',
43 'matplotlib.sphinxext.mathmpl',
44 'matplotlib.sphinxext.only_directives',
44 'matplotlib.sphinxext.only_directives',
45 'matplotlib.sphinxext.plot_directive',
45 'matplotlib.sphinxext.plot_directive',
46 'sphinx.ext.autodoc',
46 'sphinx.ext.autodoc',
47 'sphinx.ext.autosummary',
47 'sphinx.ext.autosummary',
48 'sphinx.ext.doctest',
48 'sphinx.ext.doctest',
49 'sphinx.ext.inheritance_diagram',
49 'sphinx.ext.inheritance_diagram',
50 'sphinx.ext.intersphinx',
50 'sphinx.ext.intersphinx',
51 'IPython.sphinxext.ipython_console_highlighting',
51 'IPython.sphinxext.ipython_console_highlighting',
52 'IPython.sphinxext.ipython_directive',
52 'IPython.sphinxext.ipython_directive',
53 'numpydoc', # to preprocess docstrings
53 'numpydoc', # to preprocess docstrings
54 'github', # for easy GitHub links
54 'github', # for easy GitHub links
55 ]
55 ]
56
56
57 if ON_RTD:
57 if ON_RTD:
58 # Remove extensions not currently supported on RTD
58 # Remove extensions not currently supported on RTD
59 extensions.remove('matplotlib.sphinxext.only_directives')
59 extensions.remove('matplotlib.sphinxext.only_directives')
60 extensions.remove('matplotlib.sphinxext.mathmpl')
60 extensions.remove('matplotlib.sphinxext.mathmpl')
61 extensions.remove('matplotlib.sphinxext.plot_directive')
61 extensions.remove('matplotlib.sphinxext.plot_directive')
62 extensions.remove('IPython.sphinxext.ipython_directive')
62 extensions.remove('IPython.sphinxext.ipython_directive')
63 extensions.remove('IPython.sphinxext.ipython_console_highlighting')
63 extensions.remove('IPython.sphinxext.ipython_console_highlighting')
64
64
65 # Add any paths that contain templates here, relative to this directory.
65 # Add any paths that contain templates here, relative to this directory.
66 templates_path = ['_templates']
66 templates_path = ['_templates']
67
67
68 # The suffix of source filenames.
68 # The suffix of source filenames.
69 source_suffix = '.rst'
69 source_suffix = '.rst'
70
70
71 if iprelease['_version_extra']:
71 if iprelease['_version_extra']:
72 rst_prolog = """
72 rst_prolog = """
73 .. note::
73 .. note::
74
74
75 This documentation is for a development version of IPython. There may be
75 This documentation is for a development version of IPython. There may be
76 significant differences from the latest stable release (1.2.1).
76 significant differences from the latest stable release (1.2.1).
77
77
78 """
78 """
79
79
80 # The master toctree document.
80 # The master toctree document.
81 master_doc = 'index'
81 master_doc = 'index'
82
82
83 # General substitutions.
83 # General substitutions.
84 project = 'IPython'
84 project = 'IPython'
85 copyright = '2008, The IPython Development Team'
85 copyright = '2008, The IPython Development Team'
86
86
87 # ghissue config
87 # ghissue config
88 github_project_url = "https://github.com/ipython/ipython"
88 github_project_url = "https://github.com/ipython/ipython"
89
89
90 # numpydoc config
90 # numpydoc config
91 numpydoc_show_class_members = False # Otherwise Sphinx emits thousands of warnings
91 numpydoc_show_class_members = False # Otherwise Sphinx emits thousands of warnings
92 numpydoc_class_members_toctree = False
92 numpydoc_class_members_toctree = False
93
93
94 # The default replacements for |version| and |release|, also used in various
94 # The default replacements for |version| and |release|, also used in various
95 # other places throughout the built documents.
95 # other places throughout the built documents.
96 #
96 #
97 # The full version, including alpha/beta/rc tags.
97 # The full version, including alpha/beta/rc tags.
98 codename = iprelease['codename']
98 release = "%s" % iprelease['version']
99 release = "%s: %s" % (iprelease['version'], codename)
100 # Just the X.Y.Z part, no '-dev'
99 # Just the X.Y.Z part, no '-dev'
101 version = iprelease['version'].split('-', 1)[0]
100 version = iprelease['version'].split('-', 1)[0]
102
101
103
102
104 # There are two options for replacing |today|: either, you set today to some
103 # There are two options for replacing |today|: either, you set today to some
105 # non-false value, then it is used:
104 # non-false value, then it is used:
106 #today = ''
105 #today = ''
107 # Else, today_fmt is used as the format for a strftime call.
106 # Else, today_fmt is used as the format for a strftime call.
108 today_fmt = '%B %d, %Y'
107 today_fmt = '%B %d, %Y'
109
108
110 # List of documents that shouldn't be included in the build.
109 # List of documents that shouldn't be included in the build.
111 #unused_docs = []
110 #unused_docs = []
112
111
113 # List of directories, relative to source directories, that shouldn't be searched
112 # List of directories, relative to source directories, that shouldn't be searched
114 # for source files.
113 # for source files.
115 exclude_dirs = ['attic']
114 exclude_dirs = ['attic']
116
115
117 # If true, '()' will be appended to :func: etc. cross-reference text.
116 # If true, '()' will be appended to :func: etc. cross-reference text.
118 #add_function_parentheses = True
117 #add_function_parentheses = True
119
118
120 # If true, the current module name will be prepended to all description
119 # If true, the current module name will be prepended to all description
121 # unit titles (such as .. function::).
120 # unit titles (such as .. function::).
122 #add_module_names = True
121 #add_module_names = True
123
122
124 # If true, sectionauthor and moduleauthor directives will be shown in the
123 # If true, sectionauthor and moduleauthor directives will be shown in the
125 # output. They are ignored by default.
124 # output. They are ignored by default.
126 #show_authors = False
125 #show_authors = False
127
126
128 # The name of the Pygments (syntax highlighting) style to use.
127 # The name of the Pygments (syntax highlighting) style to use.
129 pygments_style = 'sphinx'
128 pygments_style = 'sphinx'
130
129
131
130
132 # Options for HTML output
131 # Options for HTML output
133 # -----------------------
132 # -----------------------
134
133
135 # The style sheet to use for HTML and HTML Help pages. A file of that name
134 # The style sheet to use for HTML and HTML Help pages. A file of that name
136 # must exist either in Sphinx' static/ path, or in one of the custom paths
135 # must exist either in Sphinx' static/ path, or in one of the custom paths
137 # given in html_static_path.
136 # given in html_static_path.
138 html_style = 'default.css'
137 html_style = 'default.css'
139
138
140 # The name for this set of Sphinx documents. If None, it defaults to
139 # The name for this set of Sphinx documents. If None, it defaults to
141 # "<project> v<release> documentation".
140 # "<project> v<release> documentation".
142 #html_title = None
141 #html_title = None
143
142
144 # The name of an image file (within the static path) to place at the top of
143 # The name of an image file (within the static path) to place at the top of
145 # the sidebar.
144 # the sidebar.
146 #html_logo = None
145 #html_logo = None
147
146
148 # Add any paths that contain custom static files (such as style sheets) here,
147 # Add any paths that contain custom static files (such as style sheets) here,
149 # relative to this directory. They are copied after the builtin static files,
148 # relative to this directory. They are copied after the builtin static files,
150 # so a file named "default.css" will overwrite the builtin "default.css".
149 # so a file named "default.css" will overwrite the builtin "default.css".
151 html_static_path = ['_static']
150 html_static_path = ['_static']
152
151
153 # If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
152 # If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
154 # using the given strftime format.
153 # using the given strftime format.
155 html_last_updated_fmt = '%b %d, %Y'
154 html_last_updated_fmt = '%b %d, %Y'
156
155
157 # If true, SmartyPants will be used to convert quotes and dashes to
156 # If true, SmartyPants will be used to convert quotes and dashes to
158 # typographically correct entities.
157 # typographically correct entities.
159 #html_use_smartypants = True
158 #html_use_smartypants = True
160
159
161 # Custom sidebar templates, maps document names to template names.
160 # Custom sidebar templates, maps document names to template names.
162 #html_sidebars = {}
161 #html_sidebars = {}
163
162
164 # Additional templates that should be rendered to pages, maps page names to
163 # Additional templates that should be rendered to pages, maps page names to
165 # template names.
164 # template names.
166 html_additional_pages = {
165 html_additional_pages = {
167 'interactive/htmlnotebook': 'notebook_redirect.html',
166 'interactive/htmlnotebook': 'notebook_redirect.html',
168 'interactive/notebook': 'notebook_redirect.html',
167 'interactive/notebook': 'notebook_redirect.html',
169 'interactive/nbconvert': 'notebook_redirect.html',
168 'interactive/nbconvert': 'notebook_redirect.html',
170 'interactive/public_server': 'notebook_redirect.html',
169 'interactive/public_server': 'notebook_redirect.html',
171 }
170 }
172
171
173 # If false, no module index is generated.
172 # If false, no module index is generated.
174 #html_use_modindex = True
173 #html_use_modindex = True
175
174
176 # If true, the reST sources are included in the HTML build as _sources/<name>.
175 # If true, the reST sources are included in the HTML build as _sources/<name>.
177 #html_copy_source = True
176 #html_copy_source = True
178
177
179 # If true, an OpenSearch description file will be output, and all pages will
178 # If true, an OpenSearch description file will be output, and all pages will
180 # contain a <link> tag referring to it. The value of this option must be the
179 # contain a <link> tag referring to it. The value of this option must be the
181 # base URL from which the finished HTML is served.
180 # base URL from which the finished HTML is served.
182 #html_use_opensearch = ''
181 #html_use_opensearch = ''
183
182
184 # If nonempty, this is the file name suffix for HTML files (e.g. ".xhtml").
183 # If nonempty, this is the file name suffix for HTML files (e.g. ".xhtml").
185 #html_file_suffix = ''
184 #html_file_suffix = ''
186
185
187 # Output file base name for HTML help builder.
186 # Output file base name for HTML help builder.
188 htmlhelp_basename = 'ipythondoc'
187 htmlhelp_basename = 'ipythondoc'
189
188
190 intersphinx_mapping = {'python': ('http://docs.python.org/2/', None)}
189 intersphinx_mapping = {'python': ('http://docs.python.org/2/', None)}
191
190
192 # Options for LaTeX output
191 # Options for LaTeX output
193 # ------------------------
192 # ------------------------
194
193
195 # The paper size ('letter' or 'a4').
194 # The paper size ('letter' or 'a4').
196 latex_paper_size = 'letter'
195 latex_paper_size = 'letter'
197
196
198 # The font size ('10pt', '11pt' or '12pt').
197 # The font size ('10pt', '11pt' or '12pt').
199 latex_font_size = '11pt'
198 latex_font_size = '11pt'
200
199
201 # Grouping the document tree into LaTeX files. List of tuples
200 # Grouping the document tree into LaTeX files. List of tuples
202 # (source start file, target name, title, author, document class [howto/manual]).
201 # (source start file, target name, title, author, document class [howto/manual]).
203
202
204 latex_documents = [
203 latex_documents = [
205 ('index', 'ipython.tex', 'IPython Documentation',
204 ('index', 'ipython.tex', 'IPython Documentation',
206 ur"""The IPython Development Team""", 'manual', True),
205 ur"""The IPython Development Team""", 'manual', True),
207 ('parallel/winhpc_index', 'winhpc_whitepaper.tex',
206 ('parallel/winhpc_index', 'winhpc_whitepaper.tex',
208 'Using IPython on Windows HPC Server 2008',
207 'Using IPython on Windows HPC Server 2008',
209 ur"Brian E. Granger", 'manual', True)
208 ur"Brian E. Granger", 'manual', True)
210 ]
209 ]
211
210
212 # The name of an image file (relative to this directory) to place at the top of
211 # The name of an image file (relative to this directory) to place at the top of
213 # the title page.
212 # the title page.
214 #latex_logo = None
213 #latex_logo = None
215
214
216 # For "manual" documents, if this is true, then toplevel headings are parts,
215 # For "manual" documents, if this is true, then toplevel headings are parts,
217 # not chapters.
216 # not chapters.
218 #latex_use_parts = False
217 #latex_use_parts = False
219
218
220 # Additional stuff for the LaTeX preamble.
219 # Additional stuff for the LaTeX preamble.
221 #latex_preamble = ''
220 #latex_preamble = ''
222
221
223 # Documents to append as an appendix to all manuals.
222 # Documents to append as an appendix to all manuals.
224 #latex_appendices = []
223 #latex_appendices = []
225
224
226 # If false, no module index is generated.
225 # If false, no module index is generated.
227 latex_use_modindex = True
226 latex_use_modindex = True
228
227
229
228
230 # Options for texinfo output
229 # Options for texinfo output
231 # --------------------------
230 # --------------------------
232
231
233 texinfo_documents = [
232 texinfo_documents = [
234 (master_doc, 'ipython', 'IPython Documentation',
233 (master_doc, 'ipython', 'IPython Documentation',
235 'The IPython Development Team',
234 'The IPython Development Team',
236 'IPython',
235 'IPython',
237 'IPython Documentation',
236 'IPython Documentation',
238 'Programming',
237 'Programming',
239 1),
238 1),
240 ]
239 ]
241
240
242 modindex_common_prefix = ['IPython.']
241 modindex_common_prefix = ['IPython.']
243
242
244
243
245 # Cleanup
244 # Cleanup
246 # -------
245 # -------
247 # delete release info to avoid pickling errors from sphinx
246 # delete release info to avoid pickling errors from sphinx
248
247
249 del iprelease
248 del iprelease
General Comments 0
You need to be logged in to leave comments. Login now