From 5e931604563b3ec77eb52980b2d8991414f85d22 Mon Sep 17 00:00:00 2001 From: Shu Kutsuzawa Date: Thu, 18 Feb 2021 03:03:09 +0900 Subject: feat(lua): Configure when the module is shown (#2326) This makes it possible to configure when the lua module is shown based on the contents of a directory. This should make it possible to be a lot more granular when configuring the module. --- docs/config/README.md | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) (limited to 'docs') diff --git a/docs/config/README.md b/docs/config/README.md index 1249fa03f..80da04048 100644 --- a/docs/config/README.md +++ b/docs/config/README.md @@ -1569,7 +1569,7 @@ disabled = true ## Lua The `lua` module shows the currently installed version of Lua. -The module will be shown if any of the following conditions are met: +By default the module will be shown if any of the following conditions are met: - The current directory contains a `.lua-version` file - The current directory contains a `lua` directory @@ -1577,13 +1577,16 @@ The module will be shown if any of the following conditions are met: ### Options -| Option | Default | Description | -| ------------ | ------------------------------------ | ----------------------------------------------------------------------------- | -| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | -| `symbol` | `"🌙 "` | A format string representing the symbol of Lua. | -| `style` | `"bold blue"` | The style for the module. | -| `lua_binary` | `"lua"` | Configures the lua binary that Starship executes when getting the version. | -| `disabled` | `false` | Disables the `lua` module. | +| Option | Default | Description | +| ------------------- | ------------------------------------ | ----------------------------------------------------------------------------- | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `symbol` | `"🌙 "` | A format string representing the symbol of Lua. | +| `detect_extensions` | `["lua"]` | Which extensions should trigger this moudle. | +| `detect_files` | `[".lua-version"]` | Which filenames should trigger this module. | +| `detect_folders` | `["lua"]` | Which folders should trigger this module. | +| `style` | `"bold blue"` | The style for the module. | +| `lua_binary` | `"lua"` | Configures the lua binary that Starship executes when getting the version. | +| `disabled` | `false` | Disables the `lua` module. | ### Variables -- cgit v1.2.3