diff options
author | Milo <50248166+Milo123459@users.noreply.github.com> | 2021-05-03 20:50:29 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-03 21:50:29 +0200 |
commit | 48f913ec2309c8fa1f3c012e5aa33f7df0f6e0ad (patch) | |
tree | d0a54a5cd27b2f43685812b967cf62b6e407f4a6 /docs/config/README.md | |
parent | dead06ba14e30803f0027be8d46cc1f395d5d87e (diff) |
feat(vlang): create module (#2577)
* Add V module
* Format
* Fix tests
* fix typo
* Update src/configs/v.rs
Co-authored-by: Dario Vladović <d.vladimyr@gmail.com>
* Update docs/config/README.md
Co-authored-by: Dario Vladović <d.vladimyr@gmail.com>
* Update docs/config/README.md
Co-authored-by: Dario Vladović <d.vladimyr@gmail.com>
* Update docs/config/README.md
Co-authored-by: Dario Vladović <d.vladimyr@gmail.com>
* Use blue bold
* v -> vlang
* change docs
* More vlang fixes
* add package support for v
* Update docs/config/README.md
Co-authored-by: Dario Vladović <d.vladimyr@gmail.com>
* use regex
* Update src/configs/mod.rs
Co-authored-by: David Knaack <davidkna@users.noreply.github.com>
* apply patch
* fix
Co-authored-by: Dario Vladović <d.vladimyr@gmail.com>
Co-authored-by: David Knaack <davidkna@users.noreply.github.com>
Diffstat (limited to 'docs/config/README.md')
-rw-r--r-- | docs/config/README.md | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/docs/config/README.md b/docs/config/README.md index b6ff32819..86e206160 100644 --- a/docs/config/README.md +++ b/docs/config/README.md @@ -223,6 +223,7 @@ $rust\ $scala\ $swift\ $terraform\ +$vlang\ $vagrant\ $zig\ $nix_shell\ @@ -2022,6 +2023,7 @@ package, and shows its current version. The module currently supports `npm`, `ca - [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present - [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present - [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your > current directory, not your package manager. @@ -2839,6 +2841,41 @@ By default the module will be shown if any of the following conditions are met: format = "via [⍱ $version](bold white) " ``` +## VLang + +The `vlang` module shows you your currently installed version of V. +By default the module will be shown if any of the following conditions are met: +- The current directory contains a file with `.v` extension +- The current directory contains a `v.mod` file + +### Options + +| Option | Default | Description | +| ------------------- | ------------------------------------------------- | ----------------------------------------------- | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `symbol` | `"V "` | A format string representing the symbol of V | +| `detect_extensions` | `["v"]` | Which extensions should trigger this module. | +| `detect_files` | `["v.mod"]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `style` | `"blue bold"` | The style for the module. | +| `disabled` | `false` | Disables the `vlang` module. | + +### Variables + +| Variable | Example | Description | +| -------- | -------- | ------------------------------------ | +| version | `v0.2` | The version of `v` | +| symbol | | Mirrors the value of option `symbol` | +| style\* | | Mirrors the value of option `style` | + +### Example + +```toml +# ~/.config/starship.toml +[v] +format = "via [V $version](blue bold) " +``` + ## VCSH The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/vcsh) repository. |