This has definitely worked in the past. Fish has a fairly complex completion system that 'knows' about lots of commands (and can infer arguments from manpages too iirc), so it can predict what arguments will work (never 100% accurate)
On Mon, Nov 3, 2014 at 10:06 AM, Santhosh T <santhosh.tek...@gmail.com> wrote: > the article http://lwn.net/Articles/136232/ says that > fish shell can show misspelled options as errors. > > it has a screenshot also where "--colour" is highlighted in red in "ls > --colour" command. > > > > when I tried the same, it didn't work. > > so i asked the question.... > > - santhosh > > > > On Mon, Nov 3, 2014 at 2:39 PM, Cedric Auger <sedri...@gmail.com> wrote: > >> >> >> 2014-10-31 17:58 GMT+01:00 Santhosh T <santhosh.tek...@gmail.com>: >> >>> when i type "ls --unknownoption" >>> >>> i am expected "--unknownoption" to be shown in red. >>> >>> fish only showing wrong commands in red color, but not wrong options >>> >>> i already did run "fish_update_completions" >>> >>> I am using MAC >>> >>> thanks >>> Santhosh >>> >>> >>> >> I first glance, I would say, that it is not a realistic feature. >> How could you tell if a given option is a right or a wrong one? >> >> For the command, work is easy: just ask the file system is there is such >> an executable program. >> But there is no Unix command which tells given a program and options if >> they are compatible. >> Of course, like autocompletion, you could forbid some options (but that >> would concern only very specific programs for which the set of "good" >> options can be easily known). >> Plus there should be some clever parsing, as for example "ls -- >> --unknownoption" is a valid command (at least on the Ubuntu version I have). >> That is because I can create a file named "--unknownoption". >> >> >> -- >> .../Sedrikov\... >> > > > > ------------------------------------------------------------------------------ > > _______________________________________________ > Fish-users mailing list > Fish-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/fish-users > >
------------------------------------------------------------------------------
_______________________________________________ Fish-users mailing list Fish-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/fish-users