You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For example, you can work on a project which requires Django 1.3 while also
230
+
maintaining a project which requires Django 1.0.
324
231
325
-
This will prevent your virtualenvs from relying on your (global) site packages
326
-
directory, so that they are completely separate.
327
-
[Note: This is the default behavior for ``virtualenv`` 1.7 and later]
232
+
To start using and see more information: `Virtual Environments <http://github.com/kennethreitz/python-guide/blob/master/docs/dev/virtualenvs.rst>`_ docs.
Copy file name to clipboardExpand all lines: docs/starting/install/linux.rst
+9-32Lines changed: 9 additions & 32 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -45,41 +45,18 @@ To install pip, simply open a command prompt and run
45
45
$ easy_install pip
46
46
47
47
48
-
Virtualenv
49
-
----------
48
+
Virtual Environments
49
+
--------------------
50
50
51
-
After Setuptools & Pip, the next development tool that you should install is
52
-
`virtualenv <http://pypi.python.org/pypi/virtualenv/>`_. Use pip
51
+
A Virtual Environment is a tool to keep the dependencies required by different projects
52
+
in separate places, by creating virtual Python environments for them. It solves the
53
+
"Project X depends on version 1.x but, Project Y needs 4.x" dilemma, and keeps
54
+
your global site-packages directory clean and manageable.
53
55
54
-
.. code-block:: console
55
-
56
-
$ pip install virtualenv
57
-
58
-
The virtualenv kit provides the ability to create virtual Python environments
59
-
that do not interfere with either each other, or the main Python installation.
60
-
If you install virtualenv before you begin coding then you can get into the
61
-
habit of using it to create completely clean Python environments for each
62
-
project. This is particularly important for Web development, where each
63
-
framework and application will have many dependencies.
64
-
65
-
To set up a new Python environment, change the working directory to where ever
66
-
you want to store the environment, and run the virtualenv utility in your
67
-
project's directory
68
-
69
-
.. code-block:: console
70
-
71
-
$ virtualenv venv
72
-
73
-
To use an environment, run ``source venv/bin/activate``. Your command prompt
74
-
will change to show the active environment. Once you have finished working in
75
-
the current virtual environment, run ``deactivate`` to restore your settings
76
-
to normal.
56
+
For example, you can work on a project which requires Django 1.3 while also
57
+
maintaining a project which requires Django 1.0.
77
58
78
-
Each new environment automatically includes a copy of ``pip``, so that you can
79
-
setup the third-party libraries and tools that you want to use in that
80
-
environment. Put your own code within a subdirectory of the environment,
81
-
however you wish. When you no longer need a particular environment, simply
82
-
copy your code out of it, and then delete the main directory for the environment.
59
+
To start using and see more information: `Virtual Environments <http://github.com/kennethreitz/python-guide/blob/master/docs/dev/virtualenvs.rst>`_ docs.
Copy file name to clipboardExpand all lines: docs/starting/install/osx.rst
+9-34Lines changed: 9 additions & 34 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -77,44 +77,19 @@ that is recommended over ``easy_install``. It is superior to ``easy_install`` in
77
77
and is actively maintained.
78
78
79
79
80
-
Virtualenv
81
-
----------
80
+
Virtual Environments
81
+
--------------------
82
82
83
-
After Setuptools & Pip, the next development tool that you should install is
84
-
`virtualenv <http://pypi.python.org/pypi/virtualenv/>`_. Use pip
83
+
A Virtual Environment is a tool to keep the dependencies required by different projects
84
+
in separate places, by creating virtual Python environments for them. It solves the
85
+
"Project X depends on version 1.x but, Project Y needs 4.x" dilemma, and keeps
86
+
your global site-packages directory clean and manageable.
85
87
86
-
.. code-block:: console
87
-
88
-
$ pip install virtualenv
89
-
90
-
The virtualenv kit provides the ability to create virtual Python environments
91
-
that do not interfere with either each other, or the main Python installation.
92
-
If you install virtualenv before you begin coding then you can get into the
93
-
habit of using it to create completely clean Python environments for each
94
-
project. This is particularly important for Web development, where each
95
-
framework and application will have many dependencies.
96
-
97
-
To set up a new Python environment, move into the directory where you would
98
-
like to store the environment, and use the ``virtualenv`` utility to create
99
-
the new environment.
100
-
101
-
.. code-block:: console
102
-
103
-
$ virtualenv venv
104
-
105
-
To use an environment, run ``source venv/bin/activate``. Your command prompt
106
-
will change to show the active environment. Once you have finished working in
107
-
the current virtual environment, run ``deactivate`` to restore your settings
108
-
to normal.
88
+
For example, you can work on a project which requires Django 1.3 while also
89
+
maintaining a project which requires Django 1.0.
109
90
110
-
Each new environment automatically includes a copy of ``pip``, so that you can
111
-
setup the third-party libraries and tools that you want to use in that
112
-
environment. Put your own code within a subdirectory of the environment,
113
-
however you wish. When you no longer need a particular environment, simply
114
-
copy your code out of it, and then delete the main directory for the environment.
91
+
To start using and see more information: `Virtual Environments <http://github.com/kennethreitz/python-guide/blob/master/docs/dev/virtualenvs.rst>`_ docs.
115
92
116
-
A useful set of extensions to virtualenv is available in virtualenvwrapper,
117
-
`RTFD <http://virtualenvwrapper.readthedocs.org/en/latest/>`_ to find out more.
After Setuptools & Pip, the next development tool that you should install is
73
-
`virtualenv <http://pypi.python.org/pypi/virtualenv/>`_. Use pip
72
+
A Virtual Environment is a tool to keep the dependencies required by different projects
73
+
in separate places, by creating virtual Python environments for them. It solves the
74
+
"Project X depends on version 1.x but, Project Y needs 4.x" dilemma, and keeps
75
+
your global site-packages directory clean and manageable.
74
76
75
-
.. code-block:: console
76
-
77
-
> pip install virtualenv
78
-
79
-
The virtualenv kit provides the ability to create virtual Python environments
80
-
that do not interfere with either each other, or the main Python installation.
81
-
If you install virtualenv before you begin coding then you can get into the
82
-
habit of using it to create completely clean Python environments for each
83
-
project. This is particularly important for Web development, where each
84
-
framework and application will have many dependencies.
85
-
86
-
87
-
To set up a new Python environment, change the working directory to wherever
88
-
you want to store the environment, and run the virtualenv utility in your
89
-
project's directory
90
-
91
-
.. code-block:: console
92
-
93
-
> virtualenv venv
94
-
95
-
To use an environment, run the :file:`activate.bat` batch file in the :file:`Scripts`
96
-
subdirectory of that environment. Your command prompt will change to show the
97
-
active environment. Once you have finished working in the current virtual
98
-
environment, run the :file:`deactivate.bat` batch file to restore your settings to
99
-
normal.
100
-
101
-
Each new environment automatically includes a copy of ``pip`` in the
102
-
:file:`Scripts` subdirectory, so that you can setup the third-party libraries and
103
-
tools that you want to use in that environment. Put your own code within a
104
-
subdirectory of the environment, however you wish. When you no longer need a
105
-
particular environment, simply copy your code out of it, and then delete the
106
-
main directory for the environment.
77
+
For example, you can work on a project which requires Django 1.3 while also
78
+
maintaining a project which requires Django 1.0.
107
79
80
+
To start using and see more information: `Virtual Environments <http://github.com/kennethreitz/python-guide/blob/master/docs/dev/virtualenvs.rst>`_ docs.
0 commit comments