twaugh / patchutils

Manipulate patch files
GNU General Public License v2.0
139 stars 22 forks source link

-x $file only removes the diff body from git diff output #27

Open brianjmurrell opened 5 years ago

brianjmurrell commented 5 years ago
git diff v3.3..HEAD | filterdiff -p 1 -x README.vin
...
diff --git a/README.vin b/README.vin
index d7a1ea2..7c298d7 100644
diff --git a/autogen.sh b/autogen.sh
...

Leaving those two lines in confuses patch:

The text leading up to this was:
--------------------------
|diff --git a/README.vin b/README.vin
|index d7a1ea2..7c298d7 100644
--------------------------
File to patch: