I guess what's confusing is the talk about token types, which is are
apparently something specific to Fish and not explained in the manual.
Why doesn't the message just say
fish: Expected redirection specification, got "\n" (newline)
echo > (echo)
^
or
fish: Invalid file name "" for output redirection
echo > (echo -n)
^
I think the error message repeats the problematic token so that the
user can see it. If it said 'Can't redirect to ""', the user would
wonder which part of the command she typed produced the "". But the
message needs to say that the token expands to "" or to newline, which
are invalid file names. And it does not need to mention tokens.
What do you suggest the messages should be?
On 6/5/08, Isaac Dupree <[EMAIL PROTECTED]> wrote:
> > set filename abcde
> > set --erase not_a_filename
>
> > echo out > $filename
> > rm $filename
> > #given that, this is weird:
> > echo out > $not_a_filename
> fish: Expected redirection specification, got token of type
> "$not_a_filename"
> echo out > $not_a_filename
> ^
>
> > echo out > (echo $filename)
> > rm $filename
> > echo out > (echo $not_a_filename)
> fish: Invalid IO redirection
> echo out > (echo $not_a_filename)
> ^
> > echo out > (echo)
> fish: Invalid IO redirection
> echo out > (echo)
> ^
> > echo out > (echo -n)
> fish: Expected redirection specification, got token of type "(echo -n)"
> echo out > (echo -n)
> ^
>
> Hmm. I'm a little confused (although luckily it seems to be only the
> messages that are confusing me -- it seems quite sensible so far in
> *whether* it accepts a redirection)
>
> -Isaac
>
> -------------------------------------------------------------------------
> Check out the new SourceForge.net Marketplace.
> It's the best place to buy or sell services for
> just about anything Open Source.
> http://sourceforge.net/services/buy/index.php
> _______________________________________________
> Fish-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/fish-users
>
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
Fish-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fish-users