Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: support more arguments to diff
- X-seq: zsh-workers 42680
- From: Eitan Adler <lists@xxxxxxxxxxxxxx>
- To: Oliver Kiddle <okiddle@xxxxxxxxxxx>
- Subject: Re: support more arguments to diff
- Date: Wed, 18 Apr 2018 02:36:23 -0700
- Cc: Zsh hackers list <zsh-workers@xxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=LcozQLC9WURR40pVY60h9KPk57M5+5HxHLNlvJtFJZY=; b=bQBm/qijapUbR4e4HmTvOlHQBWHIU/zI6COT7VfH8Y/8TLBGWmj01DjsZO6cRIxrM+ /FW4MR6f8R9WU8cgF2E6dLF/eIrjGLIMbSqs3YKoxgqM+OCTgMP6LsmAjLpz4RMCTfNB A7BoJnmnjtc0fFygYHQEnpqFqrGIaYKeHKXvc=
- In-reply-to: <15398.1524043378@thecus>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CAF6rxgmh+N8VdjzN-jGA4QHPJANLkMJ-JZXChb-28DZxxLVa7Q@mail.gmail.com> <20180416145913.wv637mfnw5hfe2fi@Daniels-MacBook-Air.local> <CAF6rxgkmqUbAivhR6c3=RK4U_F2gY3ybebAjLgBnuqSmCyneeQ@mail.gmail.com> <20180417125307.GA34493@CptOrmolo.darkstar> <CAF6rxgnKzGGbRiBYqWZ_8rApFM_8xKjB9A+_3j9PDk9skPTuFQ@mail.gmail.com> <15398.1524043378@thecus>
On 18 April 2018 at 02:22, Oliver Kiddle <okiddle@xxxxxxxxxxx> wrote:
> Eitan Adler wrote:
>> >> I'd also like to port this particular diff implementation to the other
>> >> BSDs, hence adding all of them to the case statement.
>> >
>> > I think it would be best to add the other cases as each BSD adopts
>> > whichever diff. I generally try to update the completion to match
>> > -current, so when a new release is picked up the options are correct.
>>
>> I also wonder if we could just get rid of the OS test and replace it
>> with a pure version test. What if we run different verrsions than the
>> default?
>
> Yes, detecting the version first is usually best. Arguably, this is what
> we already do with $OSTYPE being a fallback; we have:
>
> _pick_variant -c $cmd gnu=GNU unix -v
>
> Does this new diff produce a helpful signature by which it can be
> identified if run as diff -v
Annoyingly no, but that seems easy to fix.
∴diff -V
diff: invalid option -- V
> I'm not fond of the patch in the form that was posted.
What about just adding FreeBSD then?
> If you want a temporary workaround while using 12-CURRENT, I'd recommend
> setting: _cmd_variant[diff]=gnu
I'll use that for now.
--
Eitan Adler
Messages sorted by:
Reverse Date,
Date,
Thread,
Author