<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/t/t4014-format-patch.sh, branch v2.0.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.0.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.0.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2014-03-19T19:55:57Z</updated>
<entry>
<title>tests: use "env" to run commands with temporary env-var settings</title>
<updated>2014-03-19T19:55:57Z</updated>
<author>
<name>David Tran</name>
<email>unsignedzero@gmail.com</email>
</author>
<published>2014-03-18T18:54:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=512477b175288a429aaf4071dc9fe94f17f0e4ee'/>
<id>urn:sha1:512477b175288a429aaf4071dc9fe94f17f0e4ee</id>
<content type='text'>
Ordinarily, we would say "VAR=VAL command" to execute a tested
command with environment variable(s) set only for that command.
This however does not work if 'command' is a shell function (most
notably 'test_must_fail'); the result of the assignment is retained
and affects later commands.

To avoid this, we used to assign and export environment variables
and run such a test in a subshell, like so:

        (
                VAR=VAL &amp;&amp; export VAR &amp;&amp;
                test_must_fail git command to be tested
        )

But with "env" utility, we should be able to say:

        test_must_fail env VAR=VAL git command to be tested

which is much shorter and easier to read.

Signed-off-by: David Tran &lt;unsignedzero@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>t: use perl instead of "$PERL_PATH" where applicable</title>
<updated>2013-10-29T19:45:15Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2013-10-29T01:23:03Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=94221d22036f36e10680c0a1e7eafb4bceeb1248'/>
<id>urn:sha1:94221d22036f36e10680c0a1e7eafb4bceeb1248</id>
<content type='text'>
As of the last commit, we can use "perl" instead of
"$PERL_PATH" when running tests, as the former is now a
function which uses the latter. As the shorter "perl" is
easier on the eyes, let's switch to using it everywhere.

This is not quite a mechanical s/$PERL_PATH/perl/
replacement, though. There are some places where we invoke
perl from a script we generate on the fly, and those scripts
do not have access to our internal shell functions. The
result can be double-checked by running:

  ln -s /bin/false bin-wrappers/perl
  make test

which continues to pass even after this patch.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>format-patch: print in-body "From" only when needed</title>
<updated>2013-09-20T18:09:51Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2013-09-20T10:16:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=662cc30cd048f2ccd7ba8d1540e0768ae264c0dd'/>
<id>urn:sha1:662cc30cd048f2ccd7ba8d1540e0768ae264c0dd</id>
<content type='text'>
Commit a908047 taught format-patch the "--from" option,
which places the author ident into an in-body from header,
and uses the committer ident in the rfc822 from header.  The
documentation claims that it will omit the in-body header
when it is the same as the rfc822 header, but the code never
implemented that behavior.

This patch completes the feature by comparing the two idents
and doing nothing when they are the same (this is the same
as simply omitting the in-body header, as the two are by
definition indistinguishable in this case). This makes it
reasonable to turn on "--from" all the time (if it matches
your particular workflow), rather than only using it when
exporting other people's patches.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>teach format-patch to place other authors into in-body "From"</title>
<updated>2013-07-03T19:11:04Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2013-07-03T07:08:22Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a90804752f6ab2b911882d47fafb6c2b78f447c3'/>
<id>urn:sha1:a90804752f6ab2b911882d47fafb6c2b78f447c3</id>
<content type='text'>
Format-patch generates emails with the "From" address set to the
author of each patch. If you are going to send the emails, however,
you would want to replace the author identity with yours (if they
are not the same), and bump the author identity to an in-body
header.

Normally this is handled by git-send-email, which does the
transformation before sending out the emails. However, some
workflows may not use send-email (e.g., imap-send, or a custom
script which feeds the mbox to a non-git MUA). They could each
implement this feature themselves, but getting it right is
non-trivial (one must canonicalize the identities by reversing any
RFC2047 encoding or RFC822 quoting of the headers, which has caused
many bugs in send-email over the years).

