YamlHelper class

Reads metadata (version, project name, dependencies) from pubspec.yaml files.

This helper isolates YAML parsing so other classes can remain focused on generation and CLI behavior. It reads the installed package pubspec for version info and the target project pubspec for names/dependencies.

Constructors

YamlHelper()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

getDependencies({required String workingDirectory}) Future<(YamlMap?, YamlMap?)>
Returns the dependencies and dev_dependencies maps from the target project's pubspec.
getProjectName({required String workingDirectory}) Future<String>
Returns the name field from the target project's pubspec.yaml.
getVersion() Future<String?>
Returns the version of the feature_gen_cli package from its own pubspec.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited