plugins.cloak.settings

Options provided to the require('cloak').setup function.

Type: attribute set of anything

Default: { }

Example:

{
  cloak_character = "*";
  enabled = true;
  highlight_group = "Comment";
  patterns = [
    {
      cloak_pattern = "=.+";
      file_pattern = [
        ".env*"
        "wrangler.toml"
        ".dev.vars"
      ];
    }
  ];
}

Declared by:

plugins.cloak.settings.enabled

Whether to enable the plugin.

Plugin default: true

Type: null or boolean or raw lua code

Default: null

Declared by:

plugins.cloak.settings.cloak_character

Define the cloak character.

Plugin default: "*"

Type: null or string or raw lua code

Default: null

Declared by:

plugins.cloak.settings.cloak_length

Provide a number if you want to hide the true length of the value. Applies the length of the replacement characters for all matched patterns, defaults to the length of the matched pattern.

Type: null or (unsigned integer, meaning >=0)

Default: null

Declared by:

plugins.cloak.settings.cloak_telescope

Set to true to cloak Telescope preview buffers. (Required feature not in 0.1.x)

Plugin default: true

Type: null or boolean or raw lua code

Default: null

Declared by:

plugins.cloak.settings.highlight_group

The applied highlight group (colors) on the cloaking, see :h highlight.

Plugin default: "Comment"

Type: null or string or raw lua code

Default: null

Declared by:

plugins.cloak.settings.patterns

List of pattern configurations.

Plugin default:

[
  {

    file_pattern = ".env*";
    cloak_pattern = "=.+";
    replace = null;
  }
]

Type: null or (list of ((submodule) or raw lua code))

Default: null

Declared by:

plugins.cloak.settings.try_all_patterns

Whether it should try every pattern to find the best fit or stop after the first.

Plugin default: true

Type: null or boolean or raw lua code

Default: null

Declared by: