Skip to content

Commit 39f6fa7

Browse files
committed
Move the Windows doc about venv with pip into a separate code block
Relevant issue pandas-dev#29112
1 parent 7aaf270 commit 39f6fa7

File tree

1 file changed

+25
-7
lines changed

1 file changed

+25
-7
lines changed

doc/source/development/contributing.rst

+25-7
Original file line numberDiff line numberDiff line change
@@ -238,21 +238,16 @@ Creating a Python environment (pip)
238238
If you aren't using conda for your development environment, follow these instructions.
239239
You'll need to have at least python3.5 installed on your system.
240240

241+
**Unix**/**Mac OS**
242+
241243
.. code-block:: none
242244
243245
# Create a virtual environment
244246
# Use an ENV_DIR of your choice. We'll use ~/virtualenvs/pandas-dev
245247
# Any parent directories should already exist
246-
# If you are using Windows and command prompt, replace ~ (the tilde sign)
247-
# with %userprofile%
248248
python3 -m venv ~/virtualenvs/pandas-dev
249249
250250
# Activate the virtualenv
251-
# If you are using Windows, you can find the activation scripts under
252-
# ~\virtualenvs\pandas-dev\scripts
253-
# Please refer to the official user guide at
254-
# https://virtualenv.pypa.io/en/stable/userguide/#activate-script
255-
# about how to activate your virtual environment under Windows
256251
. ~/virtualenvs/pandas-dev/bin/activate
257252
258253
# Install the build dependencies
@@ -262,6 +257,29 @@ You'll need to have at least python3.5 installed on your system.
262257
python setup.py build_ext --inplace -j 4
263258
python -m pip install -e . --no-build-isolation
264259
260+
**Windows**
261+
262+
Below is a brief overview on how to set-up a virtual environment with Powershell
263+
under Windows. For details please refer to the \
264+
`official virtualenv user guide <https://virtualenv.pypa.io/en/stable/userguide/#activate-script>`__
265+
266+
.. code-block:: none
267+
268+
# Create a virtual environment
269+
# Use an ENV_DIR of your choice. We'll use ~\virtualenvs\pandas-dev
270+
# Any parent directories should already exist
271+
python -m venv ~\virtualenvs\pandas-dev
272+
273+
# Activate the virtualenv
274+
~\virtualenvs\pandas-dev\Scripts\Activate.ps1
275+
276+
# Install the build dependencies
277+
python -m pip install -r requirements-dev.txt
278+
279+
# Build and install pandas
280+
python setup.py build_ext --inplace -j 4
281+
python -m pip install -e . --no-build-isolation
282+
265283
Creating a branch
266284
-----------------
267285

0 commit comments

Comments
 (0)