pathPubspecRemoveDependency function
Returns true if removed
Implementation
Future<bool> pathPubspecRemoveDependency(String dir, String dependency) async {
var map = await pathGetPubspecYamlMap(dir);
if (pubspecYamlHasAnyDependencies(map, [dependency])) {
var content = _loadPubspecContent(dir);
content = pubspecStringRemoveDependency(content, dependency);
await _writePubspecContent(dir, content);
return true;
}
return false;
}