cheking writeDir using regex (done). added stringi pckg