pub fn path_entries(
prefix: &str,
case_sensitive: bool,
include_files: bool,
) -> Vec<RawCandidate>Expand description
PC.9: [fs_entries] without the completion engine’s context.
The prefix split, the ~ expansion, the case rule, the trailing / on a
directory and the sort are all one behaviour, and the picker’s dir-pick
source needs exactly it — a picker source cannot build a
GenerateContext, which is shaped for the completion engine (buffer,
command registry, cursor). Extracted rather than copied so the two surfaces
cannot drift on what “list this path’s children” means: a dir-pick that
expanded ~ differently from <Tab> on the : line would be a bug nobody
would think to look for.
An unreadable directory yields an empty list rather than an error. Half a typed path names nothing yet, and that is the state the caller is in for most of the keystrokes.