mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-01-23 09:46:04 -05:00
Shell: Provide the correct invariant length to the line editor
This commit is contained in:
parent
683a0696f3
commit
0fb4a808ef
Notes:
sideshowbarker
2024-07-19 07:09:57 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/0fb4a808ef6 Pull-request: https://github.com/SerenityOS/serenity/pull/2030
1 changed files with 3 additions and 3 deletions
|
@ -1135,7 +1135,7 @@ int main(int argc, char** argv)
|
|||
// e.g. in `cd /foo/bar', 'bar' is the invariant
|
||||
// since we are not suggesting anything starting with
|
||||
// `/foo/', but rather just `bar...'
|
||||
editor.suggest(token_to_complete.length(), 0);
|
||||
editor.suggest(escape_token(token).length(), 0);
|
||||
|
||||
// only suggest dot-files if path starts with a dot
|
||||
Core::DirIterator files(path,
|
||||
|
@ -1185,7 +1185,7 @@ int main(int argc, char** argv)
|
|||
}
|
||||
suggestions.append({ cached_path[index], " " });
|
||||
|
||||
editor.suggest(token_to_complete.length(), 0);
|
||||
editor.suggest(escape_token(token).length(), 0);
|
||||
|
||||
return suggestions;
|
||||
};
|
||||
|
@ -1216,7 +1216,7 @@ int main(int argc, char** argv)
|
|||
// e.g. in `cd /foo/bar', 'bar' is the invariant
|
||||
// since we are not suggesting anything starting with
|
||||
// `/foo/', but rather just `bar...'
|
||||
editor.suggest(token_to_complete.length(), 0);
|
||||
editor.suggest(escape_token(token).length(), 0);
|
||||
|
||||
// only suggest dot-files if path starts with a dot
|
||||
Core::DirIterator files(path,
|
||||
|
|
Loading…
Add table
Reference in a new issue