1. 04 11月, 2012 8 次提交
  2. 29 10月, 2012 8 次提交
    • J
      Merge branch 'rs/branch-del-symref' · 9c503744
      Jeff King 提交于
      A symbolic ref refs/heads/SYM was not correctly removed with
      "git branch -d SYM"; the command removed the ref pointed by
      SYM instead.
      
      * rs/branch-del-symref:
        branch: show targets of deleted symrefs, not sha1s
        branch: skip commit checks when deleting symref branches
        branch: delete symref branch, not its target
        branch: factor out delete_branch_config()
        branch: factor out check_branch_commit()
      9c503744
    • J
      Merge branch 'nd/status-long' · eeb2535f
      Jeff King 提交于
      Allow an earlier "--short" option on the command line to be
      countermanded with the "--long" option for "git status" and "git
      commit".
      
      * nd/status-long:
        status: add --long output format option
      eeb2535f
    • J
      Merge branch 'jk/sh-setup-in-filter-branch' · deb24581
      Jeff King 提交于
      Refactoring to avoid code duplication in shell scripts.
      
      * jk/sh-setup-in-filter-branch:
        filter-branch: use git-sh-setup's ident parsing functions
        git-sh-setup: refactor ident-parsing functions
      deb24581
    • J
      Merge branch 'nd/grep-true-path' · e034d1bb
      Jeff King 提交于
      "git grep -e pattern <tree>" asked the attribute system to read
      "<tree>:.gitattributes" file in the working tree, which was
      nonsense.
      
      * nd/grep-true-path:
        grep: stop looking at random places for .gitattributes
      e034d1bb
    • J
      Merge branch 'jk/maint-http-init-not-in-result-handler' · 58f3f989
      Jeff King 提交于
      Further clean-up to the http codepath that picks up results after
      cURL library is done with one request slot.
      
      * jk/maint-http-init-not-in-result-handler:
        http: do not set up curl auth after a 401
        remote-curl: do not call run_slot repeatedly
      58f3f989
    • J
      Merge branch 'jc/grep-pcre-loose-ends' · d2f4469b
      Jeff King 提交于
      "git log -F -E --grep='<ere>'" failed to use the given <ere>
      pattern as extended regular expression, and instead looked for the
      string literally.  The early part of this series is a fix for it;
      the latter part teaches log to respect the grep.* configuration.
      
      * jc/grep-pcre-loose-ends:
        log: honor grep.* configuration
        log --grep: accept --basic-regexp and --perl-regexp
        log --grep: use the same helper to set -E/-F options as "git grep"
        revisions: initialize revs->grep_filter using grep_init()
        grep: move pattern-type bits support to top-level grep.[ch]
        grep: move the configuration parsing logic to grep.[ch]
        builtin/grep.c: make configuration callback more reusable
      d2f4469b
    • J
      Merge branch 'jl/submodule-add-by-name' · fdb4d271
      Jeff King 提交于
      If you remove a submodule, in order to keep the repository so that
      "git checkout" to an older commit in the superproject history can
      resurrect the submodule, the real repository will stay in $GIT_DIR
      of the superproject.  A later "git submodule add $path" to add a
      different submodule at the same path will fail.  Diagnose this case
      a bit better, and if the user really wants to add an unrelated
      submodule at the same path, give the "--name" option to give it a
      place in $GIT_DIR of the superproject that does not conflict with
      the original submodule.
      
      * jl/submodule-add-by-name:
        submodule add: Fail when .git/modules/<name> already exists unless forced
        Teach "git submodule add" the --name option
      fdb4d271
    • J
      Merge branch 'jl/submodule-rm' · d21240fa
      Jeff King 提交于
      "git rm submodule" cannot blindly remove a submodule directory as
      its working tree may have local changes, and worse yet, it may even
      have its repository embedded in it.  Teach it some special cases
      where it is safe to remove a submodule, specifically, when there is
      no local changes in the submodule working tree, and its repository
      is not embedded in its working tree but is elsewhere and uses the
      gitfile mechanism to point at it.
      
      * jl/submodule-rm:
        submodule: teach rm to remove submodules unless they contain a git directory
      d21240fa
  3. 28 10月, 2012 2 次提交
    • T
      Fix t9200 on case insensitive file systems · e342acc6
      Torsten Bögershausen 提交于
      t9200 defines $CVSROOT where cvs should init its repository
      $CVSROOT is set to $PWD/cvsroot.
      cvs init is supposed to create the repository inside $PWD/cvsroot/CVSROOT
      
      "cvs init" (e.g. version  1.11.23) checks if the last element of the path is
      "CVSROOT", and if a directory with e.g. $PWD/cvsroot/CVSROOT already exists.
      
      For such a $CVSROOT cvs refuses to init a repository here:
      "Cannot initialize repository under existing CVSROOT:
      
      On a case insenstive file system cvsroot and CVSROOT are the same directories
      and t9200 fails.
      
      Solution: use $PWD/tmpcvsroot instead of cvsroot $PWD/cvsroot
      Signed-off-by: NTorsten Bögershausen <tboegi@web.de>
      Signed-off-by: NJeff King <peff@peff.net>
      e342acc6
    • R
      mailmap: avoid out-of-bounds memory access · 3174bc5c
      Romain Francoise 提交于
      AddressSanitizer (http://clang.llvm.org/docs/AddressSanitizer.html)
      complains of a one-byte buffer underflow in parse_name_and_email() while
      running the test suite. And indeed, if one of the lines in the mailmap
      begins with '<', we dereference the address just before the beginning of
      the buffer when looking for whitespace to remove, before checking that
      we aren't going too far.
      
      So reverse the order of the tests to make sure that we don't read
      outside the buffer.
      Signed-off-by: NRomain Francoise <romain@orebokech.com>
      Signed-off-by: NJeff King <peff@peff.net>
      3174bc5c
  4. 26 10月, 2012 2 次提交
  5. 25 10月, 2012 14 次提交
    • S
      configure: fix some output message · 49aeead2
      Stefano Lattarini 提交于
      Before this change, output from ./configure could contain
      botched wording like this:
      
          checking Checking for POSIX Threads with '-pthread'... yes
      
      instead of the intended:
      
          checking for POSIX Threads with '-pthread'... yes
      Signed-off-by: NStefano Lattarini <stefano.lattarini@gmail.com>
      Signed-off-by: NJeff King <peff@peff.net>
      49aeead2
    • P
      Doc repository-layout: Show refs/replace · 11fbe18e
      Philip Oakley 提交于
      Signed-off-by: NPhilip Oakley <philipoakley@iee.org>
      Signed-off-by: NJeff King <peff@peff.net>
      11fbe18e
    • M
      Documentation: remote tracking branch -> remote-tracking branch · a6d3bde5
      Matthieu Moy 提交于
      This change was already done by 0e615b25 (Matthieu Moy, Tue Nov 2
      2010, Replace "remote tracking" with "remote-tracking"), but new
      instances of remote tracking (without dash) were introduced in the
      meantime.
      Signed-off-by: NMatthieu Moy <Matthieu.Moy@imag.fr>
      Signed-off-by: NJeff King <peff@peff.net>
      a6d3bde5
    • J
      Merge branch 'jk/strbuf-detach-always-non-null' · 2cfceefa
      Jeff King 提交于
      * jk/strbuf-detach-always-non-null:
        strbuf: always return a non-NULL value from strbuf_detach
      2cfceefa
    • J
      Merge branch 'js/mingw-fflush-errno' · bbbd0573
      Jeff King 提交于
      * js/mingw-fflush-errno:
        maybe_flush_or_die: move a too-loose Windows specific error
      bbbd0573
    • J
      Merge branch 'da/mergetools-p4' · 33d3c6bb
      Jeff King 提交于
      * da/mergetools-p4:
        mergetools/p4merge: Handle "/dev/null"
      33d3c6bb
    • J
      Merge branch 'jc/test-say-color-avoid-echo-escape' · 4cd31a63
      Jeff King 提交于
      Recent nd/wildmatch series was the first to reveal this ancient bug
      in the test scaffolding.
      
      * jc/test-say-color-avoid-echo-escape:
        test-lib: Fix say_color () not to interpret \a\b\c in the message
      4cd31a63
    • J
      Merge branch 'nd/attr-match-optim' · 70d18257
      Jeff King 提交于
      Trivial and obvious optimization for finding attributes that match
      a given path.
      
      * nd/attr-match-optim:
        attr: avoid searching for basename on every match
        attr: avoid strlen() on every match
      70d18257
    • J
      Merge branch 'jk/peel-ref' · 315ea32f
      Jeff King 提交于
      Speeds up "git upload-pack" (what is invoked by "git fetch" on the
      other side of the connection) by reducing the cost to advertise the
      branches and tags that are available in the repository.
      
      * jk/peel-ref:
        upload-pack: use peel_ref for ref advertisements
        peel_ref: check object type before loading
        peel_ref: do not return a null sha1
        peel_ref: use faster deref_tag_noverify
      315ea32f
    • J
      Merge branch 'bw/config-lift-variable-name-length-limit' · 6a83a6d5
      Jeff King 提交于
      The configuration parser had an unnecessary hardcoded limit on
      variable names that was not checked consistently. Lift the limit.
      
      * bw/config-lift-variable-name-length-limit:
        Remove the hard coded length limit on variable names in config files
      6a83a6d5
    • J
      Merge branch 'fa/remote-svn' · 530f2375
      Jeff King 提交于
      A GSoC project.
      
      * fa/remote-svn:
        Add a test script for remote-svn
        remote-svn: add marks-file regeneration
        Add a svnrdump-simulator replaying a dump file for testing
        remote-svn: add incremental import
        remote-svn: Activate import/export-marks for fast-import
        Create a note for every imported commit containing svn metadata
        vcs-svn: add fast_export_note to create notes
        Allow reading svn dumps from files via file:// urls
        remote-svn, vcs-svn: Enable fetching to private refs
        When debug==1, start fast-import with "--stats" instead of "--quiet"
        Add documentation for the 'bidi-import' capability of remote-helpers
        Connect fast-import to the remote-helper via pipe, adding 'bidi-import' capability
        Add argv_array_detach and argv_array_free_detached
        Add svndump_init_fd to allow reading dumps from arbitrary FDs
        Add git-remote-testsvn to Makefile
        Implement a remote helper for svn in C
      530f2375
    • J
      Merge branch 'jm/diff-context-config' · 8de8f9f6
      Jeff King 提交于
      Teaches a new configuration variable to "git diff" Porcelain and
      its friends.
      
      * jm/diff-context-config:
        t4055: avoid use of sed 'a' command
        diff: diff.context configuration gives default to -U
      8de8f9f6
    • J
      Merge branch 'jk/no-more-pre-exec-callback' · 55ff6300
      Jeff King 提交于
      Removes a workaround for buggy version of less older than version
      406.
      
      * jk/no-more-pre-exec-callback:
        pager: drop "wait for output to run less" hack
      55ff6300
    • P
      git-pull: Avoid merge-base on detached head · e980765c
      Phil Hord 提交于
      git pull --rebase does some clever tricks to find the base
      for $upstream, but it forgets that we may not have any
      branch at all.  When this happens, git merge-base reports its
      "usage" help in the middle of an otherwise successful
      rebase operation, because git-merge is called with one too
      few parameters.
      
      Since we do not need the merge-base trick in the case of a
      detached HEAD, detect this condition and bypass the clever
      trick and the usage noise.
      Signed-off-by: NPhil Hord <hordp@cisco.com>
      Signed-off-by: NJeff King <peff@peff.net>
      e980765c
  6. 22 10月, 2012 1 次提交
  7. 19 10月, 2012 5 次提交
    • J
      filter-branch: use git-sh-setup's ident parsing functions · 3c730fab
      Jeff King 提交于
      This saves us some code, but it also reduces the number of
      processes we start for each filtered commit. Since we can
      parse both author and committer in the same sed invocation,
      we save one process. And since the new interface avoids tr,
      we save 4 processes.
      
      It also avoids using "tr", which has had some odd
      portability problems reported with from Solaris's xpg6
      version.
      
      We also tweak one of the tests in t7003 to double-check that
      we are properly exporting the variables (because test-lib.sh
      exports GIT_AUTHOR_NAME, it will be automatically exported
      in subprograms. We override this to make sure that
      filter-branch handles it properly itself).
      Signed-off-by: NJeff King <peff@peff.net>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      3c730fab
    • J
      git-sh-setup: refactor ident-parsing functions · ce80ca56
      Jeff King 提交于
      The only ident-parsing function we currently provide is
      get_author_ident_from_commit. This is not very
      flexible for two reasons:
      
        1. It takes a commit as an argument, and can't read from
           commit headers saved on disk.
      
        2. It will only parse authors, not committers.
      
      This patch provides a more flexible interface which will
      parse multiple idents from a commit provide on stdin. We can
      easily use it as a building block for the current function
      to retain compatibility.
      Signed-off-by: NJeff King <peff@peff.net>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      ce80ca56
    • J
      status: add --long output format option · f3f47a1e
      Jeff King 提交于
      You can currently set the output format to --short or
      --porcelain. There is no --long, because we default to it
      already. However, you may want to override an alias that
      uses "--short" to get back to the default.
      
      This requires a little bit of refactoring, because currently
      we use STATUS_FORMAT_LONG internally to mean the same as
      "the user did not specify anything". By expanding the enum
      to include STATUS_FORMAT_NONE, we can distinguish between
      the implicit and explicit cases. This effects these
      conditions:
      
        1. The user has asked for NUL termination. With NONE, we
           currently default to turning on the porcelain mode.
           With an explicit --long, we would in theory use NUL
           termination with the long mode, but it does not support
           it. So we can just complain and die.
      
        2. When an output format is given to "git commit", we
           default to "--dry-run". This behavior would now kick in
           when "--long" is given, too.
      Signed-off-by: NJeff King <peff@peff.net>
      Signed-off-by: NNguyễn Thái Ngọc Duy <pclouds@gmail.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      f3f47a1e
    • R
      branch: show targets of deleted symrefs, not sha1s · 13baa9fe
      René Scharfe 提交于
      git branch reports the abbreviated hash of the head commit of
      a deleted branch to make it easier for a user to undo the
      operation.  For symref branches this doesn't help.  Print the
      symref target instead for them.
      Signed-off-by: NRene Scharfe <rene.scharfe@lsrfire.ath.cx>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      13baa9fe
    • R
      branch: skip commit checks when deleting symref branches · 0fe700e3
      René Scharfe 提交于
      Before a branch is deleted, we check that it points to a valid
      commit.  With -d we also check that the commit is a merged; this
      check is not done with -D.
      
      The reason for that is that commits pointed to by branches should
      never go missing; if they do then something broke and it's better
      to stop instead of adding to the mess.  And a non-merged commit
      may contain changes that are worth preserving, so we require the
      stronger option -D instead of -d to get rid of them.
      
      If a branch consists of a symref, these concerns don't apply.
      Deleting such a branch can't make a commit become unreferenced,
      so we don't need to check if it is merged, or even if it is
      actually a valid commit.  Skip them in that case.  This allows
      us to delete dangling symref branches.
      Signed-off-by: NRene Scharfe <rene.scharfe@lsrfire.ath.cx>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      0fe700e3