Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion lua/neo-tree/sources/common/commands.lua
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,16 @@ end

M.order_by_name = function(state)
set_sort(state, "Name")
state.sort_field_provider = nil
local config = require("neo-tree").config
if config.sort_case_insensitive then
state.sort_field_provider = function(node)
return node.path:lower()
end
else
state.sort_field_provider = function(node)
return node.path
end
end
require("neo-tree.sources.manager").refresh(state.name)
end

Expand Down