rule

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package rule contains the configurations for the available rulesets. These are pre-compiled on start up for efficiency

Index

Constants

This section is empty.

Variables

View Source
var (
	// Sets contain the available rulesets
	Sets map[string][]Rule
)

Functions

This section is empty.

Types

type Rule

type Rule struct {
	Part        string         `json:"part"` // Only applicable to file types
	Type        string         `json:"type"`
	Pattern     string         `json:"pattern"`
	Caption     string         `json:"caption"`
	Description string         `json:"description"`
	Regex       *regexp.Regexp `json:"regex,omitempty"`
}

Rule represents a rule that can be run against part of a patch or a filename

Jump to

Keyboard shortcuts

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