Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 18 Sep 2006 20:00:08 -0300
From:      Fernan Aguero <fernan@iib.unsam.edu.ar>
To:        MC <rossiya@gmail.com>
Cc:        freebsd-ports@freebsd.org
Subject:   Re: Basic Diff question
Message-ID:  <20060918230008.GB89966@iib.unsam.edu.ar>
In-Reply-To: <28a99ba50609181526s6a3ab59btfca1d6517b89c951@mail.gmail.com>
References:  <28a99ba50609181526s6a3ab59btfca1d6517b89c951@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
+----[ MC <rossiya@gmail.com> (18.Sep.2006 19:47):
|
| Hello
| 
| I am getting going on my second port.  However in this new one are many
| little patches
| to most of the source code.  I always see '.orig' suffixes appended to in
| Freebsd diff files, like
| 
| --- Src/DasherCore/FileLogger.cpp.orig Tue Jan 17 01:41:44 2006
| +++ Src/DasherCore/FileLogger.cpp Tue Jan 17 01:51:33 2006
| 
| but for the life of me I don't know a way to produce these '.orig' suffixes
| in the patch file other than
| hand editing.  
+----]

cp file file.orig
edit file, fix things, hack away, and when you're done
diff -u file.orig file

will produce the kind of output you see all over the place
in the FreeBSD repo.

Using .orig it's just a matter of taste ... you can follow
what most freebsd people do ... but you can use .bak, .old
or whatever you want, provided you supply the old/bak/orig
file first to diff ...

The thing is that having the old file associated with '---' and
the new file with '+++' makes one more comfortable, as
things that got added in the new version of the file will
get labeled by diff as '+', and things that got deleted in
the new version will be shown as present in the old version (as '-').

Hope this makes it clearer for you,

Fernan



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060918230008.GB89966>