0

I generated a patchfile of 2 directories using this command:

diff -ur source-20110125 source > mailpatch3.patch

Now I would like to apply the patch, doing this:

patch -p1 < mailpatch3.patch

But it then asks me for the file to patch. Why?

Something that looks strange to me in the patch file: there are a lot of "common subdirectories" lines. Like this:

Common subdirectories: source-20110125/ac_depository and source/ac_depository
Common subdirectories: source-20110125/ac_depository_jar and source/ac_depository_jar
Common subdirectories: source-20110125/_backoffice and source/_backoffice
Common subdirectories: source-20110125/_csvexport and source/_csvexport
Common subdirectories: source-20110125/_foundation and source/_foundation
Common subdirectories: source-20110125/_impex and source/_impex

And I don't really know why they're there.

The rest of the patch looks normal.

Jelle De Loecker
  • 1,055
  • 6
  • 16
  • 29

1 Answers1

0

Most likely you have the wrong -p setting for trimming prefixes from your paths. If you were below the two source directories when generating the patch, then you should be inside the source directory to apply the patch with -p1.

beans
  • 1,550
  • 13
  • 16