This patch takes a different approach: it teaches format-patch a
"--from" option which handles the ident check and in-body header
while it is writing out the email.  It's much simpler to do at this
level (because we haven't done any quoting yet), and any workflow
based on format-patch can easily turn it on.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'fc/send-email-annotate'</title>
<updated>2013-04-18T18:49:11Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2013-04-18T18:49:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=288aa7534ae79eef03f79aaec355a7eedb08ddfa'/>
<id>urn:sha1:288aa7534ae79eef03f79aaec355a7eedb08ddfa</id>
<content type='text'>
Allows format-patch --cover-letter to be configurable; the most
notable is the "auto" mode to create cover-letter only for multi
patch series.

* fc/send-email-annotate:
  rebase-am: explicitly disable cover-letter
  format-patch: trivial cleanups
  format-patch: add format.coverLetter configuration variable
  log: update to OPT_BOOL
  format-patch: refactor branch name calculation
  format-patch: improve head calculation for cover-letter
  send-email: make annotate configurable
</content>
</entry>
<entry>
<title>Sync with 'maint'</title>
<updated>2013-04-12T20:54:01Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2013-04-12T20:54:01Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=caa7d79f1f7c9940acfaf161b9b84bbf81980d95'/>
<id>urn:sha1:caa7d79f1f7c9940acfaf161b9b84bbf81980d95</id>
<content type='text'>
* maint:
  Correct common spelling mistakes in comments and tests
  kwset: fix spelling in comments
  precompose-utf8: fix spelling of "want" in error message
  compat/nedmalloc: fix spelling in comments
  compat/regex: fix spelling and grammar in comments
  obstack: fix spelling of similar
  contrib/subtree: fix spelling of accidentally
  git-remote-mediawiki: spelling fixes
  doc: various spelling fixes
  fast-export: fix argument name in error messages
  Documentation: distinguish between ref and offset deltas in pack-format
  i18n: make the translation of -u advice in one go
</content>
</entry>
<entry>
<title>Correct common spelling mistakes in comments and tests</title>
<updated>2013-04-12T20:38:40Z</updated>
<author>
<name>Stefano Lattarini</name>
<email>stefano.lattarini@gmail.com</email>
</author>
<published>2013-04-11T22:36:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=41ccfdd9c931ee71b09f38f4eb19cf44a8e4381d'/>
<id>urn:sha1:41ccfdd9c931ee71b09f38f4eb19cf44a8e4381d</id>
<content type='text'>
Most of these were found using Lucas De Marchi's codespell tool.

Signed-off-by: Stefano Lattarini &lt;stefano.lattarini@gmail.com&gt;
Signed-off-by: Jonathan Nieder &lt;jrnieder@gmail.com&gt;
Acked-by: Matthieu Moy &lt;Matthieu.Moy@imag.fr&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>format-patch: add format.coverLetter configuration variable</title>
<updated>2013-04-07T20:37:47Z</updated>
<author>
<name>Felipe Contreras</name>
<email>felipe.contreras@gmail.com</email>
</author>
<published>2013-04-07T17:46:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=2a4c26076c3c99300a51439702791c17e7d21e6c'/>
<id>urn:sha1:2a4c26076c3c99300a51439702791c17e7d21e6c</id>
<content type='text'>
Also, add a new option: 'auto', so if there's more than one patch, the
cover letter is generated, otherwise it's not.

Signed-off-by: Felipe Contreras &lt;felipe.contreras@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>format-patch: improve head calculation for cover-letter</title>
<updated>2013-04-07T20:32:41Z</updated>
<author>
<name>Felipe Contreras</name>
<email>felipe.contreras@gmail.com</email>
</author>
<published>2013-04-07T17:46:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=80d35ca0aaeca654562974be6ea528e22bc76e8c'/>
<id>urn:sha1:80d35ca0aaeca654562974be6ea528e22bc76e8c</id>
<content type='text'>
If we do it after the revision traversal we can be sure that this is
indeed a commit that will be processed (i.e. not a merge) and it's the
top most one (thus removing the NEEDSWORK comment, at least we show the
same as 'git diff --stat' output that appears in the cover-letter).

While we are at it, since we know there's nothing to generate, exit
sooner in all cases, like --cover-letter currently does.

Also, if there's nothing to generate and cover-letter is specified, a
different code-path might be triggered that is not currently covered in
the test-case, so add a test for it.

Signed-off-by: Felipe Contreras &lt;felipe.contreras@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'ks/rfc2047-one-char-at-a-time' into maint</title>
<updated>2013-04-03T16:25:29Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2013-04-03T16:25:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=e6658b9d6917d9888fa41702bf53393c57de0631'/>
<id>urn:sha1:e6658b9d6917d9888fa41702bf53393c57de0631</id>
<content type='text'>
When "format-patch" quoted a non-ascii strings on the header files,
it incorrectly applied rfc2047 and chopped a single character in the
middle of it.

* ks/rfc2047-one-char-at-a-time:
  format-patch: RFC 2047 says multi-octet character may not be split
</content>
</entry>
</feed>
