Re: [PATCH 2/2] Use NullProgressMonitor.INSTANCE and indent for loop
- From
Shawn O. Pearce <spearce@spearce.org>
- Date
- May 6, 2009, 20:54 UTC
- Message-ID
- <20090506205444.GN30527@spearce.org>
- In-Reply-To
- <46FFA889-7EFA-4CF2-9493-81DF5A319B6C@gmail.com>
Alex Blewitt <alex.blewitt@gmail.com> wrote:
Show 5 quoted lines
> I've been using git send-email --format-patch, which doesn't appear to > add the signed by line. If I do it as the commit, will it add the > signed-by when it gets committed, and thus I can use send-email? git > format-patch just seems to dump a load of files into the directory, and > (as noted elsewhere) the git-rebase doesn't appear to work for me.
IIRC, "git send-email --format-patch -- -s" would pass -s to the format-patch script, adding the line automatically. But that's an undocumented feature of send-email.
Personally, I put the SOB line in with "git commit -s" when I write the change. Then its there when I dump it out with format-patch.
As for format-patch making a ton of files, yea, that's its job. I actually use the following pair of scripts to manage sending, as this lets me edit _sop/OUT/* before firing it off.
--8<-- #!/bin/sh if [ -n "$(git rev-parse --show-cdup)" ]; then cd $(git rev-parse --show-cdup) || exit fi
mkdir -p _sop/OUT &&
rm -f $(find _sop/OUT -name '*.patch' | grep -v '0000-cover-letter') &&
base="${1:-master}" &&
if [ $(git rev-list ^$base HEAD | wc -l) -gt 1 ]
then
n="--numbered --cover-letter"
fi &&
git format-patch \
--output-directory _sop/OUT \
--subject-prefix='JGIT PATCH' \
-M \
$n \
$base || exit
------8<-- #!/bin/sh if [ -n "$(git rev-parse --show-cdup)" ]; then cd $(git rev-parse --show-cdup) || exit fi
ls -1 _sop/OUT read
git send-email \ --to 'Robin Rosenberg <robin.rosenberg@dewire.com>' \ --cc 'git@vger.kernel.org' \ --chain-reply-to \ --suppress-cc self \ --smtp-server localhost \ --smtp-server-port 8025 \ _sop/OUT ----
-- Shawn.