Python Road--python Environment installation

Source: Internet
Author: User
Tags virtual environment virtualenv

Https://github.com/yyuu/pyenv-installer


Installing Pyenv

1. install git ' yum-y install git '

2. install pyenv ' curl-l '

Curl-l Https://raw.githubusercontent.com/yyuu/pyenv-installer/master/bin/pyenv-installer | Bash

3. Configure the environment variables to add the following in ' ~/.bash_profile '

"' Bash

Export path= "~/.pyenv/bin: $PATH"

Eval "$ (pyenv init-)"

Eval "$ (pyenv virtualenv-init-)"

```

Install Python

1. Install the Build tool ' yum-y install gcc make patch '

2. Install dependent Environment ' yum-y install zlib-devel gdbm-devel openssl-devel sqlite-devel bzip2-devel readline-devel '

3. install python 3.5.2 ' pyen install 3.5.2 '

Using pyenv

Local command

The local command toggles the Python version of the current directory and its subdirectories by deleting '. Python-version ' to restore the default Python version

Global command

Global command Toggles the default Python version

* * Never use global command * *

virtualenv command

Create a virtual Environment ' pyenv virtualenv $bash _version $name '

Uninstall command

Uninstalling a version, including a virtual environment


Python Road--python Environment installation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.