[Bash-completion-devel] Bug#503691: bash-completion: does not complete files and directories as arguments

David Paleino d.paleino at gmail.com
Fri Oct 31 21:46:13 UTC 2008


On Fri, 31 Oct 2008 22:16:22 +0100, David Paleino wrote:

> On Mon, 27 Oct 2008 16:52:29 +0100, Norbert Preining wrote:
> 
> > Example:
> > [..]
> > Same with our TeX packing scripts:
> > 	perl tpm2deb-source.pl make-orig-tar --master=/src/TeX/Mas<TAB>
> > or
> > 	perl tpm2deb-source.pl make-orig-tar --master /src/TeX/Mas<TAB>
> > in both cases it never completes to /src/TeX/Master-2007.0 which is
> > there.
> > 
> > I assume that in lack of any information, in former times bash
> > completion did path name completion, but now it does nothing. That is
> > not good.
> 
> Yes, right.
> I've just tried with a non-existant command, and...
> 
> [..]
> 
> it seems working, really.

It seems working also with a simple Perl script:

$ cat /tmp/foo.pl 
#!/usr/bin/perl
use Getopt::Std;

%opts=();
getopts("f:",\%opts);

print "-f $opts{f}\n" if defined $opts{f};
$

$ perl /tmp/foo.pl -f /t<TAB>
$ perl /tmp/foo.pl -f /tmp/<TAB>
claws-mail-1000        kde-neo/               ssh-fEkPrD3081/
foo.pl                 ksocket-neo/           .X0-lock
Galaxium/              orbit-neo/             .X11-unix/
gconfd-neo/            plugtmp/               .xfsm-ICE-07FKJU
gpg-YWdQy5/            pulse-L9K88eMlGn7C/    
.ICE-unix/             serverauth.kTXVHqDjyx  
$ perl /tmp/foo.pl -f /tmp/f<TAB>
$ perl /tmp/foo.pl -f /tmp/foo.pl 
-f /tmp/foo.pl
$

> However, with existing commands it does not work, as you reported. I'll take a
> look at it, :)

"perl" is obviously an existing command. And my line seems totally similar to
the one you reported. I'll continue having a look :)

Kindly,
David

-- 
 . ''`.  Debian maintainer | http://wiki.debian.org/DavidPaleino
 : :'  : Linuxer #334216 --|-- http://www.hanskalabs.net/
 `. `'`  GPG: 1392B174 ----|---- http://snipr.com/qa_page
   `-   2BAB C625 4E66 E7B8 450A C3E1 E6AA 9017 1392 B174
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
Url : http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20081031/5f0dc6a1/attachment-0001.pgp 


More information about the Bash-completion-devel mailing list