From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1052 invoked from network); 19 Apr 2000 09:19:41 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 19 Apr 2000 09:19:41 -0000 Received: (qmail 27605 invoked by alias); 19 Apr 2000 09:19:26 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10823 Received: (qmail 27563 invoked from network); 19 Apr 2000 09:19:21 -0000 Date: Wed, 19 Apr 2000 11:14:58 +0200 From: =?iso-8859-1?Q?Thomas_K=F6hler?= To: zsh-workers@sunsite.auc.dk Subject: Re: bindkey bug with zsh-3.1.6-dev-21? Message-ID: <20000419111458.B16679@picard.franken.de> Mail-Followup-To: =?iso-8859-1?Q?Thomas_K=F6hler?= , zsh-workers@sunsite.auc.dk References: <200004190857.KAA21162@beta.informatik.hu-berlin.de> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Yylu36WmvOXNoKYn" Content-Disposition: inline User-Agent: Mutt/1.1.9i In-Reply-To: <200004190857.KAA21162@beta.informatik.hu-berlin.de>; from wischnow@informatik.hu-berlin.de on Wed, Apr 19, 2000 at 10:58:14AM +0200 X-Operating-System: Linux picard.franken.de 2.2.14 X-Editor: VIM - Vi IMproved 5.6 http://www.vim.org/ X-IRC: tirc-1.2; Nick: jeanluc X-URL: http://jeanluc-picard.de/ --Yylu36WmvOXNoKYn Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Apr 19, 2000 at 10:58:14AM +0200, Sven Wischnowsky wrote: >=20 > =3D?iso-8859-1?Q?Thomas_K=3DF6hler?=3D wrote: >=20 > > Hi, > > Seems that there's a problem with bindkey and zsh-3.1.6-dev-21 and > > zsh-3.1.6-dev-22: > >=20 > > When I use this .zshrc: > >=20 > > bindkey -e > > export EDITOR=3D3Dvi > >=20 > > I get not tab-completion. If I type "bindkey", I get a long list of > > bindkeys, amongst others this one: > > "^I" expand-or-complete > >=20 > > So, the binding is there, but it just doesn't work :-( > >=20 > > The funny thing is, when I just have the "export EDITOR=3D3Dvi" line in= my > > =3D2Ezshrc and type "bindkey -e" on the prompt later, tab-completion wo= rks. > > How to resolve the problem? >=20 > Put `zmodload zsh/compctl' in your `.zshrc'. Or better, use the new > completion system (autoloading and calling `compinit'). Well, *I* do use the new completion system, but the one who found the problem (tries zsh because I showed him what it can do) doesn't (yet?). > Ick. The problem is that in autoload_zleread() we do: >=20 > if (load_module("zsh/zle")) > load_module("zsh/compctl"); >=20 > i.e., we attempt to load compctl only if loading zle succeeds. For > people who have a call to `bindkey' in their .z*, the zle module will > already be loaded, re-loading fails and compctl is not loaded. Bummer. Uhm. Bad. > Can anyone think of a solution for this? I can't (apart from trying to=20 > load compctl unconditionally, which I don't like). Is there a test whether or not a module is loaded? Something like =20 if (load_module("zsh/zle") || is_loaded_module("zsh/zle")) load_module("zsh/compctl"); If there is no such function (I don't have any insight in zsh's source) perhaps now is the time to implement one :-) Other possible solution: load zsh/compctl if there's a bindkey in .z* - but that's of course not very intuitive. > Bye > Sven CU, Thomas --=20 Thomas K=F6hler Email: jean-luc@picard.franken.de | LCARS - Linux <>< WWW: http://jeanluc-picard.de | for Computers IRC: jeanluc | on All Real PGP public key available from Homepage! | Starships --Yylu36WmvOXNoKYn Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.1 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE4/XkSTEYXWMJlHuYRAk03AJ9e8oAalGtEU0YU3A9yCMgDUkPwUQCfVufr vs0zIW1GCR/PTxjhF3Q1A0o= =E3T4 -----END PGP SIGNATURE----- --Yylu36WmvOXNoKYn--