Fix permissions issue with makign dir before git