From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26666 invoked from network); 29 Nov 2004 20:12:04 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 29 Nov 2004 20:12:04 -0000 Received: (qmail 16247 invoked from network); 29 Nov 2004 20:11:58 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 29 Nov 2004 20:11:58 -0000 Received: (qmail 29374 invoked by alias); 29 Nov 2004 20:11:05 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 8243 Received: (qmail 29352 invoked from network); 29 Nov 2004 20:11:03 -0000 Received: from unknown (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 29 Nov 2004 20:11:03 -0000 Received: (qmail 14337 invoked from network); 29 Nov 2004 20:10:06 -0000 Received: from karnickel.franken.de (193.141.110.11) by a.mx.sunsite.dk with SMTP; 29 Nov 2004 20:10:04 -0000 Received: from karnickel.franken.de (localhost [127.0.0.1]) by karnickel.franken.de (8.12.10/8.12.10) with ESMTP id iATKA2Od036763 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 29 Nov 2004 21:10:03 +0100 (CET) Received: (from uucp@localhost) by karnickel.franken.de (8.12.10/8.12.2/Submit) with UUCP id iATK0EN4034213 for zsh-users@sunsite.dk; Mon, 29 Nov 2004 21:00:14 +0100 (CET) (envelope-from jean-luc@picard.franken.de) Received: by picard.franken.de (Postfix, from userid 1001) id 753493BE7F; Mon, 29 Nov 2004 20:58:21 +0100 (CET) Date: Mon, 29 Nov 2004 20:58:21 +0100 From: Thomas =?iso-8859-1?Q?K=F6hler?= To: zsh-users@sunsite.dk Subject: Re: Edit result of last command Message-ID: <20041129195821.GA20141@picard.franken.de> Mail-Followup-To: zsh-users@sunsite.dk References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="fdj2RfSjLxBAspz7" Content-Disposition: inline In-Reply-To: X-Operating-System: Linux X-Editor: VIM - Vi IMproved 6.2 http://www.vim.org/ X-IRC: tirc; Nick: tkoehler X-URL: http://jeanluc-picard.de/ User-Agent: Mutt/1.5.4i X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, hits=-0.9 required=6.0 tests=BAYES_10 autolearn=no version=2.63 X-Spam-Hits: -0.9 --fdj2RfSjLxBAspz7 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi, zzapper wrote: > Hi >=20 > say I've done a command a find/ls whatever >=20 > eg=20 > >ls *add* > which returns > addition.html >=20 > I can then type > > vi $(!!) >=20 > But that's way too tiring >=20 > So I wrote the following function vr >=20 > function vr () {=20 > gvim.exe $($(history -1 | sed "s/^ *[0-9]* *//g")) & > } >=20 > This does the trick, but how would you zedii do it? function VR() { BUFFER=3D'gvim.exe $(!!)'=20 } zle -N VR bindkey vr VR Ciao, Thomas --=20 Thomas K=F6hler Email: jean-luc@picard.franken.de <>< WWW: http://gott-gehabt.de IRC: tkoehler PGP public key available from Homepage! --fdj2RfSjLxBAspz7 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (GNU/Linux) iD8DBQFBq39dTEYXWMJlHuYRAl6sAJ93ITlBMiXtLMjFe8uL58SQD6g45QCdF5aY vz0oFcOvCQuUhnmfJYhjnMQ= =Ex8H -----END PGP SIGNATURE----- --fdj2RfSjLxBAspz7--