Giter Site home page Giter Site logo

pyenv-installer's Introduction

pyenv installer

This tool installs pyenv and friends. It is inspired by rbenv-installer.

Prerequisites

In general, compiling your own Python interpreter requires the installation of the appropriate libraries and packages. The installation wiki provides a list of these for common operating systems.

Installation / Update / Uninstallation

Once prerequisites have been installed correctly:

Install:

$ curl https://pyenv.run | bash

pyenv.run redirects to the install script in this repository and the invocation above is equivalent to:

$ curl -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash

Restart your shell so the path changes take effect:

$ exec $SHELL

You can now begin using pyenv.

If you need, export USE_GIT_URI to use git:// instead of https:// for git clone.

Update:

$ pyenv update

Uninstall:

pyenv is installed within $PYENV_ROOT (default: ~/.pyenv). To uninstall, just remove it:

$ rm -fr ~/.pyenv

then remove these three lines from .bashrc:

export PATH="$HOME/.pyenv/bin:$PATH"
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"

and finally, restart your shell:

$ exec $SHELL

Using pyenv-installer on Travis CI

Travis itself uses pyenv and therefore PYENV_ROOT is set already. To make it work anyway the installation for pyenv-installer needs to look like this:

[...]
- unset PYENV_ROOT
- curl -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash
- export PATH="$HOME/.pyenv/bin:$PATH"
- pyenv install 3.5.2

Development and testing

The project on github contains a setup for vagrant to test the installer inside a vagrant managed virtual image.

If you don't know vagrant yet: just install the latest package, open a shell in this project directory and say

$ vagrant up
$ vagrant ssh

Now you are inside the vagrant container and your prompt should like something like vagrant@vagrant-ubuntu-trusty-64:~$

The project (this repository) is mapped into the vagrant image at /vagrant

$ cd /vagrant
$ python setup.py install
$ echo 'export PATH="$HOME/.pyenv/bin:$PATH"' >> ~/.bashrc
$ echo 'eval "$(pyenv init -)"' >> ~/.bashrc
$ echo 'eval "$(pyenv virtualenv-init -)"' >> ~/.bashrc
$ source ~/.bashrc

Pyenv should be installed and responding now.

Version History

20190111

  • Remove experimental PyPi support and replace with a dummy package.

20150113

  • Initial release on PyPi.

20130601

  • Initial public release.

License

MIT - see License file.

pyenv-installer's People

Contributors

alanyee avatar charlesreid1 avatar fgimian avatar gvoysey avatar jaycenhorton avatar jkwill87 avatar joshfriend avatar jvtrigueros avatar lsflling avatar luzfcb avatar mnencia avatar obestwalter avatar peterdavehello avatar proinsias avatar sean-smith avatar sethwoodworth avatar shajiquan avatar shubhodeep9 avatar tronicum avatar voronind avatar wjv avatar yuvipanda avatar yyuu avatar zevaverbach avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.