<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/git-sh-setup.sh, branch v1.7.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v1.7.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v1.7.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2010-03-07T20:47:17Z</updated>
<entry>
<title>Merge branch 'gb/maint-submodule-env'</title>
<updated>2010-03-07T20:47:17Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2010-03-07T20:47:17Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=9317dc4f051452a0e0f7a62a5531b16adf36b553'/>
<id>urn:sha1:9317dc4f051452a0e0f7a62a5531b16adf36b553</id>
<content type='text'>
* gb/maint-submodule-env:
  is_submodule_modified(): clear environment properly
  submodules: ensure clean environment when operating in a submodule
  shell setup: clear_local_git_env() function
  rev-parse: --local-env-vars option
  Refactor list of of repo-local env vars
</content>
</entry>
<entry>
<title>Merge branch 'jn/maint-fix-pager'</title>
<updated>2010-03-02T20:44:11Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2010-03-02T20:44:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=52ebb06f1466a235c643acffdea9c9e484cfdec0'/>
<id>urn:sha1:52ebb06f1466a235c643acffdea9c9e484cfdec0</id>
<content type='text'>
* jn/maint-fix-pager:
  tests: Fix race condition in t7006-pager
  t7006-pager: if stdout is not a terminal, make a new one
  tests: Add tests for automatic use of pager
  am: Fix launching of pager
  git svn: Fix launching of pager
  git.1: Clarify the behavior of the --paginate option
  Make 'git var GIT_PAGER' always print the configured pager
  Fix 'git var' usage synopsis
</content>
</entry>
<entry>
<title>Merge branch 'gf/maint-sh-setup-nongit-ok'</title>
<updated>2010-03-02T20:44:07Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2010-03-02T20:44:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=8acd141bb5cd4155d849fbfb3b74eb509608cd15'/>
<id>urn:sha1:8acd141bb5cd4155d849fbfb3b74eb509608cd15</id>
<content type='text'>
* gf/maint-sh-setup-nongit-ok:
  require_work_tree broken with NONGIT_OK
</content>
</entry>
<entry>
<title>shell setup: clear_local_git_env() function</title>
<updated>2010-02-25T00:24:25Z</updated>
<author>
<name>Giuseppe Bilotta</name>
<email>giuseppe.bilotta@gmail.com</email>
</author>
<published>2010-02-24T23:34:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=7d750f0ea511dcc26c3c9de996a9b75444366ecc'/>
<id>urn:sha1:7d750f0ea511dcc26c3c9de996a9b75444366ecc</id>
<content type='text'>
Introduce an auxiliary function to clear all repo-local environment
variables. This should be invoked by any shell script that switches
repository during execution, to ensure that the environment is clean
and that things such as the git dir and worktree are set up correctly.

Signed-off-by: Giuseppe Bilotta &lt;giuseppe.bilotta@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>require_work_tree broken with NONGIT_OK</title>
<updated>2010-02-17T18:55:12Z</updated>
<author>
<name>Gabriel Filion</name>
<email>lelutin@gmail.com</email>
</author>
<published>2010-02-17T04:18:50Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=ab62677b1424d4e53cf222c973b841d3dada4cf3'/>
<id>urn:sha1:ab62677b1424d4e53cf222c973b841d3dada4cf3</id>
<content type='text'>
With NONGIT_OK set, require_work_tree function outside a git repository
gives a syntax error.  This is caused by an incorrect use of "test" that
didn't anticipate $(git rev-parse --is-inside-work-tree) may return an
empty string.

Properly quote the argument to "test", and send the standard error stream
to /dev/null to avoid giving duplicate error messages.

Signed-off-by: Gabriel Filion &lt;lelutin@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>am: Fix launching of pager</title>
<updated>2010-02-15T06:05:17Z</updated>
<author>
<name>Jonathan Nieder</name>
<email>jrnieder@gmail.com</email>
</author>
<published>2010-02-15T05:04:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=f6dff119d51e0067d213068093039bb2f939d139'/>
<id>urn:sha1:f6dff119d51e0067d213068093039bb2f939d139</id>
<content type='text'>
The pagination functionality in git am has some problems:

 - It does not check if stdout is a tty, so it always paginates.

 - If $GIT_PAGER uses any environment variables, they are being
   ignored, since it does not run $GIT_PAGER through eval.

 - If $GIT_PAGER is set to the empty string, instead of passing
   output through to stdout, it tries to run $dotest/patch.

