strojnadzor/.envrc
2020-03-10 20:53:00 +01:00

15 lines
327 B
Bash

if type lorri &>/dev/null; then
# https://github.com/target/lorri
eval "$(lorri direnv)"
else
# fall back to using direnv's builtin nix support
use nix
fi
VIRTUAL_ENV="$PWD/venv"
if [ ! -e venv ]
then
python -m venv --system-site-packages "${VIRTUAL_ENV}"
fi
export VIRTUAL_ENV
PATH_add "$VIRTUAL_ENV/bin"