-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Command completion for :sh #6727
Comments
I don't think that's possible, what commands are available depends in the system shell and there is no unified way to obtain completions from those. Crawling |
It can be implemented, that's not the question (it's implemented in other editors like Vim). Is it a good idea? I am saying yes because it's a (minor) improvement to user experience |
Well, Pascal described a way to do it - we're just concerned about the performance: blocking the prompt for a while to scan the PATH is not a good UX. Also, if you're going to assert this it would be helpful to at least link to the code where another editor implements this. It looks like Kakoune crawls |
As for shell built-ins, this is not a great solution, but maybe Helix could complete a hard-coded list of POSIX standard built-ins. If the user's shell has additional ones, those won't be completed. Not ideal when the user's shell isn't POSIX compliant, though... |
Shell completion for Fish can be implemented pretty easily by using the I wasn't able to find an equivalent for Bash. |
Typing
:sh l<Tab>
should display completions for (example)longcommand
,ls
,ln
, etc... based on executables available inPATH
, in addition to file/directory name completion.Similar to, but distinct from #6717
The text was updated successfully, but these errors were encountered: