initRemoteGit function
Init remote git repository in directory
Implementation
Future<void> initRemoteGit(Directory testDir) async {
final remoteDir = testDir;
await remoteDir.create(recursive: true);
final result = await Process.run('git', [
'init',
'--bare',
'--initial-branch=main',
], workingDirectory: remoteDir.path);
_throw('Could not initialize remote git repository', result);
}