Commit b7617b35 authored by Jonathan Cremin's avatar Jonathan Cremin
Browse files

Check for autoenv_init function before trying to source autoenv.

parent 3ea33841
# Activates autoenv or reports its failure # Activates autoenv or reports its failure
if ! source $HOME/.autoenv/activate.sh 2>/dev/null; then if ! type autoenv_init &>/dev/null && ! source $HOME/.autoenv/activate.sh 2>/dev/null; then
echo '-------- AUTOENV ---------' echo '-------- AUTOENV ---------'
echo 'Could not find ~/.autoenv/activate.sh.' echo 'Could not find autoenv_init function or ~/.autoenv/activate.sh.'
echo 'Please check if autoenv is correctly installed.' echo 'Please check if autoenv is correctly installed.'
echo 'In the meantime the autoenv plugin is DISABLED.' echo 'In the meantime the autoenv plugin is DISABLED.'
echo '--------------------------' echo '--------------------------'
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment