Commit Graph

7 Commits

Author SHA1 Message Date
Sean Dewar
7e24c45221
feat(health): detect tmux RGB support via client_termfeatures
Problem: On tmux v3.2+, the `terminal-features` option may be used to enable RGB
capabilities over `terminal-overrides`. However, `show-messages` cannot be used
to detect if RGB capabilities are enabled using `terminal-features`.

Solution: Try to use `display-message -p #{client_termfeatures}` instead.
The returned features include "RGB" if either "RGB" is set in
`terminal-features`, or if "Tc" or "RGB" is set in `terminal-overrides` (as
before).
Nothing is returned by tmux versions older than v3.2, so fallback to checking
`show-messages` in that case.

Also, un-Vimscriptify the previous logic a bit, and change the error message to
point to using the `terminal-features` option instead for newer tmux versions.
2023-01-16 15:30:57 +00:00
Sean Dewar
60df0c0651
fix(health): fix tmux_esc_time comparison
Regression from the health.vim to .lua changes.

Unlike Vim script, Lua does not implicitly convert strings to numbers, so this
comparison threw an error.
2023-01-16 14:26:29 +00:00
TJ DeVries
307efe4906
health: migrate to Lua #21661
* refactor: remove all vimscript from nvim/health
* fixup: previous method broke if you had a folder named 'x-lua'
2023-01-16 01:55:24 -08:00
dundargoc
936e191fef
docs: fix typos (#21427)
Co-authored-by: Gustavo Sampaio <gbritosampaio@gmail.com>
Co-authored-by: C.D. MacEachern <craig.daniel.maceachern@gmail.com>
Co-authored-by: Sean Dewar <seandewar@users.noreply.github.com>
Co-authored-by: Tomas Nemec <nemi@skaut.cz>
2023-01-04 07:38:48 +08:00
Justin M. Keyes
4d2373f5f6
feat(checkhealth): use "help" syntax, avoid tabpage #20879
- If Nvim was just started, don't create a new tab.
- Name the buffer "health://".
- Use "help" syntax instead of "markdown". It fits better, and
  eliminates various workarounds.
- Simplfy formatting, avoid visual noise.
- Don't print a "INFO" status, it is noisy.
- Drop the ":" after statuses, they are already UPPERCASE and highlighted.
2022-11-11 18:33:31 -08:00
Justin M. Keyes
cc7c378bf3 feat(checkhealth): check runtime ($VIMRUNTIME)
Move man/health.lua into the "runtime" check.

fix #20696
2022-10-30 16:23:58 +01:00
Justin M. Keyes
3213bc36c5 refactor(checkhealth): convert "nvim" check to Lua 2022-10-30 15:50:59 +01:00