Replace man function with a wrapper script which is more robust

I had problems with tab completions bombing out before