Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Having a hard time dealing with a completion collision
- X-seq: zsh-users 24693
- From: Peter Stephenson <p.stephenson@xxxxxxxxxxx>
- To: <zsh-users@xxxxxxx>
- Subject: Re: Having a hard time dealing with a completion collision
- Date: Wed, 19 Feb 2020 09:35:20 +0000
- Cms-type: 201P
- Dkim-filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20200219093522euoutp02026458b2865a3d843d91b99457975b79~0xAtetXXF2910729107euoutp024
- In-reply-to: <20200218191720.ae3fafhyrrqch5um@NUX>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- List-unsubscribe: <mailto:zsh-users-unsubscribe@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <CGME20200218163908eucas1p28a3b95a5e11163f515ee6e902ff9bbf5@eucas1p2.samsung.com> <20200218163725.zdkiord4uaxmutsk@NUX> <1582045340.4529.20.camel@samsung.com> <20200218191720.ae3fafhyrrqch5um@NUX>
On Tue, 2020-02-18 at 21:17 +0200, Doron Behar wrote:
> On Tue, Feb 18, 2020 at 05:02:20PM +0000, Peter Stephenson wrote:
> >
> > The files have different names, so they're both loaded. To get the
> > first file to be loaded used by compdef, remove the ~/.zcompdump* file
> > --- exact names vary depending on configuration but it's safe to
> > remove any you find --- and it will be regenerated with the correct
> > configuration next time you start the shell.
> If I remove the ~/.zcompdump* files and don't ran the `compdef` command,
> the same issue occurs.
That suggests something unusual in your set up as the compinit script
handles this case by design. For example,
- fpath is being modified after compinit;
- something is using "compdef" explicitly for the wrong function.
Obviously, those are just random guesses. You can get a bit further
by looking in the appropriate .zcompdump file. If it's showing
the wrong function, that suggests the fpath was not set up
correctly at the point compinit was run. If it's showing
the right function, something monkeyed with the definition later.
If you care enough, you could instrument compdef to print a message
when it handles one of the two functions.
However, your workaround of using compdef by hand will be fine.
pws
Messages sorted by:
Reverse Date,
Date,
Thread,
Author