Made dir generic for Mac and Windows