bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-bash] Re: Completion in bash


From: Chet Ramey
Subject: [Bug-bash] Re: Completion in bash
Date: Fri, 15 Sep 2000 11:07:21 -0400

>    I don't like the way bash completes things for me and I want to
> change it.  I went through the info and man pages but I still couldn't
> figure it out.
> 
>    Here's how my completion works now: Let's use filename completion
> as an example and let's assume I have the files `foo.bar.1',
> `foo.bar.2', `foo.bar.3', and `foo.bar.4' in the working directory,
> along with a bunch of other files that do not begin with `foo'.  Now,
> when I type `ls foo<TAB>' at the command prompt, the shell prints out
> a list of all possible file completions (so, four file names in this
> case), and then the command prompt has `ls foo.bar.' and waits for me
> to finish.  I want to change this behaviour but I don't know how.

You probably have the `show-all-if-ambiguous' readline variable set.
Type `bind -v' and see if it is.

>    I want completion to work the way my emacs completion works.
> Here's what I mean: After I type `ls foo<TAB>' I don't want the shell
> to print out all possible completions.  Instead, I just want the shell
> to expand the command to `ls foo.bar.' and wait for further input.

This is the default behavior, which is modified by the aforementioned
readline variable.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
( ``Discere est Dolere'' -- chet)

Chet Ramey, CWRU    address@hidden    http://cnswww.cns.cwru.edu/~chet/


reply via email to

[Prev in Thread] Current Thread [Next in Thread]