mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Willy Tarreau <willy@w.ods.org>
To: 7eggert@nurfuerspam.de
Cc: Russell King <rmk+lkml@arm.linux.org.uk>,
	Gene Heskett <gene.heskett@verizon.net>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Re: diff command line?
Date: Sat, 5 Mar 2005 22:08:50 +0100	[thread overview]
Message-ID: <20050305210850.GI30106@alpha.home.local> (raw)
In-Reply-To: <E1D7gBd-0000q3-3G@be1.7eggert.dyndns.org>

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


  reply	other threads:[~2005-03-05 21:14 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <fa.jshi2h6.1g20sjc@ifi.uio.no>
     [not found] ` <fa.h6jj2d8.143utbu@ifi.uio.no>
2005-03-05 20:47   ` Bodo Eggert
2005-03-05 21:08     ` Willy Tarreau [this message]
2005-03-05 21:53       ` Gene Heskett

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050305210850.GI30106@alpha.home.local \
    --to=willy@w.ods.org \
    --cc=7eggert@nurfuerspam.de \
    --cc=gene.heskett@verizon.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rmk+lkml@arm.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®