zsh-users
 help / color / mirror / code / Atom feed
From: Eric Smith <Eric.Smith@fruitcom.com>
To: Zsh Users <zsh-users@sunsite.dk>
Subject: Re: preexec function to work after `&&' -> tab completion for preexec
Date: Mon, 8 Sep 2003 22:21:54 +0200	[thread overview]
Message-ID: <20030908202152.GC23793@fruitcom.com> (raw)
In-Reply-To: <20030908191720.GR6280@strindberg.student.uu.se>

Hi

Alas I cannot take credit for this mimecap for the command line,
that is due to the redoubtable Bart Schaefer who replied to a
question I posted on the list.  I just brainlessly extended it.

I use it constantly with screen(1) cutting and pasting and
could not imagine life without it.  I have some function like
print -l (#i)*$1*
print matching files and then move up in screen copy mode to
the wanted file and hit a button and the file is pasted onto
the command line with enter automatically appended and the file
opens with its associated application.  (This is made practical
by my quirky policy of not using subdirs much and having all files
in a single dir - using `_' to give descriptive "classes" to filenames).

Thanks Jesper for asking the question about completion.  Its been on the tip of my
tongue for months - just did not get round to posting it.

ciao

> > fi
> > 
> 
> I only now found the time to experiment with Eric's neat preexec function,
> and it's very nice. However, I'd like it to also work with tab completion,
> is that possible?
> 
> I.e. say I have a file in my current directory called "foo.pdf". Writing
> "./foo.pdf" on the command line starts acroread with the file as an
> argument, just as I wanted, but I cannot type "./fo<tab>" and have a
> completion of the file name. I'm not even sure this would be desirable in
> the general case, as I'm normally not interested in completing regular
> files in the first position, but would it be possible to for example
> specify that files in the current directory should be completed? Or is
> there a better way to solve this problem that I haven't thought about?
> 
> TIA,
> 
> Jesper
> 
> 
> -- 
>           Jesper Holmberg            |"But how can |
>   jesper.holmberg@enst-bretagne.fr   | one be warm |
> ENST Br, BP 832, 29285 Brest, FRANCE | alone?"     |

-- 
Eric Smith
Fruitcom BV 
Tel: +31 15 750 2364
Fax: +31 15 219 0524
Mobile: +31 6 551 76300
PO Box 2855 
2601 CW Delft 
The Netherlands


  reply	other threads:[~2003-09-08 20:28 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-08-13 13:14 preexec function to work after `&&' Eric Smith
2003-08-13 15:16 ` Oliver Kiddle
2003-09-08 19:17 ` Jesper Holmberg
2003-09-08 20:21   ` Eric Smith [this message]
2003-09-10  7:51   ` Oliver Kiddle

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030908202152.GC23793@fruitcom.com \
    --to=eric.smith@fruitcom.com \
    --cc=zsh-users@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).