# Download the latest binary
curl -O https://github.com/direnv/direnv/releases/download/v2.4.0/direnv.darwin-amd64
# Create user bin dir and move the binary
mkdir ~/bin/direnv
mv direnv.darwin-amd64 ~/bin/direnv
# Make the direnv binary executable
chmod +x ~/bin/direnv
# Ensure the user bin dir is on the path (~/.profile or ~/.zshrc)export PATH=~/bin:$PATH# Add the following line if on bash (~/.bashrc)eval"$(direnv hook bash)"# Add the following line if on zsh (~/.zshrc)eval"$(direnv hook zsh)"# Star a new terminal session or source your bash/zsh env
Virtualenv
1
2
3
4
5
6
7
8
9
10
11
12
13
# Ensure virtualenv is installed
pip install virtualenv
# cd into your project folder and create a new direnv config fileecho"# Python
layout python
export PYTHONPATH=$VIRTUAL_ENV/lib/python2.7/site-packages/:$PYTHONPATH"> .envrc
# As requested by the direnv error message that should appear, run the following
direnv allow
# If everything worked, executing the following command should print the path to the python executable within this project
which python
Robot Framework
1
2
3
4
5
6
7
8
9
10
11
12
13
# Create another dot file containing the Robot Framework packages to be presentecho"pip install robotframework
pip install robotframework-sshlibrary
pip install robotframework-requests
pip install robotframework-selenium2library
pip install robotframework-extendedselenium2library"> .robotenv
# Make the file executable
chmod u+x .robotenv
# Install the defined packages
./.robotenv