loadPubspecConfig function
Implementation
Config loadPubspecConfig(File pubspecFile) {
stdout.writeln('$flutterGenVersion Loading ... '
'${normalize(join(
basename(pubspecFile.parent.path),
basename(pubspecFile.path),
))}');
final content = pubspecFile.readAsStringSync();
final userMap = loadYaml(content) as Map?;
final defaultMap = loadYaml(configDefaultYamlContent) as Map?;
final mergedMap = mergeMap([defaultMap, userMap]);
final pubspec = Pubspec.fromJson(mergedMap);
return Config._(pubspec: pubspec, pubspecFile: pubspecFile);
}