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: > > > > I have only one problem with those two methods Ben... neither will > > > > capture command modes, and unfortunately that means that users who > > > > clean up the docs will probably not add those in either. > > > > > > > > I would advocate a tool that does 2 interactively, on the command > > > > line, and then reminds you or asks you about switches into modes... or > > > > even walks you through it. > > > > > > Sorry, what is a command mode, as opposed to an ordinary switche, > > > which changes the behavior of the command? Is it a set of switches > > > which are specified together but without other switches? > > > > > > [rearranged] > > 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'. 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. -- Axel ------------------------------------------------------------------------- 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
