Added support for pyenv

This is just a copy/paste from the rbenv files.
It's completely untested as I have environment to test it on for now (but I will on sunday). I'd love if you can give it a go yourselves.
To my best understanding the gem module supports specifying which rbenv to use but it's not that documented. I assume we need the same for pyenv (with proper documentation of course).
How do I do it correctly.

This should resolve issue #9285.