Fixed mkdir by adding -p option