Deterministic dotenv target selection across a multi-path cascade.
This module extracts the “which file should we edit?” logic from the FS-level editor
so plugins/tools can reuse the same selection semantics as editDotenvFile.
Notes:
Selection is based on paths only (directories), consistent with get-dotenv overlay precedence.
Default search order is reverse (last path wins).
Template discovery is supported via <target>.<templateExtension> and returns the template path
when the concrete target is missing.
Deterministic dotenv target selection across a multi-path cascade.
This module extracts the “which file should we edit?” logic from the FS-level editor so plugins/tools can reuse the same selection semantics as editDotenvFile.
Notes:
pathsonly (directories), consistent with get-dotenv overlay precedence.<target>.<templateExtension>and returns the template path when the concrete target is missing.