restoring prolog interpreter + fixes

- switching to Python shell now works
- checking directory existence for Magit
- restore prolog shell