On 04/06/10 12:39, Michael Lachmann wrote:
> I think that fish should know what to expand, and what not. Just like
> it should know what to complete and what not. Then, 'scp host:file* .'
> will not expand, and maybe even
> grep *file file.c

oh neat -- "Just like it should know what to complete and what not" -- 
this means that it's a function of the "tab" key and not a function of 
the shell interpreter!  (the interpreter promises not to behave 
differently for different command-names; the tab-completion makes no 
such promise, yielding some convenience and some woe...).  Thus, if you 
pressed tab on a particular argument to a particular command, an 
argument that was not expected to contain filenames at all (especially 
not multiple filenames), then it could quote any stars you'd typed into 
that argument (backslash is the usual quoting created by 
tab-completion... or possibly to put single or double quote-marks around 
the whole argument, but that doesn't always work the way you'd want). 
Not sure if it should depend at all on whether any of those files that 
are technically referenced by the stars actually exist (e.g., .*file 
refers to filenames beginning with '.' and ending with 'file').

Not only the tab-completion, also the syntax coloring could turn an 
argument red if it contained unquoted stars where it shouldn't, as it 
does for things like `ls --not-an-argument-to-ls`... It seems 
underlining existent filenames might be another route that could be used 
too, although it seems to be avoided when they contain stars, perhaps 
because that makes the calculation potentially rather slow

-Isaac

------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Fish-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to