Fix them.  While at it, move the definition of git_pager() to
git-sh-setup so authors of other commands are not tempted to
reimplement it with the same mistakes.

Signed-off-by: Jonathan Nieder &lt;jrnieder@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Do not install shell libraries executable</title>
<updated>2010-01-31T19:53:10Z</updated>
<author>
<name>Jonathan Nieder</name>
<email>jrnieder@gmail.com</email>
</author>
<published>2010-01-31T19:46:53Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=46bac904581798eaf0f07f91701c2c72219e207f'/>
<id>urn:sha1:46bac904581798eaf0f07f91701c2c72219e207f</id>
<content type='text'>
Some scripts are expected to be sourced instead of executed on their own.
Avoid some confusion by not marking them executable.

The executable bit was confusing the valgrind support of our test scripts,
which assumed that any executable without a #!-line should be intercepted
and run through valgrind.  So during valgrind-enabled tests, any script
sourcing these files actually sourced the valgrind interception script
instead.

Reported-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Jonathan Nieder &lt;jrnieder@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Use $(git rev-parse --show-toplevel) in cd_to_toplevel().</title>
<updated>2010-01-12T03:47:52Z</updated>
<author>
<name>Steven Drake</name>
<email>sdrake@xnet.co.nz</email>
</author>
<published>2010-01-11T22:34:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=91dc602de9579fe8dc29814819904e2b5a4e92e1'/>
<id>urn:sha1:91dc602de9579fe8dc29814819904e2b5a4e92e1</id>
<content type='text'>
rev-parse --show-toplevel gives the absolute (aka "physical") path of the
toplevel directory and is more portable as 'cd -P' is not supported by all
shell implementations.

This is also closer to what setup_work_tree() does.

Signed-off-by: Steven Drake &lt;sdrake@xnet.co.nz&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'rs/work-around-grep-opt-insanity'</title>
<updated>2009-11-25T19:45:07Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2009-11-25T19:45:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=ad7ace714d353ef49045bc37c1363e8fc904792d'/>
<id>urn:sha1:ad7ace714d353ef49045bc37c1363e8fc904792d</id>
<content type='text'>
* rs/work-around-grep-opt-insanity:
  Protect scripted Porcelains from GREP_OPTIONS insanity
  mergetool--lib: simplify guess_merge_tool()

Conflicts:
	git-instaweb.sh
</content>
</entry>
<entry>
<title>Protect scripted Porcelains from GREP_OPTIONS insanity</title>
<updated>2009-11-24T00:31:07Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2009-11-23T23:56:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=e1622bfcbad680225ad5c337e4778df88389227e'/>
<id>urn:sha1:e1622bfcbad680225ad5c337e4778df88389227e</id>
<content type='text'>
If the user has exported the GREP_OPTIONS environment variable, the output
from "grep" and "egrep" in scripted Porcelains may be different from what
they expect.  For example, we may want to count number of matching lines,
by "grep" piped to "wc -l", and GREP_OPTIONS=-C3 will break such use.

The approach taken by this change to address this issue is to protect only
our own use of grep/egrep.  Because we do not unset it at the beginning of
our scripts, hook scripts run from the scripted Porcelains are exposed to
the same insanity this environment variable causes when grep/egrep is used
to implement logic (e.g. "grep | wc -l"), and it is entirely up to the
hook scripts to protect themselves.

On the other hand, applypatch-msg hook may want to show offending words in
the proposed commit log message using grep to the end user, and the user
might want to set GREP_OPTIONS=--color to paint the match more visibly.
The approach to protect only our own use without unsetting the environment
variable globally will allow this use case.

Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
