Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: completion for compilers (cc, gcc...) and -o



On 2020-04-30 13:32:25 -0700, Bart Schaefer wrote:
> On Thu, Apr 30, 2020 at 1:18 PM Vincent Lefevre <vincent@xxxxxxxxxx> wrote:
> >
> > (perhaps this should be configurable by the user) for -o:
> 
> Hmm, people seem not to have seen my zstyle example?

I did, and tested it. Thanks a lot. A few comments:

It worked only with "gcc". I've changed it to use

  ":completion::complete:(c99|cc|gcc*):option-o-1:"

together with

  compdef c99=gcc

to support the c99 utility.

Now I'm wondering whether there is a way to automatically apply
the zstyle to the _gcc command list (I also sometimes use clang
and so on).

I was also wondering whether there is a way to get the extension
list automatically from the one in _gcc (assuming that it could
evolve[*]).

[*] On this subject, I'm quite sure I've already used the .cpp
extension. I do not program in C++, but sometimes have to do
some tests of small examples... I think that it should be added
to the standard list, but C++ programmers may tell you more.

-- 
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)



Messages sorted by: Reverse Date, Date, Thread, Author