bufcheck

package
v1.19.0 Latest Latest
Warning

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

Go to latest
Published: May 17, 2023 License: Apache-2.0 Imports: 7 Imported by: 4

Documentation

Overview

Package bufcheck contains the implementations of the lint and breaking change detection rules.

There is a lot of shared logic between the two, and originally they were actually combined into one logical entity (where some checks happened to be linters, and some checks happen to be breaking change detectors), so some of this is historical.

Index

Constants

This section is empty.

Variables

View Source
var AllRuleFormatStrings = []string{
	"text",
	"json",
}

AllRuleFormatStrings is all rule format strings.

Functions

func PrintRules

func PrintRules(writer io.Writer, rules []Rule, formatString string) (retErr error)

PrintRules prints the rules to the writer.

The empty string defaults to text.

Types

type Rule

type Rule interface {
	json.Marshaler

	// ID returns the ID of the Rule.
	//
	// UPPER_SNAKE_CASE.
	ID() string
	// Categories returns the categories of the Rule.
	//
	// UPPER_SNAKE_CASE.
	// Sorted.
	// May be empty.
	Categories() []string
	// Purpose returns the purpose of the Rule.
	//
	// Full sentence.
	Purpose() string
}

Rule is a rule.

Directories

Path Synopsis
Package bufbreaking contains the breaking change detection functionality.
Package bufbreaking contains the breaking change detection functionality.
Package buflint contains the linting functionality.
Package buflint contains the linting functionality.

Jump to

Keyboard shortcuts

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