Hello community,

here is the log from the commit of package git for openSUSE:Factory checked in 
at 2012-12-19 10:56:02
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/git (Old)
 and      /work/SRC/openSUSE:Factory/.git.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "git", Maintainer is "[email protected]"

Changes:
--------
--- /work/SRC/openSUSE:Factory/git/git.changes  2012-11-28 10:24:46.000000000 
+0100
+++ /work/SRC/openSUSE:Factory/.git.new/git.changes     2012-12-19 
10:56:04.000000000 +0100
@@ -1,0 +2,34 @@
+Fri Dec 14 00:46:08 UTC 2012 - [email protected]
+
+- updated to version 1.8.0.2:
+
+     * Various codepaths have workaround for a common misconfiguration to
+       spell "UTF-8" as "utf8", but it was not used uniformly.  Most
+       notably, mailinfo (which is used by "git am") lacked this support.
+
+     * We failed to mention a file without any content change but whose
+       permission bit was modified, or (worse yet) a new file without any
+       content in the "git diff --stat" output.
+
+     * When "--stat-count" hides a diffstat for binary contents, the total
+       number of added and removed lines at the bottom was computed
+       incorrectly.
+
+     * When "--stat-count" hides a diffstat for unmerged paths, the total
+       number of affected files at the bottom of the "diff --stat" output
+       was computed incorrectly.
+
+     * "diff --shortstat" miscounted the total number of affected files
+       when there were unmerged paths.
+
+     * "git p4" used to try expanding malformed "$keyword$" that spans
+       across multiple lines.
+
+     * "git update-ref -d --deref SYM" to delete a ref through a symbolic
+       ref that points to it did not remove it correctly.
+
+     * Syntax highlighting in "gitweb" was not quite working.
+
+    Also contains other minor fixes and documentation updates.
+
+-------------------------------------------------------------------

Old:
----
  git-1.8.0.1.tar.gz

New:
----
  git-1.8.0.2.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ git.spec ++++++
--- /var/tmp/diff_new_pack.PtAt4A/_old  2012-12-19 10:56:06.000000000 +0100
+++ /var/tmp/diff_new_pack.PtAt4A/_new  2012-12-19 10:56:06.000000000 +0100
@@ -30,7 +30,7 @@
 BuildRequires:  python
 BuildRequires:  sgml-skel
 BuildRequires:  xmlto
-Version:        1.8.0.1
+Version:        1.8.0.2
 Release:        0
 Summary:        Fast, scalable, distributed revision control system
 License:        GPL-2.0

++++++ git-1.8.0.1.tar.gz -> git-1.8.0.2.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/Documentation/RelNotes/1.8.0.2.txt 
new/git-1.8.0.2/Documentation/RelNotes/1.8.0.2.txt
--- old/git-1.8.0.1/Documentation/RelNotes/1.8.0.2.txt  1970-01-01 
01:00:00.000000000 +0100
+++ new/git-1.8.0.2/Documentation/RelNotes/1.8.0.2.txt  2012-12-10 
22:53:39.000000000 +0100
@@ -0,0 +1,34 @@
+Git v1.8.0.2 Release Notes
+==========================
+
+Fixes since v1.8.0.1
+--------------------
+
+ * Various codepaths have workaround for a common misconfiguration to
+   spell "UTF-8" as "utf8", but it was not used uniformly.  Most
+   notably, mailinfo (which is used by "git am") lacked this support.
+
+ * We failed to mention a file without any content change but whose
+   permission bit was modified, or (worse yet) a new file without any
+   content in the "git diff --stat" output.
+
+ * When "--stat-count" hides a diffstat for binary contents, the total
+   number of added and removed lines at the bottom was computed
+   incorrectly.
+
+ * When "--stat-count" hides a diffstat for unmerged paths, the total
+   number of affected files at the bottom of the "diff --stat" output
+   was computed incorrectly.
+
+ * "diff --shortstat" miscounted the total number of affected files
+   when there were unmerged paths.
+
+ * "git p4" used to try expanding malformed "$keyword$" that spans
+   across multiple lines.
+
+ * "git update-ref -d --deref SYM" to delete a ref through a symbolic
+   ref that points to it did not remove it correctly.
+
+ * Syntax highlighting in "gitweb" was not quite working.
+
+Also contains other minor fixes and documentation updates.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/Documentation/git-fast-import.txt 
new/git-1.8.0.2/Documentation/git-fast-import.txt
--- old/git-1.8.0.1/Documentation/git-fast-import.txt   2012-11-26 
04:18:01.000000000 +0100
+++ new/git-1.8.0.2/Documentation/git-fast-import.txt   2012-12-10 
22:53:39.000000000 +0100
@@ -442,7 +442,9 @@
 ^^^^^^
 The `from` command is used to specify the commit to initialize
 this branch from.  This revision will be the first ancestor of the
-new commit.
+new commit.  The state of the tree built at this commit will begin
+with the state at the `from` commit, and be altered by the content
+modifications in this commit.
 
 Omitting the `from` command in the first commit of a new branch
 will cause fast-import to create that commit with no ancestor. This
@@ -492,7 +494,9 @@
 
 `merge`
 ^^^^^^^
