nmk_workspace.resolvers

Nmk workspace plugin config item resolvers.

Classes

SubProjectsResolver

Resolver usable find sub-projects in the workspace tree.

Module Contents

class nmk_workspace.resolvers.SubProjectsResolver(model: nmk.model.model.NmkModel)

Bases: nmk.model.resolver.NmkListConfigResolver

Resolver usable find sub-projects in the workspace tree.

Default behavior is to look sub-projects by iterating through git submodules. (other behaviors may be implemented if needed later).

get_value(name: str, root: str, only_nmk_projects: bool = True) list[str]

Resolver for sub-projects list.

Parameters:
  • root – root path of the workspace

  • only_nmk_projects – if True (default), only return sub-projects having a default nmk project file (nmk.yml)

Returns:

list of sub-projects paths relative to the workspace root