setup: convert setup_git_directory_gently_1 et al. to strbuf