<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/t/t4014-format-patch.sh, branch v2.4.7</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.4.7</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.4.7'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2015-07-15T18:41:16Z</updated>
<entry>
<title>Merge branch 'jc/do-not-feed-tags-to-clear-commit-marks' into maint</title>
<updated>2015-07-15T18:41:16Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-07-15T18:41:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=93eba05b4f0b235dd859d9a9ed6ebb1ed49e1d60'/>
<id>urn:sha1:93eba05b4f0b235dd859d9a9ed6ebb1ed49e1d60</id>
<content type='text'>
"git format-patch --ignore-if-upstream A..B" did not like to be fed
tags as boundary commits.

* jc/do-not-feed-tags-to-clear-commit-marks:
  format-patch: do not feed tags to clear_commit_marks()
</content>
</entry>
<entry>
<title>format-patch: do not feed tags to clear_commit_marks()</title>
<updated>2015-06-01T23:02:52Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-06-01T17:44:21Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=9b7a61d7dab1635607b1b5be480ac78944cafb45'/>
<id>urn:sha1:9b7a61d7dab1635607b1b5be480ac78944cafb45</id>
<content type='text'>
"git format-patch --ignore-if-in-upstream A..B", when either A or B
is a tag, failed miserably.

This is because the code passes the tips it used for traversal to
clear_commit_marks(), after running a temporary revision traversal
to enumerate the commits on both branches to find if they have
commits that make equivalent changes.  The revision traversal
machinery knows how to enumerate commits reachable starting from a
tag, but clear_commit_marks() wants to take nothing but a commit.

In the longer term, it might be a more correct fix to teach
clear_commit_marks() to do the same "committish to commit"
dereferencing that is done in the revision traversal machinery,
but for now this fix should suffice.

Reported-by: Bruce Korb &lt;bruce.korb@gmail.com&gt;
Helped-by: Christian Couder &lt;christian.couder@gmail.com&gt;
Helped-by: brian m. carlson &lt;sandals@crustytoothpaste.net&gt;
Helped-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>t: fix trivial &amp;&amp;-chain breakage</title>
<updated>2015-03-20T17:20:14Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2015-03-20T10:07:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=99094a7ad484085b9f6849a8ebe1e23467c5bc14'/>
<id>urn:sha1:99094a7ad484085b9f6849a8ebe1e23467c5bc14</id>
<content type='text'>
These are tests which are missing a link in their &amp;&amp;-chain,
but during a setup phase. We may fail to notice failure in
commands that build the test environment, but these are
typically not expected to fail at all (but it's still good
to double-check that our test environment is what we
expect).

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 'jm/format-patch-mail-sig'</title>
<updated>2014-06-16T19:18:38Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-06-16T19:18:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=f18871dcd487bd9391accaffb4e818d58f2d2720'/>
<id>urn:sha1:f18871dcd487bd9391accaffb4e818d58f2d2720</id>
<content type='text'>
* jm/format-patch-mail-sig:
  format-patch: add "--signature-file=&lt;file&gt;" option
  format-patch: make newline after signature conditional
</content>
</entry>
<entry>
<title>Merge branch 'ep/shell-command-substitution'</title>
<updated>2014-06-03T19:06:45Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-06-03T19:06:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=6753d8a85d543253d95184ec2faad6dc197f2486'/>
<id>urn:sha1:6753d8a85d543253d95184ec2faad6dc197f2486</id>
<content type='text'>
Adjust shell scripts to use $(cmd) instead of `cmd`.

* ep/shell-command-substitution: (41 commits)
  t5000-tar-tree.sh: use the $( ... ) construct for command substitution
  t4204-patch-id.sh: use the $( ... ) construct for command substitution
  t4119-apply-config.sh: use the $( ... ) construct for command substitution
  t4116-apply-reverse.sh: use the $( ... ) construct for command substitution
  t4057-diff-combined-paths.sh: use the $( ... ) construct for command substitution
  t4038-diff-combined.sh: use the $( ... ) construct for command substitution
  t4036-format-patch-signer-mime.sh: use the $( ... ) construct for command substitution
  t4014-format-patch.sh: use the $( ... ) construct for command substitution
  t4013-diff-various.sh: use the $( ... ) construct for command substitution
  t4012-diff-binary.sh: use the $( ... ) construct for command substitution
  t4010-diff-pathspec.sh: use the $( ... ) construct for command substitution
  t4006-diff-mode.sh: use the $( ... ) construct for command substitution
  t3910-mac-os-precompose.sh: use the $( ... ) construct for command substitution
  t3905-stash-include-untracked.sh: use the $( ... ) construct for command substitution
  t1050-large.sh: use the $( ... ) construct for command substitution
  t1020-subdirectory.sh: use the $( ... ) construct for command substitution
  t1004-read-tree-m-u-wf.sh: use the $( ... ) construct for command substitution
  t1003-read-tree-prefix.sh: use the $( ... ) construct for command substitution
  t1002-read-tree-m-u-2way.sh: use the $( ... ) construct for command substitution
  t1001-read-tree-m-2way.sh: use the $( ... ) construct for command substitution
  ...
</content>
</entry>
<entry>
<title>format-patch: add "--signature-file=&lt;file&gt;" option</title>
<updated>2014-05-27T19:38:32Z</updated>
<author>
<name>Jeremiah Mahler</name>
<email>jmmahler@gmail.com</email>
</author>
<published>2014-05-24T04:08:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=7022650f61ff7d7c9297db4a04f4e93ae14e1750'/>
<id>urn:sha1:7022650f61ff7d7c9297db4a04f4e93ae14e1750</id>
<content type='text'>
Add an option to format-patch for reading a signature from a file.

  $ git format-patch -1 --signature-file=$HOME/.signature

The config variable `format.signaturefile` can also be used to make
this the default.

  $ git config format.signaturefile $HOME/.signature

  $ git format-patch -1

Signed-off-by: Jeremiah Mahler &lt;jmmahler@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>t4014-format-patch.sh: use the $( ... ) construct for command substitution</title>
<updated>2014-04-30T18:08:06Z</updated>
<author>
<name>Elia Pinto</name>
<email>gitter.spiros@gmail.com</email>
</author>
<published>2014-04-30T16:23:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=54835fc57ea16ed19d1689b37073806537f14cf7'/>
<id>urn:sha1:54835fc57ea16ed19d1689b37073806537f14cf7</id>
<content type='text'>
The Git CodingGuidelines prefer the $(...) construct for command
substitution instead of using the backquotes `...`.

The backquoted form is the traditional method for command
substitution, and is supported by POSIX.  However, all but the
simplest uses become complicated quickly.  In particular, embedded
command substitutions and/or the use of double quotes require
careful escaping with the backslash character.

The patch was generated by:

for _f in $(find . -name "*.sh")
do
   sed -i 's@`\(.*\)`@$(\1)@g' ${_f}
done

and then carefully proof-read.

Signed-off-by: Elia Pinto &lt;gitter.spiros@gmail.com&gt;
Reviewed-by: Matthieu Moy &lt;Matthieu.Moy@imag.fr&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<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>
</feed>
