Skip to main content

select_adapter

Function select_adapter 

Source
pub fn select_adapter(
    project_root: &Path,
    config: &SubmitConfig,
) -> Box<dyn SourceAdapter>
Expand description

Select an adapter by name from configuration, with auto-detection fallback.

Resolution order:

  1. If config.adapter is explicitly set to a known built-in adapter name, use it.
  2. If config.adapter is unknown, check for an external VCS plugin with that name.
  3. If config.adapter is “none” (the default), auto-detect from the project root.
  4. If auto-detection fails, fall back to NoneAdapter.

§15 enforcement is applied to all loaded adapters.