no need to check for dir if using makedir -p and optimise chown/chgrp to just chown