-Includes one additional ancestor commit.  If the `from` command is
+Includes one additional ancestor commit.  The additional ancestry
+link does not change the way the tree state is built at this commit.
+If the `from` command is
 omitted when creating a new branch, the first `merge` commit will be
 the first ancestor of the current commit, and the branch will start
 out with no files.  An unlimited number of `merge` commands per
@@ -558,8 +562,12 @@
 slash `/`), may contain any byte other than `LF`, and must not
 start with double quote (`"`).
 
-If an `LF` or double quote must be encoded into `<path>` shell-style
-quoting should be used, e.g. `"path/with\n and \" in it"`.
+A path can use C-style string quoting; this is accepted in all cases
+and mandatory if the filename starts with double quote or contains
+`LF`. In C-style quoting, the complete name should be surrounded with
+double quotes, and any `LF`, backslash, or double quote characters
+must be escaped by preceding them with a backslash (e.g.,
+`"path/with\n, \\ and \" in it"`).
 
 The value of `<path>` must be in canonical form. That is it must not:
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/Documentation/git-push.txt 
new/git-1.8.0.2/Documentation/git-push.txt
--- old/git-1.8.0.1/Documentation/git-push.txt  2012-11-26 04:18:01.000000000 
+0100
+++ new/git-1.8.0.2/Documentation/git-push.txt  2012-12-10 22:53:39.000000000 
+0100
@@ -286,7 +286,8 @@
 ----------------
 
 Further suppose that the other person already pushed changes leading to A
-back to the original repository you two obtained the original commit X.
+back to the original repository from which you two obtained the original
+commit X.
 
 The push done by the other person updated the branch that used to point at
 commit X to point at commit A.  It is a fast-forward.
@@ -384,11 +385,23 @@
        A handy way to push the current branch to the same name on the
        remote.
 
-`git push origin master:satellite/master dev:satellite/dev`::
+`git push mothership master:satellite/master dev:satellite/dev`::
        Use the source ref that matches `master` (e.g. `refs/heads/master`)
        to update the ref that matches `satellite/master` (most probably
-       `refs/remotes/satellite/master`) in the `origin` repository, then
+       `refs/remotes/satellite/master`) in the `mothership` repository;
        do the same for `dev` and `satellite/dev`.
++
+This is to emulate `git fetch` run on the `mothership` using `git
+push` that is run in the opposite direction in order to integrate
+the work done on `satellite`, and is often necessary when you can
+only make connection in one way (i.e. satellite can ssh into
+mothership but mothership cannot initiate connection to satellite
+because the latter is behind a firewall or does not run sshd).
++
+After running this `git push` on the `satellite` machine, you would
+ssh into the `mothership` and run `git merge` there to complete the
+emulation of `git pull` that were run on `mothership` to pull changes
+made on `satellite`.
 
 `git push origin HEAD:master`::
        Push the current branch to the remote ref matching `master` in the
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/Documentation/git-stash.txt 
new/git-1.8.0.2/Documentation/git-stash.txt
--- old/git-1.8.0.1/Documentation/git-stash.txt 2012-11-26 04:18:01.000000000 
+0100
+++ new/git-1.8.0.2/Documentation/git-stash.txt 2012-12-10 22:53:39.000000000 
+0100
@@ -144,7 +144,7 @@
 
        Remove a single stashed state from the stash list. When no `<stash>`
        is given, it removes the latest one. i.e. `stash@{0}`, otherwise
-       `<stash>` must a valid stash log reference of the form
+       `<stash>` must be a valid stash log reference of the form
        `stash@{<revision>}`.
 
 create::
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/Documentation/git-submodule.txt 
new/git-1.8.0.2/Documentation/git-submodule.txt
--- old/git-1.8.0.1/Documentation/git-submodule.txt     2012-11-26 
04:18:01.000000000 +0100
+++ new/git-1.8.0.2/Documentation/git-submodule.txt     2012-12-10 
22:53:39.000000000 +0100
@@ -9,7 +9,7 @@
 SYNOPSIS
 --------
 [verse]
-'git submodule' [--quiet] add [-b branch] [-f|--force]
+'git submodule' [--quiet] add [-b <branch>] [-f|--force]
              [--reference <repository>] [--] <repository> [<path>]
 'git submodule' [--quiet] status [--cached] [--recursive] [--] [<path>...]
 'git submodule' [--quiet] init [--] [<path>...]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/Documentation/git.txt 
new/git-1.8.0.2/Documentation/git.txt
--- old/git-1.8.0.1/Documentation/git.txt       2012-11-26 04:18:01.000000000 
+0100
+++ new/git-1.8.0.2/Documentation/git.txt       2012-12-10 22:53:39.000000000 
+0100
@@ -43,9 +43,10 @@
 branch of the `git.git` repository.
 Documentation for older releases are available here:
 
-* link:v1.8.0.1/git.html[documentation for release 1.8.0.1]
+* link:v1.8.0.2/git.html[documentation for release 1.8.0.2]
 
 * release notes for
+  link:RelNotes/1.8.0.2.txt[1.8.0.2],
   link:RelNotes/1.8.0.1.txt[1.8.0.1],
   link:RelNotes/1.8.0.txt[1.8.0].
 
@@ -868,8 +869,7 @@
 -------
 Git was started by Linus Torvalds, and is currently maintained by Junio
 C Hamano. Numerous contributions have come from the git mailing list
