1. 11 4月, 2018 2 次提交
  2. 03 4月, 2018 7 次提交
  3. 14 3月, 2018 2 次提交
  4. 23 2月, 2018 2 次提交
    • J
      revision: drop --show-all option · f74bbc8d
      Jeff King 提交于
      This was an undocumented debugging aid that does not seem to
      have come in handy in the past decade, judging from its lack
      of mentions on the mailing list.
      
      Let's drop it in the name of simplicity. This is morally a
      revert of 3131b713 (Add "--show-all" revision walker flag
      for debugging, 2008-02-09), but note that I did leave in the
      mapping of UNINTERESTING to "^" in get_revision_mark(). I
      don't think this would be possible to trigger with the
      current code, but it's the only sensible marker.
      
      We'll skip the usual deprecation period because this was
      explicitly a debugging aid that was never documented.
      Signed-off-by: NJeff King <peff@peff.net>
      Acked-by: NLinus Torvalds <torvalds@linux-foundation.org>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      f74bbc8d
    • J
      commit: drop uses of get_cached_commit_buffer() · 7fa31b64
      Jeff King 提交于
      The "--show-all" revision option shows UNINTERESTING
      commits. Some of these commits may be unparsed when we try
      to show them (since we may or may not need to walk their
      parents to fulfill the request).
      
      Commit 3131b713 (Add "--show-all" revision walker flag for
      debugging, 2008-02-09) resolved this by just skipping
      pretty-printing for commits without their object contents
      cached, saying:
      
        Because we now end up listing commits we may not even have been parsed
        at all "show_log" and "show_commit" need to protect against commits
        that don't have a commit buffer entry.
      
      That was the easy fix to avoid the pretty-printer segfaulting,
      but:
      
        1. It doesn't work for all formats. E.g., --oneline
           prints the oid for each such commit but not a trailing
           newline, leading to jumbled output.
      
        2. It only affects some commits, depending on whether we
           happened to parse them or not (so if they were at the
           tip of an UNINTERESTING starting point, or if we
           happened to traverse over them, you'd see more data).
      
        3. It unncessarily ties the decision to show the verbose
           header to whether the commit buffer was cached. That
           makes it harder to change the logic around caching
           (e.g., if we could traverse without actually loading
           the full commit objects).
      
      These days it's safe to feed such a commit to the
      pretty-print code. Since be5c9fb9 (logmsg_reencode: lazily
      load missing commit buffers, 2013-01-26), we'll load it on
      demand in such a case. So let's just always show the verbose
      headers.
      
      This does change the behavior of plumbing, but:
      
        a. The --show-all option was explicitly introduced as a
           debugging aid, and was never documented (and has rarely
           even been mentioned on the list by git devs).
      
        b. Avoiding the commits was already not deterministic due
           to (2) above. So the caller might have seen full
           headers for these commits anyway, and would need to be
           prepared for it.
      Signed-off-by: NJeff King <peff@peff.net>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      7fa31b64
  5. 16 2月, 2018 27 次提交
    • J
      Git 2.16.2 · ffa95249
      Junio C Hamano 提交于
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      ffa95249
    • J
      Merge branch 'ab/doc-cat-file-e-still-shows-errors' into maint · c93150cf
      Junio C Hamano 提交于
      Doc update.
      
      * ab/doc-cat-file-e-still-shows-errors:
        cat-file doc: document that -e will return some output
      c93150cf
    • J
      Merge branch 'as/read-tree-prefix-doc-fix' into maint · d4e528ef
      Junio C Hamano 提交于
      Doc update.
      
      * as/read-tree-prefix-doc-fix:
        doc/read-tree: remove obsolete remark
      d4e528ef
    • J
      Merge branch 'nd/add-i-ignore-submodules' into maint · 2409e103
      Junio C Hamano 提交于
      "git add -p" was taught to ignore local changes to submodules as
      they do not interfere with the partial addition of regular changes
      anyway.
      
      * nd/add-i-ignore-submodules:
        add--interactive: ignore submodule changes except HEAD
      2409e103
    • J
      Merge branch 'tg/stash-with-pathspec-fix' into maint · 984c8337
      Junio C Hamano 提交于
      "git stash -- <pathspec>" incorrectly blew away untracked files in
      the directory that matched the pathspec, which has been corrected.
      
      * tg/stash-with-pathspec-fix:
        stash: don't delete untracked files that match pathspec
      984c8337
    • J
      Merge branch 'jk/abort-clone-with-existing-dest' into maint · 1363914a
      Junio C Hamano 提交于
      "git clone $there $here" is allowed even when here directory exists
      as long as it is an empty directory, but the command incorrectly
      removed it upon a failure of the operation.
      
      * jk/abort-clone-with-existing-dest:
        clone: do not clean up directories we didn't create
        clone: factor out dir_exists() helper
        t5600: modernize style
        t5600: fix outdated comment about unborn HEAD
      1363914a
    • J
      Merge branch 'jc/merge-symlink-ours-theirs' into maint · ff19620f
      Junio C Hamano 提交于
      "git merge -Xours/-Xtheirs" learned to use our/their version when
      resolving a conflicting updates to a symbolic link.
      
      * jc/merge-symlink-ours-theirs:
        merge: teach -Xours/-Xtheirs to symbolic link merge
      ff19620f
    • J
      Merge branch 'rs/lose-leak-pending' into maint · e17cec27
      Junio C Hamano 提交于
      API clean-up around revision traversal.
      
      * rs/lose-leak-pending:
        commit: remove unused function clear_commit_marks_for_object_array()
        revision: remove the unused flag leak_pending
        checkout: avoid using the rev_info flag leak_pending
        bundle: avoid using the rev_info flag leak_pending
        bisect: avoid using the rev_info flag leak_pending
        object: add clear_commit_marks_all()
        ref-filter: use clear_commit_marks_many() in do_merge_filter()
        commit: use clear_commit_marks_many() in remove_redundant()
        commit: avoid allocation in clear_commit_marks_many()
      e17cec27
    • J
      Merge branch 'jm/svn-pushmergeinfo-fix' into maint · 04afcc22
      Junio C Hamano 提交于
      "git svn dcommit" did not take into account the fact that a
      svn+ssh:// URL with a username@ (typically used for pushing) refers
      to the same SVN repository without the username@ and failed when
      svn.pushmergeinfo option is set.
      
      * jm/svn-pushmergeinfo-fix:
        git-svn: fix svn.pushmergeinfo handling of svn+ssh usernames.
      04afcc22
    • J
      Merge branch 'dk/describe-all-output-fix' into maint · 468dc22e
      Junio C Hamano 提交于
      An old regression in "git describe --all $annotated_tag^0" has been
      fixed.
      
      * dk/describe-all-output-fix:
        describe: prepend "tags/" when describing tags with embedded name
      468dc22e
    • J
      Merge branch 'ab/perf-grep-threads' into maint · af38deeb
      Junio C Hamano 提交于
      More perf tests for threaded grep
      
      * ab/perf-grep-threads:
        perf: amend the grep tests to test grep.threads
      af38deeb
    • J
      Merge branch 'bc/hash-algo' · 0fd90dab
      Junio C Hamano 提交于
      More abstraction of hash function from the codepath.
      
      * bc/hash-algo:
        hash: update obsolete reference to SHA1_HEADER
        bulk-checkin: abstract SHA-1 usage
        csum-file: abstract uses of SHA-1
        csum-file: rename sha1file to hashfile
        read-cache: abstract away uses of SHA-1
        pack-write: switch various SHA-1 values to abstract forms
        pack-check: convert various uses of SHA-1 to abstract forms
        fast-import: switch various uses of SHA-1 to the_hash_algo
        sha1_file: switch uses of SHA-1 to the_hash_algo
        builtin/unpack-objects: switch uses of SHA-1 to the_hash_algo
        builtin/index-pack: improve hash function abstraction
        hash: create union for hash context allocation
        hash: move SHA-1 macros to hash.h
      0fd90dab
    • J
      Merge branch 'nd/ignore-glob-doc-update' · 0dbd562c
      Junio C Hamano 提交于
      Doc update.
      
      * nd/ignore-glob-doc-update:
        gitignore.txt: elaborate shell glob syntax
      0dbd562c
    • J
      Merge branch 'tg/reset-hard-show-head-with-pretty' · e6b4a549
      Junio C Hamano 提交于
      The way "git reset --hard" reports the commit the updated HEAD
      points at is made consistent with the way how the commit title is
      generated by the other parts of the system.  This matters when the
      title is spread across physically multiple lines.
      
      * tg/reset-hard-show-head-with-pretty:
        reset --hard: make use of the pretty machinery
      e6b4a549
    • J
      Merge branch 'rs/cocci-strbuf-addf-to-addstr' · ab66fc27
      Junio C Hamano 提交于
      * rs/cocci-strbuf-addf-to-addstr:
        cocci: simplify check for trivial format strings
      ab66fc27
    • J
      Merge branch 'nd/trace-index-ops' · 090dbea6
      Junio C Hamano 提交于
      * nd/trace-index-ops:
        trace: measure where the time is spent in the index-heavy operations
      090dbea6
    • J
      Merge branch 'cc/perf-aggregate' · 9b6734e5
      Junio C Hamano 提交于
      "make perf" enhancement.
      
      * cc/perf-aggregate:
        perf/aggregate: sort JSON fields in output
        perf/aggregate: add --reponame option
        perf/aggregate: add --subsection option
      9b6734e5
    • J
      Merge branch 'ab/wildmatch-tests' · bfc817d8
      Junio C Hamano 提交于
      More tests for wildmatch functions.
      
      * ab/wildmatch-tests:
        wildmatch test: mark test as EXPENSIVE_ON_WINDOWS
        test-lib: add an EXPENSIVE_ON_WINDOWS prerequisite
        wildmatch test: create & test files on disk in addition to in-memory
        wildmatch test: perform all tests under all wildmatch() modes
        wildmatch test: use test_must_fail, not ! for test-wildmatch
        wildmatch test: remove dead fnmatch() test code
        wildmatch test: use a paranoia pattern from nul_match()
        wildmatch test: don't try to vertically align our output
        wildmatch test: use more standard shell style
        wildmatch test: indent with tabs, not spaces
      bfc817d8
    • J
      Merge branch 'po/object-id' · 8be8342b
      Junio C Hamano 提交于
      Conversion from uchar[20] to struct object_id continues.
      
      * po/object-id:
        sha1_file: rename hash_sha1_file_literally
        sha1_file: convert write_loose_object to object_id
        sha1_file: convert force_object_loose to object_id
        sha1_file: convert write_sha1_file to object_id
        notes: convert write_notes_tree to object_id
        notes: convert combine_notes_* to object_id
        commit: convert commit_tree* to object_id
        match-trees: convert splice_tree to object_id
        cache: clear whole hash buffer with oidclr
        sha1_file: convert hash_sha1_file to object_id
        dir: convert struct sha1_stat to use object_id
        sha1_file: convert pretend_sha1_file to object_id
      8be8342b
    • J
      Merge branch 'sb/pull-rebase-submodule' · 157ee050
      Junio C Hamano 提交于
      "git pull --rebase" did not pass verbosity setting down when
      recursing into a submodule.
      
      * sb/pull-rebase-submodule:
        builtin/pull: respect verbosity settings in submodules
      157ee050
    • J
      Merge branch 'kg/packed-ref-cache-fix' · 9db22910
      Junio C Hamano 提交于
      Avoid mmapping small files while using packed refs (especially ones
      with zero size, which would cause later munmap() to fail).
      
      * kg/packed-ref-cache-fix:
        packed_ref_cache: don't use mmap() for small files
        load_contents(): don't try to mmap an empty file
        packed_ref_iterator_begin(): make optimization more general
        find_reference_location(): make function safe for empty snapshots
        create_snapshot(): use `xmemdupz()` rather than a strbuf
        struct snapshot: store `start` rather than `header_len`
      9db22910
    • J
      Merge branch 'jt/fsck-code-cleanup' · 52b7ab31
      Junio C Hamano 提交于
      Plug recently introduced leaks in fsck.
      
      * jt/fsck-code-cleanup:
        fsck: fix leak when traversing trees
      52b7ab31
    • J
      Merge branch 'en/merge-recursive-fixes' · ae0d0795
      Junio C Hamano 提交于
      * en/merge-recursive-fixes:
        merge-recursive: add explanation for src_entry and dst_entry
        merge-recursive: fix logic ordering issue
        Tighten and correct a few testcases for merging and cherry-picking
      ae0d0795
    • J
      Merge branch 'jc/worktree-add-short-help' · cc7655a5
      Junio C Hamano 提交于
      Error message fix.
      
      * jc/worktree-add-short-help:
        worktree: say that "add" takes an arbitrary commit in short-help
      cc7655a5
    • J
      Merge branch 'ab/sha1dc-build' · a66b51c6
      Junio C Hamano 提交于
      Push the submodule version of collision-detecting SHA-1 hash
      implementation a bit harder on builders.
      
      * ab/sha1dc-build:
        sha1dc_git.h: re-arrange an ifdef chain for a subsequent change
        Makefile: under "make dist", include the sha1collisiondetection submodule
        Makefile: don't error out under DC_SHA1_EXTERNAL if DC_SHA1_SUBMODULE=auto
      a66b51c6
    • J
      packfile: refactor hash search with fanout table · b4e00f73
      Jonathan Tan 提交于
      Subsequent patches will introduce file formats that make use of a fanout
      array and a sorted table containing hashes, just like packfiles.
      Refactor the hash search in packfile.c into its own function, so that
      those patches can make use of it as well.
      Signed-off-by: NJonathan Tan <jonathantanmy@google.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      b4e00f73
    • J
      packfile: remove GIT_DEBUG_LOOKUP log statements · 4669e7d6
      Jonathan Tan 提交于
      In commit 628522ec ("sha1-lookup: more memory efficient search in
      sorted list of SHA-1", 2008-04-09), a different algorithm for searching
      a sorted list was introduced, together with a set of log statements
      guarded by GIT_DEBUG_LOOKUP that are invoked both when using that
      algorithm and when using the existing binary search. Those log
      statements was meant for experiments and debugging, but with the removal
      of the aforementioned different algorithm in commit f1068efe
      ("sha1_file: drop experimental GIT_USE_LOOKUP search", 2017-08-09),
      those log statements are probably no longer necessary.
      
      Remove those statements.
      Signed-off-by: NJonathan Tan <jonathantanmy@google.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      4669e7d6