summaryrefslogtreecommitdiff
path: root/lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua')
-rw-r--r--lua/telescope/builtin/files.lua14
1 files changed, 13 insertions, 1 deletions
diff --git a/lua/telescope/builtin/files.lua b/lua/telescope/builtin/files.lua
index 29c8df5..5c36963 100644
--- a/lua/telescope/builtin/files.lua
+++ b/lua/telescope/builtin/files.lua
@@ -7,6 +7,7 @@ local pickers = require('telescope.pickers')
local previewers = require('telescope.previewers')
local utils = require('telescope.utils')
local conf = require('telescope.config').values
+local log = require('telescope.log')
local scan = require('plenary.scandir')
local Path = require('plenary.path')
@@ -173,7 +174,7 @@ files.find_files = function(opts)
table.insert(find_command, v)
end
end
- elseif 1 == vim.fn.executable("find") then
+ elseif 1 == vim.fn.executable("find") and not vim.fn.has('win32') then
find_command = { 'find', '.', '-type', 'f' }
if not hidden then
table.insert(find_command, { '-not', '-path', "*/.*" })
@@ -186,6 +187,17 @@ files.find_files = function(opts)
table.insert(find_command, 2, v)
end
end
+ elseif 1 == vim.fn.executable("where") then
+ find_command = { 'where', '/r', '.', '*'}
+ if hidden ~= nil then
+ log.warn('The `hidden` key is not available for the Windows `where` command in `find_files`.')
+ end
+ if follow ~= nil then
+ log.warn('The `follow` key is not available for the Windows `where` command in `find_files`.')
+ end
+ if search_dirs ~= nil then
+ log.warn('The `search_dirs` key is not available for the Windows `where` command in `find_files`.')
+ end
end
end