From mboxrd@z Thu Jan 1 00:00:00 1970 MIME-Version: 1.0 In-Reply-To: References: <1469103.jPehuaMYEC@coil> Date: Mon, 9 Sep 2013 16:20:19 +0200 Message-ID: From: =?UTF-8?B?QmVuY2UgRsOhYmnDoW4=?= To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Content-Type: multipart/alternative; boundary=001a11c2b7c08a764404e5f41618 Subject: Re: [9fans] programmable pathname completion in Acme? Topicbox-Message-UUID: 7d7d3904-ead8-11e9-9d60-3106f5b1d025 --001a11c2b7c08a764404e5f41618 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable nothing prevents textcomplete from forking. 2013/9/9 Lee Fallat > Source code says: no. > > Check out line 725* in text.c, and begin your journey! > > *Code at line 725 in text.c for 9front acme: > > case 0x06: > case Kins: //interesting, didn't know you could use the insert key to > invoke this too. > rp =3D textcomplete(t); //the path completion > if(rp =3D=3D nil) > return; > nr =3D runestrlen(rp); > break; /* fall through to normal insertion case */ > > > On Mon, Sep 9, 2013 at 9:38 AM, dexen deVries wr= ote: > >> currently the ^F pathname completion is handled internally by Acme. is >> there a >> way to pass the argument of ^F to a script instead? >> >> >> my use case: find an existing pathname by supplying /any/ substring of i= t >> and >> invoking completion, as opposed to current requirement of providing whol= e >> leading part. i have a script that takes part of pathname in $1 and >> returns >> all (hopefully exactly one) matching pathnames, and i want to plumb the = ^F >> from Acme to it. >> >> >> -- >> dexen deVries >> >> [[[=E2=86=93][=E2=86=92]]] >> >> >> > --001a11c2b7c08a764404e5f41618 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
nothing prevents textcomplete from forking.


2013/9/9 Lee Falla= t <lee.fallat@muraculous.ca>
Source code says: no.
<= br>
Check out line 725* in text.c, and begin your journey!
<= div>
*Code at line 725 in text.c for 9front acme:

<= /div>
case 0x06:
case Kins: //interesting,= didn't know you could use the insert key to invoke this too.
rp =3D textcomplete(t); //th= e path completion
if(rp =3D=3D nil)
<= div> return;
nr =3D runestrlen(rp);
break; /* fall through to normal insertion case */


On Mon, Sep 9, 2013 at 9:38 AM, dexen deVries <dexen.devries@gmail.c= om> wrote:
currently the ^F pathname completion is handled internally= by Acme. is there a
way to pass the argument of ^F to a script instead?


my use case: find an existing pathname by supplying /any/ substring of it a= nd
invoking completion, as opposed to current requirement of providing whole leading part. i have a script that takes part of pathname in $1 and returns=
all (hopefully exactly one) matching pathnames, and i want to plumb the ^F<= br> from Acme to it.


--
dexen deVries

[[[=E2=86=93][=E2=86=92]]]




--001a11c2b7c08a764404e5f41618--