Last active
February 19, 2016 02:12
-
-
Save gwax/bc31dab140f257bbe8a7 to your computer and use it in GitHub Desktop.
Upgrade all the things!
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Upgrade applications on system | |
brew update | |
brew upgrade --all | |
# Install latest python versions | |
pyenv install 2.7.11 | |
pyenv install 3.5.1 | |
# Make sure pip is up to date in new python versions | |
PYENV_VERSION=2.7.11 pip2 install -U pip | |
PYENV_VERSION=3.5.1 pip3 install -U pip | |
# Copy requirements | |
pip2 freeze --local | grep -v '^\-e' | cut -d = -f 1 | PYENV_VERSION=2.7.11 xargs pip2 install -U | |
pip3 freeze --local | grep -v '^\-e' | cut -d = -f 1 | PYENV_VERSION=3.5.1 xargs pip3 install -U | |
# Switch global versions to latest | |
pyenv global 2.7.11 3.5.1 | |
# Update all packages | |
pip2 freeze --local | grep -v '^\-e' | cut -d = -f 1 | xargs pip2 install -U | |
pip3 freeze --local | grep -v '^\-e' | cut -d = -f 1 | xargs pip3 install -U |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment