removePath method
Implementation
Future<GitHash?> removePath(String pathSpec) async {
var i = entries.indexWhere((e) => e.path == pathSpec);
if (i == -1) {
return null;
}
var indexEntry = entries.removeAt(i);
return indexEntry.hash;
}