# Functions
AllStringsInSlice determines if `slice` contains the `strings`.
CapFirst capitalizes the first letter of a string.
CondSprintf is sprintf, ignores extra arguments.
FileExists determines if the path given by `filename` exists.
FindAsset tries to locate a Vale-related resource by looking in the user-defined StylesPath.
FormatAlert ensures that all required fields have data.
FormatFromExt takes a file extension and returns its [normExt, format] list, if supported.
FormatMessage inserts `subs` into `msg`.
FromFile loads an INI configuration from a file.
FromString loads an INI configuration from a string.
Get the user-defined packages from a `.vale.ini` file.
No description provided by the author
Indent adds padding to every line of `text`.
InRange determines if the range r contains the integer n.
IntInSlice determines if `slice` contains the int `a`.
IsDir determines if the path given by `filename` is a directory.
IsLetter returns `true` if s contains all letter characters and false if not.
IsPhrase returns `true` is s is a phrase-like token.
NewConfig initializes a Config with its default values.
NewE100 creates a new, formatted "unexpected" error.
NewE201 creates a formatted user-generated error.
NewE201FromPosition creates a new E201 error from an in-file location.
NewE201FromTarget creates a new E201 error from a target string.
NewError creates a colored error from the given information.
NewFile initializes a File.
No description provided by the author
No description provided by the author
Sanitize prepares text for our check functions.
ShouldIgnoreDirectory will check if directory should be ignored.
SplitLines splits on CRLF, CR not followed by LF, and LF.
StringInSlice determines if `slice` contains the string `a`.
StringsToInterface converts a slice of strings to an interface.
StripANSI removes all ANSI characters from the given string.
Substitute replaces the substring `sub` with a string of asterisks.
No description provided by the author
ToSentence converts a slice of terms into sentence.
Which checks for the existence of any command in `cmds`.
WhitespaceToSpace converts newlines and multiple spaces (e.g., " ") into a single space.
# Variables
AlertLevels holds the possible values for "level" in an external rule.
CommentsByNormedExt determines what parts of a file we should lint -- e.g., we only want to lint // or /* comments in a C++ file.
FormatByExtension associates a file extension with its "normed" extension and its format (markup, code or text).
LevelToInt allows us to easily compare levels in lint.go.
# Structs
An Action represents a possible solution to an Alert.
An Alert represents a potential error in prose.
CLIFlags holds the values that are defined at runtime by the user.
Config holds the configuration values from both the CLI and `.vale.ini`.
A File represents a linted text file.
# Type aliases
ByName sorts Files by their path.
ByPosition sorts Alerts by line and column.
No description provided by the author