Sync with 1.7.1.2
authorJunio C Hamano <gitster@pobox.com>
Tue, 27 Jul 2010 23:40:15 +0000 (16:40 -0700)
committerJunio C Hamano <gitster@pobox.com>
Tue, 27 Jul 2010 23:40:23 +0000 (16:40 -0700)
1  2 
Documentation/git.txt
t/t1300-repo-config.sh
diff --combined Documentation/git.txt
index 27ece5885720c0db79e30a6de9663e3bdfb37f07,b5a4e3d4031961d648b52abc1c64df5b4acfb32c..f6e10f586c8d4e8fa8231f118cd5a107e79c4371
@@@ -12,7 -12,6 +12,7 @@@ SYNOPSI
  'git' [--version] [--exec-path[=GIT_EXEC_PATH]] [--html-path]
      [-p|--paginate|--no-pager] [--no-replace-objects]
      [--bare] [--git-dir=GIT_DIR] [--work-tree=GIT_WORK_TREE]
 +    [-c name=value]
      [--help] COMMAND [ARGS]
  
  DESCRIPTION
@@@ -44,20 -43,18 +44,22 @@@ unreleased) version of git, that is ava
  branch of the `git.git` repository.
  Documentation for older releases are available here:
  
 +* link:v1.7.2/git.html[documentation for release 1.7.2]
 +
 +* release notes for
 +  link:RelNotes-1.7.2.txt[1.7.2].
  
- * link:v1.7.1.1/git.html[documentation for release 1.7.1.1]
+ * link:v1.7.1.2/git.html[documentation for release 1.7.1.2]
  
  * release notes for
+   link:RelNotes-1.7.1.2.txt[1.7.1.2],
    link:RelNotes-1.7.1.1.txt[1.7.1.1],
    link:RelNotes-1.7.1.txt[1.7.1].
  
- * link:v1.7.0.6/git.html[documentation for release 1.7.0.6]
+ * link:v1.7.0.7/git.html[documentation for release 1.7.0.7]
  
  * release notes for
+   link:RelNotes-1.7.0.7.txt[1.7.0.7],
    link:RelNotes-1.7.0.6.txt[1.7.0.6],
    link:RelNotes-1.7.0.5.txt[1.7.0.5],
    link:RelNotes-1.7.0.4.txt[1.7.0.4],
@@@ -235,12 -232,6 +237,12 @@@ displayed. See linkgit:git-help[1] for 
  because `git --help ...` is converted internally into `git
  help ...`.
  
 +-c <name>=<value>::
 +      Pass a configuration parameter to the command. The value
 +      given will override values from configuration files.
 +      The <name> is expected in the same format as listed by
 +      'git config' (subkeys separated by dots).
 +
  --exec-path::
        Path to wherever your core git programs are installed.
        This can also be controlled by setting the GIT_EXEC_PATH
@@@ -484,7 -475,7 +486,7 @@@ HEAD:
        (i.e. the contents of `$GIT_DIR/refs/heads/<head>`).
  
  For a more complete list of ways to spell object names, see
 -"SPECIFYING REVISIONS" section in linkgit:git-rev-parse[1].
 +"SPECIFYING REVISIONS" section in linkgit:gitrevisions[1].
  
  
  File/Directory Structure
@@@ -551,16 -542,6 +553,16 @@@ git so take care if using Cogito etc
        a GIT_DIR set on the command line or in the environment.
        (Useful for excluding slow-loading network directories.)
  
 +'GIT_DISCOVERY_ACROSS_FILESYSTEM'::
 +      When run in a directory that does not have ".git" repository
 +      directory, git tries to find such a directory in the parent
 +      directories to find the top of the working tree, but by default it
 +      does not cross filesystem boundaries.  This environment variable
 +      can be set to true to tell git not to stop at filesystem
 +      boundaries.  Like 'GIT_CEILING_DIRECTORIES', this will not affect
 +      an explicit repository directory set via 'GIT_DIR' or on the
 +      command line.
 +
  git Commits
  ~~~~~~~~~~~
  'GIT_AUTHOR_NAME'::
diff --combined t/t1300-repo-config.sh
index 64f05080b65c2b9506d1e34748b47ee721026aef,7ddab5fb76697442808e2818ec3bc5c635731830..074f2f2e3e57f76b01f16502998e95b493676711
@@@ -707,19 -707,41 +707,41 @@@ test_expect_success 'set --path' 
        git config --path path.trailingtilde "foo~" &&
        test_cmp expect .git/config'
  
+ if test "${HOME+set}"
+ then
+       test_set_prereq HOMEVAR
+ fi
  cat >expect <<EOF
  $HOME/
  /dev/null
  foo~
  EOF
  
- test_expect_success 'get --path' '
+ test_expect_success HOMEVAR 'get --path' '
        git config --get --path path.home > result &&
        git config --get --path path.normal >> result &&
        git config --get --path path.trailingtilde >> result &&
        test_cmp expect result
  '
  
+ cat >expect <<\EOF
+ /dev/null
+ foo~
+ EOF
+ test_expect_success 'get --path copes with unset $HOME' '
+       (
+               unset HOME;
+               test_must_fail git config --get --path path.home \
+                       >result 2>msg &&
+               git config --get --path path.normal >>result &&
+               git config --get --path path.trailingtilde >>result
+       ) &&
+       grep "[Ff]ailed to expand.*~/" msg &&
+       test_cmp expect result
+ '
  rm .git/config
  
  git config quote.leading " test"
@@@ -824,12 -846,4 +846,12 @@@ test_expect_success 'check split_cmdlin
        test_must_fail git merge master
        "
  
 +test_expect_success 'git -c "key=value" support' '
 +      test "z$(git -c name=value config name)" = zvalue &&
 +      test "z$(git -c core.name=value config core.name)" = zvalue &&
 +      test "z$(git -c CamelCase=value config camelcase)" = zvalue &&
 +      test "z$(git -c flag config --bool flag)" = ztrue &&
 +      test_must_fail git -c core.name=value config name
 +'
 +
  test_done