* [PATCH] Re: diff command line?
[not found] ` <fa.h6jj2d8.143utbu@ifi.uio.no>
@ 2005-03-05 20:47 ` Bodo Eggert
2005-03-05 21:08 ` Willy Tarreau
0 siblings, 1 reply; 3+ messages in thread
From: Bodo Eggert @ 2005-03-05 20:47 UTC (permalink / raw)
To: Russell King, Gene Heskett, linux-kernel
Russell King <rmk+lkml@arm.linux.org.uk> wrote:
> On Sat, Mar 05, 2005 at 10:48:00AM -0500, Gene Heskett wrote:
>> What are the options normally used to generate a diff for public
>> consumption on this list?
>
> diff -urpN orig new
>
> where "orig" and "new" both contain the top level "linux" directory,
> so the resulting patch can be applied with patch -p1.
This seems to be a common mistake.
Signed-Off-By: Bodo Eggert <7eggert@gmx.de>
--- linux-2.6.11/Documentation/SubmittingPatches.ori 2005-03-05
21:29:26.000000000 +0100
+++ linux-2.6.11/Documentation/SubmittingPatches 2005-03-05
21:38:40.000000000 +0100
@@ -24,6 +24,7 @@ SECTION 1 - CREATING AND SENDING YOUR CH
------------
Use "diff -up" or "diff -uprN" to create patches.
+The resulting patch must apply with -p1 from within the linux directory.
All changes to the Linux kernel occur in the form of patches, as
generated by diff(1). When creating your patch, make sure to create it
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Re: diff command line?
2005-03-05 20:47 ` [PATCH] Re: diff command line? Bodo Eggert
@ 2005-03-05 21:08 ` Willy Tarreau
2005-03-05 21:53 ` Gene Heskett
0 siblings, 1 reply; 3+ messages in thread
From: Willy Tarreau @ 2005-03-05 21:08 UTC (permalink / raw)
To: 7eggert; +Cc: Russell King, Gene Heskett, linux-kernel
On Sat, Mar 05, 2005 at 09:47:44PM +0100, Bodo Eggert wrote:
> Russell King <rmk+lkml@arm.linux.org.uk> wrote:
> > On Sat, Mar 05, 2005 at 10:48:00AM -0500, Gene Heskett wrote:
>
> >> What are the options normally used to generate a diff for public
> >> consumption on this list?
> >
> > diff -urpN orig new
> >
> > where "orig" and "new" both contain the top level "linux" directory,
> > so the resulting patch can be applied with patch -p1.
>
> This seems to be a common mistake.
I often use a simple trick to make my single file patches compatible
with both -p0 and -p1 :
diff -pruN ./dir/file.orig ./dir/file.new
The './' can either get stripped by -p1 or left as is, thus the patch
works for different scripts or people. The main disadvantage is that
there's no base version indication in the patch with this method.
Regards,
Willy
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Re: diff command line?
2005-03-05 21:08 ` Willy Tarreau
@ 2005-03-05 21:53 ` Gene Heskett
0 siblings, 0 replies; 3+ messages in thread
From: Gene Heskett @ 2005-03-05 21:53 UTC (permalink / raw)
To: linux-kernel
On Saturday 05 March 2005 16:08, Willy Tarreau wrote:
>On Sat, Mar 05, 2005 at 09:47:44PM +0100, Bodo Eggert wrote:
>> Russell King <rmk+lkml@arm.linux.org.uk> wrote:
>> > On Sat, Mar 05, 2005 at 10:48:00AM -0500, Gene Heskett wrote:
>> >> What are the options normally used to generate a diff for
>> >> public consumption on this list?
>> >
>> > diff -urpN orig new
>> >
>> > where "orig" and "new" both contain the top level "linux"
>> > directory, so the resulting patch can be applied with patch -p1.
>>
>> This seems to be a common mistake.
>
>I often use a simple trick to make my single file patches compatible
>with both -p0 and -p1 :
>
>diff -pruN ./dir/file.orig ./dir/file.new
>
>The './' can either get stripped by -p1 or left as is, thus the
> patch works for different scripts or people. The main disadvantage
> is that there's no base version indication in the patch with this
> method.
>
>Regards,
>Willy
Neat, Willy. Are such patches generally acceptable here?
--
Cheers, Gene
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
99.34% setiathome rank, not too shabby for a WV hillbilly
Yahoo.com attorneys please note, additions to this message
by Gene Heskett are:
Copyright 2005 by Maurice Eugene Heskett, all rights reserved.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-03-05 21:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <fa.jshi2h6.1g20sjc@ifi.uio.no>
[not found] ` <fa.h6jj2d8.143utbu@ifi.uio.no>
2005-03-05 20:47 ` [PATCH] Re: diff command line? Bodo Eggert
2005-03-05 21:08 ` Willy Tarreau
2005-03-05 21:53 ` Gene Heskett
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®