Module provider

Module provider 

Source
Expand description

CODEOWNERS sync providers for different platforms.

This module provides a trait-based abstraction for syncing CODEOWNERS files across different platforms (GitHub, GitLab, Bitbucket). Each platform has specific requirements for file location and section syntax.

§Provider Implementations

Provider implementations are available in separate platform crates:

§Example

use cuenv_codeowners::provider::{CodeownersProvider, ProjectOwners};
use cuenv_github::GitHubCodeownersProvider;
use std::path::Path;

let provider = GitHubCodeownersProvider;
let projects = vec![/* ... */];
let result = provider.sync(Path::new("."), &projects, false)?;

Structs§

CheckResult
Result of a check operation.
ProjectOwners
Project with its owners configuration and relative path.
SyncResult
Result of a sync operation.

Enums§

ProviderError
Error type for provider operations.
SyncStatus
Status of a sync operation.

Traits§

CodeownersProvider
Trait for CODEOWNERS sync providers.

Functions§

generate_aggregated_content
Generate aggregated CODEOWNERS content from multiple projects.
prefix_pattern
Prefix a pattern with the project’s relative path.
write_codeowners_file
Write content to a file, creating parent directories as needed.

Type Aliases§

Result
Result type for provider operations.