zsh-users
 help / color / mirror / code / Atom feed
* Get the name of the completion function for a given command
@ 2020-08-22 16:49 Rudi C
  2020-08-22 16:56 ` Matthew Martin
  0 siblings, 1 reply; 2+ messages in thread
From: Rudi C @ 2020-08-22 16:49 UTC (permalink / raw)
  To: zsh-users

[-- Attachment #1: Type: text/plain, Size: 232 bytes --]

I want to get the completion function for a given command. I know I can
assign such a completion function like so:

`compdef some_completion_function my_command`

But I want the reverse:

`compdef-get my_command #> some_completion`

[-- Attachment #2: Type: text/html, Size: 344 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Get the name of the completion function for a given command
  2020-08-22 16:49 Get the name of the completion function for a given command Rudi C
@ 2020-08-22 16:56 ` Matthew Martin
  0 siblings, 0 replies; 2+ messages in thread
From: Matthew Martin @ 2020-08-22 16:56 UTC (permalink / raw)
  To: zsh-users

On Sat, Aug 22, 2020 at 09:19:58PM +0430, Rudi C wrote:
> I want to get the completion function for a given command. I know I can
> assign such a completion function like so:
> 
> `compdef some_completion_function my_command`
> 
> But I want the reverse:
> 
> `compdef-get my_command #> some_completion`

% print $_comps[apt-get]
_apt
% print $^fpath/$_comps[apt-get](N)
/home/phy1729/zsh/Completion/Debian/Command/_apt


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-08-22 16:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-22 16:49 Get the name of the completion function for a given command Rudi C
2020-08-22 16:56 ` Matthew Martin

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).