Skip to content

Commit 8393f7c

Browse files
committed
add vim and libuv runtime for luals, qualify libuv types
1 parent 3af30ee commit 8393f7c

File tree

5 files changed

+11
-5
lines changed

5 files changed

+11
-5
lines changed

.luarc.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
{
22
"$schema": "https://raw.githubusercontent.com/sumneko/vscode-lua/master/setting/schema.json",
33
"runtime.version" : "Lua 5.1",
4+
"workspace": {
5+
"library": [
6+
"$VIMRUNTIME",
7+
"${3rd}/luv/library"
8+
]
9+
},
410
"diagnostics": {
511
"globals": [
612
"vim"

lua/nvim-tree/explorer/explore.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ local function get_type_from(type_, cwd)
1818
return type_ or (vim.loop.fs_stat(cwd) or {}).type
1919
end
2020

21-
---@param handle uv_fs_t
21+
---@param handle uv.uv_fs_t
2222
---@param cwd string
2323
---@param node Node
2424
---@param git_status table

lua/nvim-tree/git/runner.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,8 @@ function Runner:_handle_incoming_data(prev_output, incoming)
6060
return ""
6161
end
6262

63-
---@param stdout_handle uv_pipe_t
64-
---@param stderr_handle uv_pipe_t
63+
---@param stdout_handle uv.uv_pipe_t
64+
---@param stderr_handle uv.uv_pipe_t
6565
---@return table
6666
function Runner:_getopts(stdout_handle, stderr_handle)
6767
local untracked = self.list_untracked and "-u" or nil

lua/nvim-tree/node.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
---@class BaseNode
77
---@field absolute_path string
88
---@field executable boolean
9-
---@field fs_stat uv_fs_t
9+
---@field fs_stat uv.uv_fs_t
1010
---@field git_status GitStatus|nil
1111
---@field hidden boolean
1212
---@field name string

lua/nvim-tree/utils.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ function M.str_find(haystack, needle)
1919
end
2020

2121
---@param path string
22-
---@return string|uv_fs_t
22+
---@return string|uv.uv_fs_t
2323
function M.read_file(path)
2424
local fd = vim.loop.fs_open(path, "r", 438)
2525
if not fd then

0 commit comments

Comments
 (0)