diff options
| author | Justin M. Keyes <justinkz@gmail.com> | 2026-03-11 13:39:39 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-03-11 13:39:39 -0400 |
| commit | ba0baea620b16cb6ce4ecfcd7c5e69ebe478c276 (patch) | |
| tree | 2ba9a9f91a54786f6d7d4bfdbea448943e6c0d34 /runtime/lua/man.lua | |
| parent | 0ced2169279bc7d1d1dad906f9841707e336c371 (diff) | |
| parent | 682f5fee600802236e104ef85b5fbc6d3fe860cf (diff) | |
Merge #37830 docs
Diffstat (limited to 'runtime/lua/man.lua')
| -rw-r--r-- | runtime/lua/man.lua | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/runtime/lua/man.lua b/runtime/lua/man.lua index 9efc7e96f9..1104e7f906 100644 --- a/runtime/lua/man.lua +++ b/runtime/lua/man.lua @@ -221,12 +221,7 @@ local function get_path(name, sect) sect = sect or '' -- We can avoid relying on -S or -s here since they are very -- inconsistently supported. Instead, call -w with a section and a name. - local cmd --- @type string[] - if sect == '' then - cmd = { 'man', '-w', name } - else - cmd = { 'man', '-w', sect, name } - end + local cmd = sect == '' and { 'man', '-w', name } or { 'man', '-w', sect, name } local lines = system(cmd, true) local results = vim.split(lines, '\n', { trimempty = true }) |
