View Source Doctor.Config (Doctor v0.21.0)

This module defines a struct which houses all the configuration data for Doctor.

Link to this section Summary

Types

t()
  • :min_module_doc_coverage - Minimum ratio of @doc vs public functions per module.
  • :min_overall_doc_coverage - Minimum ratio of @doc vs public functions across the codebase.
  • :min_overall_moduledoc_coverage - Minimum ratio of @moduledoc to modules across the codebase.
  • :moduledoc_required - If true, :min_overall_moduledoc_coverage is automatically set to 100%. Deprecated.

Functions

Get the configuration defaults as a string

Get the configuration file name

Returns true if a specific module should fail validation if it lacks a moduledoc."

Create a new Config struct from a map, keyword list or preexisting Config.

Link to this section Types

@type t() :: %Doctor.Config{
  exception_moduledoc_required: boolean() | nil,
  failed: false,
  ignore_modules: [Regex.t() | String.t()],
  ignore_paths: [Regex.t() | module()],
  min_module_doc_coverage: integer() | float(),
  min_module_spec_coverage: integer() | float(),
  min_overall_doc_coverage: integer() | float(),
  min_overall_moduledoc_coverage: integer() | float(),
  min_overall_spec_coverage: integer() | float(),
  moduledoc_required: boolean(),
  raise: boolean(),
  reporter: module(),
  struct_type_spec_required: boolean(),
  umbrella: boolean()
}
  • :min_module_doc_coverage - Minimum ratio of @doc vs public functions per module.
  • :min_overall_doc_coverage - Minimum ratio of @doc vs public functions across the codebase.
  • :min_overall_moduledoc_coverage - Minimum ratio of @moduledoc to modules across the codebase.
  • :moduledoc_required - If true, :min_overall_moduledoc_coverage is automatically set to 100%. Deprecated.

Link to this section Functions

Link to this function

config_defaults_as_string()

View Source

Get the configuration defaults as a string

Get the configuration file name

Link to this function

moduledoc_required?(arg1)

View Source
@spec moduledoc_required?(t()) :: boolean()

Returns true if a specific module should fail validation if it lacks a moduledoc."

@spec new(keyword() | map()) :: t()

Create a new Config struct from a map, keyword list or preexisting Config.