linter

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2026 License: MIT Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package linter implements the command that lints a Semaphore flag configuration file.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HelpVars added in v0.2.0

func HelpVars() kong.Vars

HelpVars returns the kong interpolation variables used by Cmd help tags.

func Run added in v0.2.0

func Run(args []string, streams *helper.Streams) error

Run parses args against Cmd and executes the linter with injected output streams.

Types

type Cmd added in v0.2.0

type Cmd struct {
	ConfigFile string `arg:""         help:"${helpLintConfig}" name:"config_file" optional:""`
	Format     string `default:"yaml" help:"${helpLintFormat}" name:"format"      short:"f"`
}

Cmd lints a Semaphore flag configuration file.

func (Cmd) Help added in v0.2.0

func (Cmd) Help() string

Help returns the detailed description of lint for kong's help output.

func (Cmd) Run added in v0.2.0

func (c Cmd) Run(streams *helper.Streams) error

Run executes the lint command using streams for stdout and stderr.

type Linter

type Linter struct {
	InputFile   string
	InputFormat string
}

Linter checks a flag configuration file for errors.

func (*Linter) Lint

func (l *Linter) Lint() []error

Lint returns the errors found in the flag configuration file.

Jump to

Keyboard shortcuts

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