This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: To continue file name


Alex Vinokur wrote:
> "Dave Korn" wrote in message
> SERRANOyFrydlb9rXg5000001e7@SERRANO.CAM.ARTIMI.COM">news:SERRANOyFrydlb9rXg5000001e7@SERRANO.CAM.ARTIMI.COM... 
>> Alex Vinokur wrote:
>>> Hi,
>>> 
>>> For instance, directory contains files abcd, xyz, f123.
>>> For instance, I print 'a' and don't want to print 'bcd'.
>>> How can Cygwin continue file name automatically.
>> 
>>   In bash shell, you just press TAB to complete the filename. [snip]
> 
> I tried to do that. Doesn't work.

  It does.  However, it's a bit context sensitive.  If it's the first word on
a line, it assumes it has to be a command, so unless the directory is in your
$PATH, or you type "./a" and then press TAB (and 'abcd' has to have the 'x'
flag), it will assume that you can't mean that particular file because it
wouldn't be the valid start to a line.

  Also, if there's more than one possibility, you can press TAB twice and it
will list all the options.

  Let me demonstrate:

dk@espanola /tmp/tab> ls -la
total 0
drwxr-xr-x+ 2 dk Domain Users 0 Nov  7 18:49 .
drwxrwxrwt+ 4 dk Domain Users 0 Nov  7 18:49 ..
-rw-r--r--  1 dk Domain Users 0 Nov  7 18:49 abcd
-rw-r--r--  1 dk Domain Users 0 Nov  7 18:49 f123
-rw-r--r--  1 dk Domain Users 0 Nov  7 18:49 xyz
dk@espanola /tmp/tab> a                       [PRESS TAB TWICE]
Display all 353 possibilities? (y or n)       [PRESS CTRL-C]
dk@espanola /tmp/tab> ./a                     [PRESS TAB TWICE: NOTHING
HAPPENS]
dk@espanola /tmp/tab> chmod a+x abcd
dk@espanola /tmp/tab> ./a[PRESS TAB - COMPLETION ADDS ]bcd

> Should one set some Cygwin-variable?

  See "info readline" for full deatils.


    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]