zsh-users
 help / color / mirror / code / Atom feed
From: John Buttery <john@io.com>
To: zsh-users@sunsite.dk
Subject: Re: M-. should bring back last arg of prev cmd
Date: Wed, 20 Mar 2002 01:53:43 -0600	[thread overview]
Message-ID: <20020320075343.GA19963@io.com> (raw)
In-Reply-To: <20020320061600.GF878@acay.com.au>

[-- Attachment #1: Type: text/plain, Size: 1389 bytes --]

* Nick Croft <nicko@acay.com.au> [2002-03-20 17:16:00 +1100]:
>Hi. Another question. You help has been much appreciated.
>
>I learnt in an article by Dominic Mitchell "A Case for the Z Shell",
>that M-. can be used as a shortcut for the last argument of the previous
>command.
[snip]
>Question: Is this dependent on some setting in the .zshrc, or a setopt
>command? I had it working a few days ago. I think it's the greatest
>thing since sliced bread. 
>
>But it's gone, and I suspect I've overridden whatever it depended on.

  Well, I'm pretty new to zsh, but I may be able to field this one.  

% bindkey ^[.
"^[." insert-last-word
%

  So it looks like you just need to run something like:

bindkey "^[." insert-last-word

  Note that the ^[ represents an actual escape character.  So before you
hit M-. you need to hit Ctrl-v so zsh inserts it literally.
  By the way, thanks for pointing out this feature!

  Oh, and while I'm posting anyway, is there a way to disable zsh's
reports that mail has been read in a mailbox?  I don't want to disable
the reports of _new_ mail, just the ones where it says "the mail in xyz
has been read".

  Hmm, looks like I managed to break my sig rotation script.  Maybe I
shouldn't have switched interactive-use shell, scripting shell, and
editor at the same time.  :)

-- 
This block should never execute.  Bug!

[-- Attachment #2: Type: application/pgp-signature, Size: 232 bytes --]

  reply	other threads:[~2002-05-17 10:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-03-20  6:16 Nick Croft
2002-03-20  7:53 ` John Buttery [this message]
2002-03-20 16:16 ` Bart Schaefer

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=20020320075343.GA19963@io.com \
    --to=john@io.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).