Skip to content

Instantly share code, notes, and snippets.

@charlieparkes
Last active November 20, 2019 12:09
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save charlieparkes/f5490435d20e81672cc7e864fe0e524a to your computer and use it in GitHub Desktop.
Save charlieparkes/f5490435d20e81672cc7e864fe0e524a to your computer and use it in GitHub Desktop.
Setup OSX Development Environment
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew install cask xquartz
brew install \
python3 \
pipenv \
pyenv \
vim \
mosh \
tmux \
ack \
grep \
curl \
wget \
ctop \
htop \
git \
git-lfs \
nmap \
arping \
rdesktop \
go \
cookiecutter \
flake8 \
yarn \
mysql \
postgresql \
node \
kubernetes-cli
# pyenv-virtualenv \ # I'm not using these atm, but they're
# pyenv-virtualenvwrapper \ # supposed to make virtualenvs better with pyenv.
pyenv install -s 3.7.0
pyenv install -s 3.6.5
pyenv install -s 2.7.15
pyenv global 3.7.0 3.6.5 2.7.15 system
# We now have 5 python installations.
# 1. system
# 2. python3 (latest, via homebrew)
# 3. python 3.7.0 (via pyenv)
# 4. python 3.6.5 (via pyenv)
# 5. python 2.7.15 (via pyenv)
# Install Pipsi
curl https://raw.githubusercontent.com/mitsuhiko/pipsi/master/get-pipsi.py | python3
# Using homebrew's python3, install the tools we regularly use outside of a virtualenv.
(
pyenv local system \
&& sudo easy_install --upgrade pip
&& pip install --upgrade pip bumpversion virtualenv \
&& rm .python-version
)
#&& sudo setup_tools install pip \
# Add pyenv init, update path with pyenv, make brew respect pyenv
touch ~/.bash_profile
echo "if command -v pyenv 1>/dev/null 2>&1; then" >> ~/.bash_profile
echo " eval \"\$(pyenv init -)\"" >> ~/.bash_profile
echo "fi" >> ~/.bash_profile
echo "export PATH=~/.local/bin:\${PATH}" >> ~/.bash_profile
echo "alias brew=\"env PATH=\${PATH//\$(pyenv root)\/shims:/} brew\"" >> ~/.bash_profile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment