On 2015-04-03 02:13, Erik Christiansen wrote:
> On 01.04.15 17:25, Peng Yu wrote:
> > ~$ compgen -c ls
> > ls
> > ls
> > lsof
> > lsappinfo
>
> Or, more succinctly:
>
> $ ls<Tab>
> ls lsblk lscpu lsmod lspci
> lsusb lsattr lsb_release lsinitramfs lsof lspgpot
>
> Compare, in Vim:
>
> :h complet<Tab> # Type that,
> complete() # and with each succeeding <Tab>
> 'complete' # ONE new alternative is presented.
> ...
>
> Now that you understand how it works
Peng has demonstrated pretty solid knowledge of how it works in Vim.
The main difference is that compgen puts the output on stdout where it
can be captured for future uses. Vim's autocompletion displays the
matches but doesn't readily grant access to them in a way that
scripts can make use of that auto-complete information. See
Nikolay's contortions elsewhere in the thread for capturing them.
-tim
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment