Add script to detect host platform and Operating System
Modularize code and add switches