fromYaml static method

BuildConfig? fromYaml(
  1. String rawYaml
)

Parses the full build.yaml file to get the config May return null if no config entry is found.

Implementation

static BuildConfig? fromYaml(String rawYaml) {
  final parsedYaml = loadYaml(rawYaml);
  final configEntry = _findConfigEntry(parsedYaml);
  if (configEntry == null) {
    return null;
  }

  final map = YamlUtils.deepCast(configEntry.value);
  return fromMap(map);
}