rules

package
v0.30.14 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 27, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const BilingualRuleID = "bilingual"

BilingualRuleID is the stable identifier used to reference this rule in configuration.

View Source
const CyrillicInEnglishRuleID = "cyrillic-in-english"

CyrillicInEnglishRuleID is the stable identifier used to reference this rule in configuration.

View Source
const ReadmeRuleID = "readme"

ReadmeRuleID is the stable identifier used to reference this rule in configuration.

Variables

This section is empty.

Functions

This section is empty.

Types

type BilingualRule

type BilingualRule struct {
	// contains filtered or unexported fields
}

BilingualRule enforces that top-level English docs have Russian counterparts.

func NewBilingualRule

func NewBilingualRule(path string, res *diag.Collector) *BilingualRule

NewBilingualRule constructs a BilingualRule scoped to path, tagging diagnostics with the rule ID.

func (*BilingualRule) Check

func (r *BilingualRule) Check(_ context.Context)

Check verifies that each top-level English markdown file in docs/ has a Russian translation.

type CyrillicInEnglishRule

type CyrillicInEnglishRule struct {
	// contains filtered or unexported fields
}

CyrillicInEnglishRule enforces that English documentation does not contain cyrillic text.

func NewCyrillicInEnglishRule

func NewCyrillicInEnglishRule(path string, res *diag.Collector) *CyrillicInEnglishRule

NewCyrillicInEnglishRule constructs a CyrillicInEnglishRule scoped to path, tagging diagnostics with the rule ID.

func (*CyrillicInEnglishRule) Check

Check scans top-level English markdown files in docs/ for cyrillic characters.

type ReadmeRule

type ReadmeRule struct {
	// contains filtered or unexported fields
}

ReadmeRule enforces that docs/README.md exists and is not empty.

func NewReadmeRule

func NewReadmeRule(path string, res *diag.Collector) *ReadmeRule

NewReadmeRule constructs a ReadmeRule scoped to path, tagging diagnostics with the rule ID.

func (*ReadmeRule) Check

func (r *ReadmeRule) Check(_ context.Context)

Check verifies that docs/README.md exists and has content.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL