Axel Liljencrantz wrote:
> As to the original question, I see your point, but allowing variables in
> command names would be impossible to do for many builtins, e.g. those that
> open a block, and I strongly dislike the concept of elevating some/all
> buitins in fish to some magical 'keyword' status where they work
> differently from the rest of all commands. The emphasis on making
> everything into a command and making all commands obey the same rules
> whenever possible is something I feel needs to be protected as far as
> possible.

right now though, "block" based keywords like "begin" and "end" are too 
magical; you can't do "begin --help" (after all, the syntax "begin --help; 
end" is equivalent to "--help", yielding
>fish: Unknown command “--help”
).  Using these builtins makes me feel like I'm using parentheses that have 
funny-looking names.

But I see what inconsistency you're bothered by; you don't want this to search 
PATH for begin:
>set foo begin; $foo
and you also don't want to encourage practice like a script "runme" (e.g. 
`runme echo` or `runme begin`
>#!/usr/bin/env fish
>$argv[1]
where obviously a builtin should never be used and it's meant to search PATH. 
(reminds me of Perl's "taint" concept that is stricter about data that comes 
from outside of the script file.)

> To be perfectly honest, I sometimes play with the thought of making a new
> fish syntax, one with closures, macros and other things that no sane person
> would ever put in a command line shell. Would be kind of cool...

and is the sort of thing that is not just achieved by hacking, it needs a 
community behind it to be much use.

-Isaac


------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Fish-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to