lets divide and have two methods one for windows other for linux and those could be called from this one, instead of having all those lines of code in one method