CICD#

class src.ansys.pre_commit_hooks.quality_rules.cicd.CICD#

Bases: abc.ABC

CI/CD rule family.

Base class of the CI/CD quality rules. Each rule is a subclass named CI with a static check method that receives the repository root and the name of the detected README file.

Overview#

check

Evaluate a CI/CD rule.

Import detail#

from src.ansys.pre_commit_hooks.quality_rules.cicd import CICD

Attribute detail#

CICD.family: ClassVar[str] = 'cicd'#

Method detail#

static CICD.check(repository_root: pathlib.Path, readme_file: str | None) → ansys.pre_commit_hooks.quality_rules.common.RuleCheckResult#
Abstractmethod:

Evaluate a CI/CD rule.

Parameters:
repository_rootpathlib.Path

Repository root directory.

readme_filestr or None

Detected README path, or None when no supported README exists.

Returns:
bool or str

Raw rule result consumed by the quality-report runner.