Added simple os detection

I could see having a helper.rb file that includes this function since its so large (and any new function we might want in the future.