Debian Codegraph @

docs/source/install/install.rst

raw
1 .. _install:
2
3 Installing IPython
4 ==================
5
6
7 IPython requires Python ≥ 3.11.
8
9
10 Quick Install
11 -------------
12
13 With ``pip`` already installed :
14
15 .. code-block:: bash
16
17 $ pip install ipython
18
19 This installs IPython as well as its dependencies.
20
21 If you want to use IPython with notebooks or the Qt console, you should also
22 install Jupyter ``pip install jupyter``.
23
24
25
26 Overview
27 --------
28
29 This document describes in detail the steps required to install IPython. For a
30 few quick ways to get started with package managers or full Python
31 distributions, see `the install page <https://ipython.org/install.html>`_ of the
32 IPython website.
33
34 Please let us know if you have problems installing IPython or any of its
35 dependencies.
36
37 IPython and most dependencies should be installed via :command:`pip`.
38 In many scenarios, this is the simplest method of installing Python packages.
39 More information about :mod:`pip` can be found on
40 `its PyPI page <https://pip.pypa.io>`__.
41
42
43 More general information about installing Python packages can be found in
44 :external+python:doc:`Python's documentation <installing/index>`.
45
46 .. _dependencies:
47
48 Dependencies
49 ~~~~~~~~~~~~
50
51 IPython relies on a number of other Python packages. Installing using a package
52 manager like pip or conda will ensure the necessary packages are installed.
53 Manual installation without dependencies is possible, but not recommended.
54 The dependencies can be viewed with package manager commands,
55 such as :command:`pip show ipython` or :command:`conda info ipython`.
56
57
58 Installing IPython itself
59 ~~~~~~~~~~~~~~~~~~~~~~~~~
60
61 IPython requires several dependencies to work correctly, it is not recommended
62 to install IPython and all its dependencies manually as this can be quite long
63 and troublesome. You should use the python package manager ``pip``.
64
65 Installation using pip
66 ~~~~~~~~~~~~~~~~~~~~~~
67
68 Make sure you have the latest version of :mod:`pip` (the Python package
69 manager) installed. If you do not, head to `Pip documentation
70 <https://pip.pypa.io/en/stable/installing/>`_ and install :mod:`pip` first.
71
72 The quickest way to get up and running with IPython is to install it with pip:
73
74 .. code-block:: bash
75
76 $ pip install ipython
77
78 That's it.
79
80
81 Optional: Command-line completion
82 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
83
84 IPython supports command-line completion via the ``argcomplete`` package.
85 To enable tab completion for IPython and other Python programs that support
86 argcomplete, install IPython with the ``terminal`` extra:
87
88 .. code-block:: bash
89
90 $ pip install ipython[all]
91 $ activate-global-python-argcomplete
92
93 Alternatively, you can install argcomplete separately:
94
95 .. code-block:: bash
96
97 $ pip install argcomplete
98 $ activate-global-python-argcomplete
99
100 This will enable shell completion for all Python programs that support argcomplete,
101 including IPython. Note that you may need to restart your shell for the changes
102 to take effect.
103
104 For more information, see the `argcomplete documentation <https://github.com/kislyuk/argcomplete>`_.
105
106
107 .. _devinstall:
108
109 Installing the development version
110 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
111
112 It is also possible to install the development version of IPython from our
113 `Git <https://git-scm.com/>`_ source code repository. To do this you will
114 need to have Git installed on your system.
115
116
117 Then do:
118
119 .. code-block:: bash
120
121 $ git clone https://github.com/ipython/ipython.git
122 $ cd ipython
123 $ pip install -e '.[test]'
124
125 The :command:`pip install -e .` command allows users and developers to follow
126 the development branch as it changes by creating links in the right places and
127 installing the command line scripts to the appropriate locations.
128
129 Then, if you want to update your IPython at any time, do:
130
131 .. code-block:: bash
132
133 $ git pull
134
135 If the dependencies or entrypoints have changed, you may have to run
136
137 .. code-block:: bash
138
139 $ pip install -e .
140
141 again, but this is infrequent.