Skip to content

Validate Rules

When the architecture is configured and rules have been defined, the tool can check for rule violations with the following command:

tangle-guard validate

The codebase will be scanned and compared the the rules. If rule violations are found, the violations will be printed and the process shuts down with a error.

⚠️ Rule violations found.
Violation: bundler (layer: service) -> utils (layer: infrastructure) is not allowed.

It’s recommended to run the validation before commiting for fast feedback and early prevention of erosion. By running the tangle-guard CLI during development, teams can detect architecture violations before changes are even committed — avoiding drift before it happens.

It can also be integrated within the CI/CD pipeline.

Unter “Layer Rules” you can trigger the validation with the click of a button. Clicking it, the codebase gets scanned and violations get stored in the config file.