zsh-users
 help / color / mirror / code / Atom feed
From: kamaraju kusumanchi <raju.mailinglists@gmail.com>
To: Zsh Users <zsh-users@zsh.org>
Subject: Re: tab completion sort by modification time
Date: Mon, 12 Jan 2015 00:58:07 -0500	[thread overview]
Message-ID: <CABpbYaeyXvROFcfb2c7MMjEaf9wF-YkGivP1RM-f5fmjxgxKwQ@mail.gmail.com> (raw)
In-Reply-To: <CABpbYadfrByb1efj2vksRNpEVgmQHimK_a0ja9chTthGQh-m=g@mail.gmail.com>

On Sat, Jan 10, 2015 at 11:40 PM, kamaraju kusumanchi
<raju.mailinglists@gmail.com> wrote:
> On Sat, Jan 10, 2015 at 2:52 PM, Eric Cook <llua@gmx.com> wrote:
>> You can also reverse the order:
>> zstyle ':completion:*' file-sort 'reverse modification'
>
> I confirm that this line is all I needed to get what I am after. But
> thanks to all other tidbits. They will all be useful as I get more
> experience with Z shell.
>
> raju

So I have been experimenting with zsh and I found one feature that I
really like. The shell cleans up the tab completions once it is
completed.

For example, say I have

rajulocal@hogwarts ~/x % ls file*
file10.txt  file11.txt  file12.txt  file13.txt  file1.txt  file2.txt
file3.csv  file4.csv  file5.tsv  file6.tsv  file7.txt  file9.txt

Now, I can bring up a list of possible completions by <tab>

rajulocal@hogwarts ~/x % ls file<tab>
Completing files
file2.txt    file4.csv    file6.tsv    file7.txt    file10.txt
file12.txt
file3.csv    file5.tsv    file1.txt    file9.txt    file11.txt
file13.txt*

and when I enter 12.txt, the list completely disappears.

rajulocal@hogwarts ~/x % ls file12.txt
file12.txt

That is pretty impressive and something I always wanted to do in bash.

raju
-- 
Kamaraju S Kusumanchi
http://malayamaarutham.blogspot.com/


  reply	other threads:[~2015-01-12  5:58 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-10 19:33 kamaraju kusumanchi
2015-01-10 19:52 ` Eric Cook
2015-01-11  4:40   ` kamaraju kusumanchi
2015-01-12  5:58     ` kamaraju kusumanchi [this message]
2015-01-10 20:11 ` Peter Stephenson
2015-01-10 20:30   ` Mikael Magnusson
2015-01-10 22:08     ` kamaraju kusumanchi

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=CABpbYaeyXvROFcfb2c7MMjEaf9wF-YkGivP1RM-f5fmjxgxKwQ@mail.gmail.com \
    --to=raju.mailinglists@gmail.com \
    --cc=zsh-users@zsh.org \
    /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).