mirror of
https://github.com/kennethreitz/python-guide.git
synced 2026-06-05 23:00:18 +00:00
Mark up environment variables
This commit is contained in:
@@ -46,7 +46,7 @@ simply run
|
|||||||
The script will explain what changes it will make and prompt you before the
|
The script will explain what changes it will make and prompt you before the
|
||||||
installation begins.
|
installation begins.
|
||||||
Once you've installed Homebrew, insert the Homebrew directory at the top
|
Once you've installed Homebrew, insert the Homebrew directory at the top
|
||||||
of your ``PATH`` environment variable. You can do this by adding the following
|
of your :envvar:`PATH` environment variable. You can do this by adding the following
|
||||||
line at the bottom of your :file:`~/.bashrc` file
|
line at the bottom of your :file:`~/.bashrc` file
|
||||||
|
|
||||||
.. code-block:: console
|
.. code-block:: console
|
||||||
@@ -60,7 +60,7 @@ Now, we can install Python 2.7:
|
|||||||
$ brew install python
|
$ brew install python
|
||||||
|
|
||||||
This will take a minute or two. Once that's complete, you'll have to add the
|
This will take a minute or two. Once that's complete, you'll have to add the
|
||||||
new Python scripts directory to your ``PATH``
|
new Python scripts directory to your :envvar:`PATH`
|
||||||
|
|
||||||
.. code-block:: console
|
.. code-block:: console
|
||||||
|
|
||||||
|
|||||||
@@ -17,13 +17,13 @@ e.g. Python version 2.7 will install at :file:`C:\Python27\`, so that you can
|
|||||||
have multiple versions of Python on the
|
have multiple versions of Python on the
|
||||||
same system without conflicts. Of course, only one interpreter can be the
|
same system without conflicts. Of course, only one interpreter can be the
|
||||||
default application for Python file types. It also does not automatically
|
default application for Python file types. It also does not automatically
|
||||||
modify the ``PATH`` environment variable, so that you always have control over
|
modify the :envvar:`PATH` environment variable, so that you always have control over
|
||||||
which copy of Python is run.
|
which copy of Python is run.
|
||||||
|
|
||||||
Typing the full path name for a Python interpreter each time quickly gets
|
Typing the full path name for a Python interpreter each time quickly gets
|
||||||
tedious, so add the directories for your default Python version to the PATH.
|
tedious, so add the directories for your default Python version to the :envvar:`PATH`.
|
||||||
Assuming that your Python installation is in :file:`C:\Python27\`, add this to your
|
Assuming that your Python installation is in :file:`C:\Python27\`, add this to your
|
||||||
PATH:
|
:envvar:`PATH`:
|
||||||
|
|
||||||
.. code-block:: console
|
.. code-block:: console
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user