-<[email protected]>. For a more complete list of contributors, see
-http://git-scm.com/about. If you have a clone of git.git itself, the
+<[email protected]>.  If you have a clone of git.git itself, the
 output of linkgit:git-shortlog[1] and linkgit:git-blame[1] can show you
 the authors for specific parts of the project.
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/GIT-VERSION-GEN 
new/git-1.8.0.2/GIT-VERSION-GEN
--- old/git-1.8.0.1/GIT-VERSION-GEN     2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/GIT-VERSION-GEN     2012-12-10 22:53:39.000000000 +0100
@@ -1,7 +1,7 @@
 #!/bin/sh
 
 GVF=GIT-VERSION-FILE
-DEF_VER=v1.8.0.1
+DEF_VER=v1.8.0.2
 
 LF='
 '
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/Makefile new/git-1.8.0.2/Makefile
--- old/git-1.8.0.1/Makefile    2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/Makefile    2012-12-10 22:53:39.000000000 +0100
@@ -1564,7 +1564,7 @@
        REMOTE_CURL_NAMES = $(REMOTE_CURL_PRIMARY) $(REMOTE_CURL_ALIASES)
        PROGRAM_OBJS += http-fetch.o
        PROGRAMS += $(REMOTE_CURL_NAMES)
-       curl_check := $(shell (echo 070908; curl-config --vernum) | sort -r | 
sed -ne 2p)
+       curl_check := $(shell (echo 070908; curl-config --vernum) 2>/dev/null | 
sort -r | sed -ne 2p)
        ifeq "$(curl_check)" "070908"
                ifndef NO_EXPAT
                        PROGRAM_OBJS += http-push.o
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/RelNotes new/git-1.8.0.2/RelNotes
--- old/git-1.8.0.1/RelNotes    2012-12-19 10:56:06.000000000 +0100
+++ new/git-1.8.0.2/RelNotes    2012-12-19 10:56:06.000000000 +0100
@@ -1 +1 @@
-symbolic link to Documentation/RelNotes/1.8.0.1.txt
+symbolic link to Documentation/RelNotes/1.8.0.2.txt
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/builtin/mailinfo.c 
new/git-1.8.0.2/builtin/mailinfo.c
--- old/git-1.8.0.1/builtin/mailinfo.c  2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/builtin/mailinfo.c  2012-12-10 22:53:39.000000000 +0100
@@ -483,7 +483,8 @@
 
        if (!charset || !*charset)
                return;
-       if (!strcasecmp(metainfo_charset, charset))
+
+       if (same_encoding(metainfo_charset, charset))
                return;
        out = reencode_string(line->buf, metainfo_charset, charset);
        if (!out)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/builtin/remote.c 
