Re: Manual says "diff -uR" but macOS diff doesn't support "-R"

2019-08-11 Thread Ryan Schmidt



On Aug 11, 2019, at 14:37, Andrew Udvare wrote:

> On Aug 11, 2019, at 14:52, Gerben Wierda wrote:
>> 
>> The manual says:
>> 
>> diff -uR $(port dir $portname) . > change-$portname-maintainer.diff
>> 
>> However, macOS Mojave’s diff doesn’t understand that. -R is an invalid 
>> option. I’m not going to guess here, so what is it supposed to be?
> 
> Install coreutils and then run gdiff.


coreutils does not provide diff or gdiff. diffutils does. But there's no need 
to install this version of diff unless you really want it.

> I believe on BSD diff it's -r.

The manual of diffutils' diff doesn't mention a -R option either; it only 
mentions -r.

Whoever put that in our documentation probably got confused and was thinking of 
cp, which has a deprecated -r option and where you should use -R instead.

I've fixed our documentation.

https://github.com/macports/macports-guide/commit/05aab42697a585ed32604b101397393ac16114f1



Re: Manual says "diff -uR" but macOS diff doesn't support "-R"

2019-08-11 Thread Andrew Udvare



-- 
Andrew Udvare


> On 2019-08-11, at 15:44, Bill Cole 
>  wrote:
> 
> I feel quite safe guessing that since the argument is a directory, it's a 
> simple capitalization error, and should be 'r' instead of 'R'

I was thinking the same thing. I'm so used to typing diff -urN so often I never 
really noticed.



Re: Manual says "diff -uR" but macOS diff doesn't support "-R"

2019-08-11 Thread Bill Cole

On 11 Aug 2019, at 14:52, Gerben Wierda wrote:

Busy adopting nsd (currently no maintainer). I have created a Portfile 
for the last version and added Startupitem statements. Everything 
works here.


The manual says:

diff -uR $(port dir $portname) . > change-$portname-maintainer.diff

However, macOS Mojave’s diff doesn’t understand that. -R is an 
invalid option.


It's not valid in any common variety of diff.


I’m not going to guess here, so what is it supposed to be?


I feel quite safe guessing that since the argument is a directory, it's 
a simple capitalization error, and should be 'r' instead of 'R'


--
Bill Cole
b...@scconsult.com or billc...@apache.org
(AKA @grumpybozo and many *@billmail.scconsult.com addresses)