leopoodle
leopoodle

Reputation: 2482

Patch file includes the git version at the end

git format-patch puts the git version at the end like this:

From b2df28155560c68772063df3b3250d811e66f35e Mon Sep 17 00:00:00 2001
From: Prem Sichanugrist <[email protected]>
Date: Mon, 25 Jan 2016 18:18:38 -0500
Subject: [PATCH 1/2] Update build matrix

Build Appraisal against these versions of Ruby

... snip ...

---
 .travis.yml | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index 6b56084..52d0bff 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -3,12 +3,12 @@ sudo: false
 before_install: gem install bundler

 rvm:
-  - 1.8
-  - 1.9
-  - 2.0
-  - 2.1

... snip ...

--
2.7.0

This patch is copied from https://thoughtbot.com/blog/send-a-patch-to-someone-using-git-format-patch

How can we suppress this, which is just the git version that generated the patch file?

--
2.7.0

Upvotes: 0

Views: 380

Answers (1)

Omer Tuchfeld
Omer Tuchfeld

Reputation: 3022

Use the git format-patch --no-signature flag:

       --[no-]signature=<signature>
           Add a signature to each message produced. Per RFC 3676 the signature is separated from the
           body by a line with '-- ' on it. If the signature option is omitted the signature defaults
           to the Git version number.

Upvotes: 1

Related Questions