Compatibility improvements
Compatibility improvements

Added various improvements as suggested by @JessThrysoee

- Use 'type' instead of 'which'
- Added OPTS var to reduce duplicated code
- Use 'exec -cl bash' for a 'clean' bash shell
- Added HOME=/root for 'sh' shell

Yong-Lee/nsenter,oouyang/nsenter,aaam/nsenter,dalanlan/nsenter,BWITS/nsenter,ccortezb/nsenter,ccortezb/nsenter,jasonchaffee/nsenter,jpetazzo/nsenter,Yong-Lee/nsenter,jpetazzo/nsenter,jasonchaffee/nsenter,oouyang/nsenter,aaam/nsenter,dalanlan/nsenter,BWITS/nsenter