nerves_system_linter v0.4.0 Nerves.System.Linter.Rule.Callbacks

The language for defining a rule.

Link to this section Summary

Types

Argument to a check.

List or arguments.

The name of the check to aply.

Human readable message for a check.

Replace the message for a check.

If a check evaluates false, it should be a warning instead of error.

Link to this section Types

Specs

arg() :: message_arg() | warning_arg()

Argument to a check.

Specs

args() :: [arg()]

List or arguments.

Specs

check() :: :ensure_package | :ensure_bool | :ensure_value

The name of the check to aply.

Specs

message() :: String.t()

Human readable message for a check.

Link to this type

message_arg()

Specs

message_arg() :: {:message, message()}

Replace the message for a check.

Link to this type

warning_arg()

Specs

warning_arg() :: {:warn, boolean()}

If a check evaluates false, it should be a warning instead of error.

Link to this section Functions

Link to this macro

ensure_bool(config_name, bool \\ true, opts \\ [])

(macro)

Ensures a boolean value.

Link to this macro

ensure_package(package_name, opts \\ [])

(macro)

Specs

Ensures a package is enabled.

Link to this macro

ensure_value(config_name, value, opts \\ [])

(macro)

Ensures a value.

Link to this macro

ensure_value_match(config_name, pattern, opts \\ [])

(macro)
Link to this macro

evaluate()

(macro)

Registers this rule to be evaluated.