On 10/4/06, Axel Liljencrantz <[EMAIL PROTECTED]> wrote: > On 10/2/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > On 9/28/06, Myrddin Emrys <[EMAIL PROTECTED]> wrote: > > > On 9/28/06, Philip Ganchev <[EMAIL PROTECTED]> wrote: > > > > On 9/22/06, Myrddin Emrys <[EMAIL PROTECTED]> wrote: > > > Yes, a set of switches that work together, separate from other > > > switches. An example is the Gentoo utility 'emerge', or the Redhat > > > utility 'rpm'. They have modes with completely separate functionality, > > > and switches that only apply to one mode or the other. Another example > > > might be the old DOS pkzip app, which had zipping and unzipping in one > > > command (unlike the freenix convention of separating the two apps). > > > > As I understand, ``complete'' cannot capture those anyway, so you > > don't lose anything. > > It can and it does. For a simple example, try to complete the command > 'set LANG en_', and you will get a list of english locales. Try > completing 'set fish_color_pwd b' and you will get a list of colors > beginning with 'b'. Other commands that do this include 'rpm', > 'darcs', 'cvs' and 'svn'.
Oh, I did not see that in the help. So how can I specify that you can't write ``set --local --global x y''? I think that's what Myrddin meant. > Also, the completions for commands which run other commands, like > 'time' or 'sudo' use this kind of functionality as well. > > > > > Ideally, ``complete'' should be able to understand a synopsys of a > > command. Then the synopsis itself can be automatically parsed from > > the man page too. > > The synopsis is already in the whatis database, so there should be no > need for this. Oh, good. I'd like to think you mean no need for parsing, but I have a nagging suspicion that you mean no need for complete to understand the synopsis. I was thinking the synopsys would be useful in two ways. 1. "compete" would know exactly what combinations and order of options are acceptable. People have gone to the trouble of defining and documenting this, why not use it interactively? 2. while entering options of a command, the user would see what order and combinations of optoins are allowed. It's the same benefit as in the man page but much more handy since the user does not have to interrupt entering the command to invoke ``man''. ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Fish-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/fish-users