new/git-1.8.0.2/builtin/remote.c
--- old/git-1.8.0.1/builtin/remote.c    2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/builtin/remote.c    2012-12-10 22:53:39.000000000 +0100
@@ -39,7 +39,7 @@
 };
 
 static const char * const builtin_remote_sethead_usage[] = {
-       N_("git remote set-head <name> (-a | -d | <branch>])"),
+       N_("git remote set-head <name> (-a | -d | <branch>)"),
        NULL
 };
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/compat/fnmatch/fnmatch.c 
new/git-1.8.0.2/compat/fnmatch/fnmatch.c
--- old/git-1.8.0.1/compat/fnmatch/fnmatch.c    2012-11-26 04:18:01.000000000 
+0100
+++ new/git-1.8.0.2/compat/fnmatch/fnmatch.c    2012-12-10 22:53:39.000000000 
+0100
@@ -345,7 +345,7 @@
 
                    for (;;)
                      {
-                       if (c1 == CHAR_CLASS_MAX_LENGTH)
+                       if (c1 > CHAR_CLASS_MAX_LENGTH)
                          /* The name is too long and therefore the pattern
                             is ill-formed.  */
                          return FNM_NOMATCH;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/configure new/git-1.8.0.2/configure
--- old/git-1.8.0.1/configure   2012-11-26 04:18:02.000000000 +0100
+++ new/git-1.8.0.2/configure   2012-12-10 22:53:39.000000000 +0100
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.67 for git 1.8.0.1.
+# Generated by GNU Autoconf 2.67 for git 1.8.0.2.
 #
 # Report bugs to <[email protected]>.
 #
@@ -552,8 +552,8 @@
 # Identity of this package.
 PACKAGE_NAME='git'
 PACKAGE_TARNAME='git'
-PACKAGE_VERSION='1.8.0.1'
-PACKAGE_STRING='git 1.8.0.1'
+PACKAGE_VERSION='1.8.0.2'
+PACKAGE_STRING='git 1.8.0.2'
 PACKAGE_BUGREPORT='[email protected]'
 PACKAGE_URL=''
 
@@ -1224,7 +1224,7 @@
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures git 1.8.0.1 to adapt to many kinds of systems.
+\`configure' configures git 1.8.0.2 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1285,7 +1285,7 @@
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of git 1.8.0.1:";;
+     short | recursive ) echo "Configuration of git 1.8.0.2:";;
    esac
   cat <<\_ACEOF
 
@@ -1424,7 +1424,7 @@
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-git configure 1.8.0.1
+git configure 1.8.0.2
 generated by GNU Autoconf 2.67
 
 Copyright (C) 2010 Free Software Foundation, Inc.
@@ -1904,7 +1904,7 @@
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by git $as_me 1.8.0.1, which was
+It was created by git $as_me 1.8.0.2, which was
 generated by GNU Autoconf 2.67.  Invocation command line was
 
   $ $0 $@
@@ -7118,7 +7118,7 @@
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by git $as_me 1.8.0.1, which was
+This file was extended by git $as_me 1.8.0.2, which was
 generated by GNU Autoconf 2.67.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -7175,7 +7175,7 @@
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; 
s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-git config.status 1.8.0.1
+git config.status 1.8.0.2
 configured by $0, generated by GNU Autoconf 2.67,
   with options \\"\$ac_cs_config\\"
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/contrib/completion/git-completion.bash 
new/git-1.8.0.2/contrib/completion/git-completion.bash
--- old/git-1.8.0.1/contrib/completion/git-completion.bash      2012-11-26 
04:18:01.000000000 +0100
+++ new/git-1.8.0.2/contrib/completion/git-completion.bash      2012-12-10 
22:53:39.000000000 +0100
@@ -989,6 +989,8 @@
                        --upload-pack
                        --template=
                        --depth
+                       --single-branch
+                       --branch
                        "
                return
                ;;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/contrib/mw-to-git/git-remote-mediawiki 
new/git-1.8.0.2/contrib/mw-to-git/git-remote-mediawiki
--- old/git-1.8.0.1/contrib/mw-to-git/git-remote-mediawiki      2012-11-26 
04:18:01.000000000 +0100
+++ new/git-1.8.0.2/contrib/mw-to-git/git-remote-mediawiki      2012-12-10 
22:53:39.000000000 +0100
@@ -711,6 +711,14 @@
        return ($n, @revisions);
 }
 
+sub fe_escape_path {
+    my $path = shift;
+    $path =~ s/\\/\\\\/g;
+    $path =~ s/"/\\"/g;
+    $path =~ s/\n/\\n/g;
+    return '"' . $path . '"';
+}
+
 sub import_file_revision {
        my $commit = shift;
        my %commit = %{$commit};
@@ -738,15 +746,17 @@
                print STDOUT "from refs/mediawiki/$remotename/master^0\n";
        }
        if ($content ne DELETED_CONTENT) {
-               print STDOUT "M 644 inline $title.mw\n";
+               print STDOUT "M 644 inline " .
+                   fe_escape_path($title . ".mw") . "\n";
                literal_data($content);
                if (%mediafile) {
-                       print STDOUT "M 644 inline $mediafile{title}\n";
+                       print STDOUT "M 644 inline "
+                           . fe_escape_path($mediafile{title}) . "\n";
                        literal_data_raw($mediafile{content});
                }
                print STDOUT "\n\n";
        } else {
-               print STDOUT "D $title.mw\n";
+               print STDOUT "D " . fe_escape_path($title . ".mw") . "\n";
        }
 
        # mediawiki revision number in the git note
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/git-1.8.0.1/contrib/mw-to-git/t/t9362-mw-to-git-utf8.sh 
new/git-1.8.0.2/contrib/mw-to-git/t/t9362-mw-to-git-utf8.sh
--- old/git-1.8.0.1/contrib/mw-to-git/t/t9362-mw-to-git-utf8.sh 2012-11-26 
04:18:01.000000000 +0100
+++ new/git-1.8.0.2/contrib/mw-to-git/t/t9362-mw-to-git-utf8.sh 2012-12-10 
22:53:39.000000000 +0100
@@ -318,4 +318,30 @@
 '
 
 
+test_expect_success 'fast-import meta-characters in page name (mw -> git)' '
+       wiki_reset &&
+       wiki_editpage \"file\"_\\_foo "expect to be called \"file\"_\\_foo" 
false &&
+       git clone mediawiki::'"$WIKI_URL"' mw_dir_21 &&
+       test_path_is_file mw_dir_21/\"file\"_\\_foo.mw &&
+       wiki_getallpage ref_page_21 &&
+       test_diff_directories mw_dir_21 ref_page_21
+'
+
+
+test_expect_success 'fast-import meta-characters in page name (git -> mw) ' '
+       wiki_reset &&
+       git clone mediawiki::'"$WIKI_URL"' mw_dir_22 &&
+       (
+               cd mw_dir_22 &&
+               echo "this file is called \"file\"_\\_foo.mw" >\"file\"_\\_foo 
&&
+               git add . &&
+               git commit -am "file \"file\"_\\_foo" &&
+               git pull &&
+               git push
+       ) &&
+       wiki_getallpage ref_page_22 &&
+       test_diff_directories mw_dir_22 ref_page_22
+'
+
+
 test_done
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/diff.c new/git-1.8.0.2/diff.c
--- old/git-1.8.0.1/diff.c      2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/diff.c      2012-12-10 22:53:39.000000000 +0100
@@ -1300,6 +1300,7 @@
                unsigned is_unmerged:1;
                unsigned is_binary:1;
                unsigned is_renamed:1;
+               unsigned is_interesting:1;
                uintmax_t added, deleted;
        } **files;
 };
@@ -1469,8 +1470,8 @@
        for (i = 0; (i < count) && (i < data->nr); i++) {
                struct diffstat_file *file = data->files[i];
                uintmax_t change = file->added + file->deleted;
-               if (!data->files[i]->is_renamed &&
-                        (change == 0)) {
+
+               if (!file->is_interesting && (change == 0)) {
                        count++; /* not shown == room for one more */
                        continue;
                }
@@ -1497,7 +1498,7 @@
                if (max_change < change)
                        max_change = change;
        }
-       count = i; /* min(count, data->nr) */
+       count = i; /* where we can stop scanning in data->files[] */
 
        /*
         * We have width = stat_width or term_columns() columns total.
@@ -1585,16 +1586,15 @@
         */
        for (i = 0; i < count; i++) {
                const char *prefix = "";
-               char *name = data->files[i]->print_name;
-               uintmax_t added = data->files[i]->added;
-               uintmax_t deleted = data->files[i]->deleted;
+               struct diffstat_file *file = data->files[i];
+               char *name = file->print_name;
+               uintmax_t added = file->added;
+               uintmax_t deleted = file->deleted;
                int name_len;
 
-               if (!data->files[i]->is_renamed &&
-                        (added + deleted == 0)) {
-                       total_files--;
+               if (!file->is_interesting && (added + deleted == 0))
                        continue;
-               }
+
                /*
                 * "scale" the filename
                 */
@@ -1610,7 +1610,7 @@
                                name = slash;
                }
 
-               if (data->files[i]->is_binary) {
+               if (file->is_binary) {
                        fprintf(options->file, "%s", line_prefix);
                        show_name(options->file, prefix, name, len);
                        fprintf(options->file, " %*s", number_width, "Bin");
@@ -1627,7 +1627,7 @@
                        fprintf(options->file, "\n");
                        continue;
                }
-               else if (data->files[i]->is_unmerged) {
+               else if (file->is_unmerged) {
                        fprintf(options->file, "%s", line_prefix);
                        show_name(options->file, prefix, name, len);
                        fprintf(options->file, " Unmerged\n");
@@ -1639,8 +1639,6 @@
                 */
                add = added;
                del = deleted;
-               adds += add;
-               dels += del;
 
                if (graph_width <= max_change) {
                        int total = add + del;
@@ -1666,16 +1664,24 @@
                show_graph(options->file, '-', del, del_c, reset);
                fprintf(options->file, "\n");
        }
-       for (i = count; i < data->nr; i++) {
-               uintmax_t added = data->files[i]->added;
-               uintmax_t deleted = data->files[i]->deleted;
-               if (!data->files[i]->is_renamed &&
-                        (added + deleted == 0)) {
+
+       for (i = 0; i < data->nr; i++) {
+               struct diffstat_file *file = data->files[i];
+               uintmax_t added = file->added;
+               uintmax_t deleted = file->deleted;
+
+               if (file->is_unmerged ||
+                   (!file->is_interesting && (added + deleted == 0))) {
                        total_files--;
                        continue;
                }
-               adds += added;
-               dels += deleted;
+
+               if (!file->is_binary) {
+                       adds += added;
+                       dels += deleted;
+               }
+               if (i < count)
+                       continue;
                if (!extra_shown)
                        fprintf(options->file, "%s ...\n", line_prefix);
                extra_shown = 1;
@@ -1695,9 +1701,8 @@
                int added = data->files[i]->added;
                int deleted= data->files[i]->deleted;
 
-               if (data->files[i]->is_unmerged)
-                       continue;
-               if (!data->files[i]->is_renamed && (added + deleted == 0)) {
+               if (data->files[i]->is_unmerged ||
+                   (!data->files[i]->is_interesting && (added + deleted == 
0))) {
                        total_files--;
                } else if (!data->files[i]->is_binary) { /* don't count bytes */
                        adds += added;
@@ -2397,13 +2402,20 @@
                             struct diff_filespec *two,
                             struct diffstat_t *diffstat,
                             struct diff_options *o,
-                            int complete_rewrite)
+                            struct diff_filepair *p)
 {
        mmfile_t mf1, mf2;
        struct diffstat_file *data;
        int same_contents;
+       int complete_rewrite = 0;
+
+       if (!DIFF_PAIR_UNMERGED(p)) {
+               if (p->status == DIFF_STATUS_MODIFIED && p->score)
+                       complete_rewrite = 1;
+       }
 
        data = diffstat_add(diffstat, name_a, name_b);
+       data->is_interesting = p->status != DIFF_STATUS_UNKNOWN;
 
        if (!one || !two) {
                data->is_unmerged = 1;
@@ -3114,11 +3126,10 @@
 {
        const char *name;
        const char *other;
-       int complete_rewrite = 0;
 
        if (DIFF_PAIR_UNMERGED(p)) {
                /* unmerged */
-               builtin_diffstat(p->one->path, NULL, NULL, NULL, diffstat, o, 
0);
+               builtin_diffstat(p->one->path, NULL, NULL, NULL, diffstat, o, 
p);
                return;
        }
 
@@ -3131,9 +3142,7 @@
        diff_fill_sha1_info(p->one);
        diff_fill_sha1_info(p->two);
 
-       if (p->status == DIFF_STATUS_MODIFIED && p->score)
-               complete_rewrite = 1;
-       builtin_diffstat(name, other, p->one, p->two, diffstat, o, 
complete_rewrite);
+       builtin_diffstat(name, other, p->one, p->two, diffstat, o, p);
 }
 
 static void run_checkdiff(struct diff_filepair *p, struct diff_options *o)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/git-p4.py new/git-1.8.0.2/git-p4.py
--- old/git-1.8.0.1/git-p4.py   2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/git-p4.py   2012-12-10 22:53:39.000000000 +0100
@@ -227,7 +227,7 @@
         pattern = r"""
             \$              # Starts with a dollar, followed by...
             (%s)            # one of the keywords, followed by...
-            (:[^$]+)?       # possibly an old expansion, followed by...
+            (:[^$\n]+)?     # possibly an old expansion, followed by...
             \$              # another dollar
             """ % kwords
         return pattern
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/git-submodule.sh 
new/git-1.8.0.2/git-submodule.sh
--- old/git-1.8.0.1/git-submodule.sh    2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/git-submodule.sh    2012-12-10 22:53:39.000000000 +0100
@@ -5,7 +5,7 @@
 # Copyright (c) 2007 Lars Hjemli
 
 dashless=$(basename "$0" | sed -e 's/-/ /')
-USAGE="[--quiet] add [-b branch] [-f|--force] [--reference <repository>] [--] 
<repository> [<path>]
+USAGE="[--quiet] add [-b <branch>] [-f|--force] [--reference <repository>] 
[--] <repository> [<path>]
    or: $dashless [--quiet] status [--cached] [--recursive] [--] [<path>...]
    or: $dashless [--quiet] init [--] [<path>...]
    or: $dashless [--quiet] update [--init] [-N|--no-fetch] [-f|--force] 
[--rebase] [--reference <repository>] [--merge] [--recursive] [--] [<path>...]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/git.spec new/git-1.8.0.2/git.spec
--- old/git-1.8.0.1/git.spec    2012-11-26 04:18:02.000000000 +0100
+++ new/git-1.8.0.2/git.spec    2012-12-10 22:53:39.000000000 +0100
@@ -1,7 +1,7 @@
 # Pass --without docs to rpmbuild if you don't want the documentation
 
 Name:          git
-Version:       1.8.0.1
+Version:       1.8.0.2
 Release:       1%{?dist}
 Summary:       Core git tools
 License:       GPL
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/gitweb/gitweb.perl 
new/git-1.8.0.2/gitweb/gitweb.perl
--- old/git-1.8.0.1/gitweb/gitweb.perl  2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/gitweb/gitweb.perl  2012-12-10 22:53:39.000000000 +0100
@@ -270,16 +270,15 @@
 our %highlight_ext = (
        # main extensions, defining name of syntax;
        # see files in /usr/share/highlight/langDefs/ directory
-       map { $_ => $_ }
-               qw(py c cpp rb java css php sh pl js tex bib xml awk bat ini 
spec tcl sql make),
+       (map { $_ => $_ } qw(py rb java css js tex bib xml awk bat ini spec tcl 
sql)),
        # alternate extensions, see /etc/highlight/filetypes.conf
-       'h' => 'c',
-       map { $_ => 'sh'  } qw(bash zsh ksh),
-       map { $_ => 'cpp' } qw(cxx c++ cc),
-       map { $_ => 'php' } qw(php3 php4 php5 phps),
-       map { $_ => 'pl'  } qw(perl pm), # perhaps also 'cgi'
-       map { $_ => 'make'} qw(mak mk),
-       map { $_ => 'xml' } qw(xhtml html htm),
+       (map { $_ => 'c'   } qw(c h)),
+       (map { $_ => 'sh'  } qw(sh bash zsh ksh)),
+       (map { $_ => 'cpp' } qw(cpp cxx c++ cc)),
+       (map { $_ => 'php' } qw(php php3 php4 php5 phps)),
+       (map { $_ => 'pl'  } qw(pl perl pm)), # perhaps also 'cgi'
+       (map { $_ => 'make'} qw(make mak mk)),
+       (map { $_ => 'xml' } qw(xml xhtml html htm)),
 );
 
 # You define site-wide feature defaults here; override them with
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/notes.c new/git-1.8.0.2/notes.c
--- old/git-1.8.0.1/notes.c     2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/notes.c     2012-12-10 22:53:39.000000000 +0100
@@ -1231,7 +1231,7 @@
        }
 
        if (output_encoding && *output_encoding &&
-                       strcmp(utf8, output_encoding)) {
+           !is_encoding_utf8(output_encoding)) {
                char *reencoded = reencode_string(msg, output_encoding, utf8);
                if (reencoded) {
                        free(msg);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/pretty.c new/git-1.8.0.2/pretty.c
--- old/git-1.8.0.1/pretty.c    2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/pretty.c    2012-12-10 22:53:39.000000000 +0100
@@ -571,7 +571,7 @@
                return NULL;
        encoding = get_header(commit, "encoding");
        use_encoding = encoding ? encoding : utf8;
-       if (!strcmp(use_encoding, output_encoding))
+       if (same_encoding(use_encoding, output_encoding))
                if (encoding) /* we'll strip encoding header later */
                        out = xstrdup(commit->buffer);
                else
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/refs.c new/git-1.8.0.2/refs.c
--- old/git-1.8.0.1/refs.c      2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/refs.c      2012-12-10 22:53:39.000000000 +0100
@@ -1770,7 +1770,7 @@
         * packed one.  Also, if it was not loose we need to repack
         * without it.
         */
-       ret |= repack_without_ref(refname);
+       ret |= repack_without_ref(lock->ref_name);
 
        unlink_or_warn(git_path("logs/%s", lock->ref_name));
        invalidate_ref_cache(NULL);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/sequencer.c new/git-1.8.0.2/sequencer.c
--- old/git-1.8.0.1/sequencer.c 2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/sequencer.c 2012-12-10 22:53:39.000000000 +0100
@@ -60,7 +60,7 @@
 
        out->reencoded_message = NULL;
        out->message = commit->buffer;
-       if (strcmp(encoding, git_commit_encoding))
+       if (same_encoding(encoding, git_commit_encoding))
                out->reencoded_message = reencode_string(commit->buffer,
                                        git_commit_encoding, encoding);
        if (out->reencoded_message)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/t/t1400-update-ref.sh 
new/git-1.8.0.2/t/t1400-update-ref.sh
--- old/git-1.8.0.1/t/t1400-update-ref.sh       2012-11-26 04:18:01.000000000 
+0100
+++ new/git-1.8.0.2/t/t1400-update-ref.sh       2012-12-10 22:53:39.000000000 
+0100
@@ -74,6 +74,24 @@
 '
 rm -f .git/$m
 
+test_expect_success \
+       "create $m (by HEAD)" \
+       "git update-ref HEAD $A &&
+        test $A"' = $(cat .git/'"$m"')'
+test_expect_success \
+       "pack refs" \
+       "git pack-refs --all"
+test_expect_success \
+       "move $m (by HEAD)" \
+       "git update-ref HEAD $B $A &&
+        test $B"' = $(cat .git/'"$m"')'
+test_expect_success "delete $m (by HEAD) should remove both packed and loose 
$m" '
+       git update-ref -d HEAD $B &&
+       ! grep "$m" .git/packed-refs &&
+       ! test -f .git/$m
+'
+rm -f .git/$m
+
 cp -f .git/HEAD .git/HEAD.orig
 test_expect_success "delete symref without dereference" '
        git update-ref --no-deref -d HEAD &&
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/t/t4006-diff-mode.sh 
new/git-1.8.0.2/t/t4006-diff-mode.sh
--- old/git-1.8.0.1/t/t4006-diff-mode.sh        2012-11-26 04:18:01.000000000 
+0100
+++ new/git-1.8.0.2/t/t4006-diff-mode.sh        2012-12-10 22:53:39.000000000 
+0100
@@ -32,28 +32,28 @@
        git commit -m binbin
 '
 
-test_expect_success '--stat output after text chmod' '
-       test_chmod -x rezrov &&
-       echo " 0 files changed" >expect &&
-       git diff HEAD --stat >actual &&
-       test_i18ncmp expect actual
-'
-
-test_expect_success '--shortstat output after text chmod' '
-       git diff HEAD --shortstat >actual &&
-       test_i18ncmp expect actual
-'
-
-test_expect_success '--stat output after binary chmod' '
-       test_chmod +x binbin &&
-       echo " 0 files changed" >expect &&
-       git diff HEAD --stat >actual &&
-       test_i18ncmp expect actual
-'
-
-test_expect_success '--shortstat output after binary chmod' '
-       git diff HEAD --shortstat >actual &&
-       test_i18ncmp expect actual
-'
+# test_expect_success '--stat output after text chmod' '
+#      test_chmod -x rezrov &&
+#      echo " 0 files changed" >expect &&
+#      git diff HEAD --stat >actual &&
+#      test_i18ncmp expect actual
+# '
+#
+# test_expect_success '--shortstat output after text chmod' '
+#      git diff HEAD --shortstat >actual &&
+#      test_i18ncmp expect actual
+# '
+#
+# test_expect_success '--stat output after binary chmod' '
+#      test_chmod +x binbin &&
+#      echo " 0 files changed" >expect &&
+#      git diff HEAD --stat >actual &&
+#      test_i18ncmp expect actual
+# '
+#
+# test_expect_success '--shortstat output after binary chmod' '
+#      git diff HEAD --shortstat >actual &&
+#      test_i18ncmp expect actual
+# '
 
 test_done
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/t/t4049-diff-stat-count.sh 
new/git-1.8.0.2/t/t4049-diff-stat-count.sh
--- old/git-1.8.0.1/t/t4049-diff-stat-count.sh  2012-11-26 04:18:01.000000000 
+0100
+++ new/git-1.8.0.2/t/t4049-diff-stat-count.sh  2012-12-10 22:53:39.000000000 
+0100
@@ -4,19 +4,62 @@
 test_description='diff --stat-count'
 . ./test-lib.sh
 
-test_expect_success setup '
+test_expect_success 'setup' '
        >a &&
        >b &&
        >c &&
        >d &&
        git add a b c d &&
-       chmod +x c d &&
+       git commit -m initial
+'
+
+test_expect_success 'mode-only change show as a 0-line change' '
+       git reset --hard &&
+       test_chmod +x b d &&
+       echo a >a &&
+       echo c >c &&
+       cat >expect <<-\EOF
+        a | 1 +
+        b | 0
+        ...
+        4 files changed, 2 insertions(+)
+       EOF
+       git diff --stat --stat-count=2 HEAD >actual &&
+       test_i18ncmp expect actual
+'
+
+test_expect_success 'binary changes do not count in lines' '
+       git reset --hard &&
+       echo a >a &&
+       echo c >c &&
+       cat "$TEST_DIRECTORY"/test-binary-1.png >d &&
+       cat >expect <<-\EOF
+        a | 1 +
+        c | 1 +
+        ...
+        3 files changed, 2 insertions(+)
+       EOF
+       git diff --stat --stat-count=2 >actual &&
+       test_i18ncmp expect actual
+'
+
+test_expect_success 'exclude unmerged entries from total file count' '
+       git reset --hard &&
        echo a >a &&
        echo b >b &&
+       git ls-files -s a >x &&
+       git rm -f d &&
+       for stage in 1 2 3
+       do
+               sed -e "s/ 0    a/ $stage       d/" x
+       done |
+       git update-index --index-info &&
+       echo d >d &&
        cat >expect <<-\EOF
         a | 1 +
         b | 1 +
-        2 files changed, 2 insertions(+)
+        ...
+        3 files changed, 3 insertions(+)
        EOF
        git diff --stat --stat-count=2 >actual &&
        test_i18ncmp expect actual
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/t/t4205-log-pretty-formats.sh 
new/git-1.8.0.2/t/t4205-log-pretty-formats.sh
--- old/git-1.8.0.1/t/t4205-log-pretty-formats.sh       2012-11-26 
04:18:01.000000000 +0100
+++ new/git-1.8.0.2/t/t4205-log-pretty-formats.sh       2012-12-10 
22:53:39.000000000 +0100
@@ -85,7 +85,7 @@
 
 test_expect_success 'NUL separation with --stat' '
        stat0_part=$(git diff --stat HEAD^ HEAD) &&
-       stat1_part=$(git diff --stat --root HEAD^) &&
+       stat1_part=$(git diff-tree --no-commit-id --stat --root HEAD^) &&
        printf "add bar\n$stat0_part\n\0initial\n$stat1_part\n" >expected &&
        git log -z --stat --pretty="format:%s" >actual &&
        test_i18ncmp expected actual
@@ -93,7 +93,7 @@
 
 test_expect_failure 'NUL termination with --stat' '
        stat0_part=$(git diff --stat HEAD^ HEAD) &&
-       stat1_part=$(git diff --stat --root HEAD^) &&
+       stat1_part=$(git diff-tree --no-commit-id --stat --root HEAD^) &&
        printf "add bar\n$stat0_part\n\0initial\n$stat1_part\n\0" >expected &&
        git log -z --stat --pretty="tformat:%s" >actual &&
        test_i18ncmp expected actual
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/t/t9810-git-p4-rcs.sh 
new/git-1.8.0.2/t/t9810-git-p4-rcs.sh
--- old/git-1.8.0.1/t/t9810-git-p4-rcs.sh       2012-11-26 04:18:01.000000000 
+0100
+++ new/git-1.8.0.2/t/t9810-git-p4-rcs.sh       2012-12-10 22:53:39.000000000 
+0100
@@ -155,6 +155,25 @@
        )
 '
 
+# perl $File:: bug check
+test_expect_success 'ktext expansion should not expand multi-line $File::' '
+       (
+               cd "$cli" &&
+               cat >lv.pm <<-\EOF
+               my $wanted = sub { my $f = $File::Find::name;
+                                   if ( -f && $f =~ /foo/ ) {
+               EOF
+               p4 add -t ktext lv.pm &&
+               p4 submit -d "lv.pm"
+       ) &&
+       test_when_finished cleanup_git &&
+       git p4 clone --dest="$git" //depot &&
+       (
+               cd "$git" &&
+               test_cmp "$cli/lv.pm" lv.pm
+       )
+'
+
 #
 # Do not scrub anything but +k or +ko files.  Sneak a change into
 # the cli file so that submit will get a conflict.  Make sure that
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/utf8.c new/git-1.8.0.2/utf8.c
--- old/git-1.8.0.1/utf8.c      2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/utf8.c      2012-12-10 22:53:39.000000000 +0100
@@ -423,6 +423,13 @@
        return 0;
 }
 
+int same_encoding(const char *src, const char *dst)
+{
+       if (is_encoding_utf8(src) && is_encoding_utf8(dst))
+               return 1;
+       return !strcasecmp(src, dst);
+}
+
 /*
  * Given a buffer and its encoding, return it re-encoded
  * with iconv.  If the conversion fails, returns NULL.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/utf8.h new/git-1.8.0.2/utf8.h
--- old/git-1.8.0.1/utf8.h      2012-11-26 04:18:01.000000000 +0100
+++ new/git-1.8.0.2/utf8.h      2012-12-10 22:53:39.000000000 +0100
@@ -7,6 +7,7 @@
 int utf8_strwidth(const char *string);
 int is_utf8(const char *text);
 int is_encoding_utf8(const char *name);
+int same_encoding(const char *, const char *);
 
 int strbuf_add_wrapped_text(struct strbuf *buf,
                const char *text, int indent, int indent2, int width);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/git-1.8.0.1/version new/git-1.8.0.2/version
--- old/git-1.8.0.1/version     2012-11-26 04:18:02.000000000 +0100
+++ new/git-1.8.0.2/version     2012-12-10 22:53:39.000000000 +0100
@@ -1 +1 @@
-1.8.0.1
+1.8.0.2

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to