make sure we set the new dir whenever we call all function with path