Skip to content
Commits on Sep 3, 2015
  1. @stefanbeller @gitster

    submodule: rewrite `module_list` shell function in C

    stefanbeller committed with gitster
    Most of the submodule operations work on a set of submodules.
    Calculating and using this set is usually done via:
    
           module_list "$@" | {
               while read mode sha1 stage sm_path
               do
                    # the actual operation
               done
           }
    
    Currently the function `module_list` is implemented in the
    git-submodule.sh as a shell script wrapping a perl script.
    The rewrite is in C, such that it is faster and can later be
    easily adapted when other functions are rewritten in C.
    
    git-submodule.sh, similar to the builtin commands, will navigate
    to the top-most directory of the repository and keep the
    subdirectory as a variable. As the helper is called from
    within the git-submodule.sh script, we are already navigated
    to the root level, but the path arguments are still relative
    to the subdirectory we were in when calling git-submodule.sh.
    That's why there is a `--prefix` option pointing to an alternative
    path which to anchor relative path arguments.
    
    Signed-off-by: Stefan Beller <sbeller@google.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Aug 19, 2015
  1. @gitster

    Merge 'hv/submodule-config' to 'sb/submodule-helper'

    gitster committed
    * hv/submodule-config:
      submodule: allow erroneous values for the fetchRecurseSubmodules option
      submodule: use new config API for worktree configurations
      submodule: extract functions for config set and lookup
      submodule: implement a config API for lookup of .gitmodules values
  2. @gitster

    submodule: implement a config API for lookup of .gitmodules values

    Heiko Voigt committed with gitster
    In a superproject some commands need to interact with submodules. They
    need to query values from the .gitmodules file either from the worktree
    of from certain revisions. At the moment this is quite hard since a
    caller would need to read the .gitmodules file from the history and then
    parse the values. We want to provide an API for this so we have one
    place to get values from .gitmodules from any revision (including the
    worktree).
    
    The API is realized as a cache which allows us to lazily read
    .gitmodules configurations by commit into a runtime cache which can then
    be used to easily lookup values from it. Currently only the values for
    path or name are stored but it can be extended for any value needed.
    
    It is expected that .gitmodules files do not change often between
    commits. Thats why we lookup the .gitmodules sha1 from a commit and then
    either lookup an already parsed configuration or parse and cache an
    unknown one for each sha1. The cache is lazily build on demand for each
    requested commit.
    
    This cache can be used for all purposes which need knowledge about
    submodule configurations. Example use cases are:
    
     * Recursive submodule checkout needs to lookup a submodule name from
       its path when a submodule first appears. This needs be done before
       this configuration exists in the worktree.
    
     * The implementation of submodule support for 'git archive' needs to
       lookup the submodule name to generate the archive when given a
       revision that is not checked out.
    
     * 'git fetch' when given the --recurse-submodules=on-demand option (or
       configuration) needs to lookup submodule names by path from the
       database rather than reading from the worktree. For new submodule it
       needs to lookup the name from its path to allow cloning new
       submodules into the .git folder so they can be checked out without
       any network interaction when the user does a checkout of that
       revision.
    
    Signed-off-by: Heiko Voigt <hvoigt@hvoigt.net>
    Signed-off-by: Stefan Beller <sbeller@google.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jul 13, 2015
  1. @gitster

    Merge branch 'nd/multiple-work-trees'

    gitster committed
    "git checkout [<tree-ish>] <paths>" spent unnecessary cycles
    checking if the current branch was checked out elsewhere, when we
    know we are not switching the branches ourselves.
    
    * nd/multiple-work-trees:
      worktree: new place for "git prune --worktrees"
      checkout: don't check worktrees when not necessary
Commits on Jun 29, 2015
  1. @pclouds @gitster

    worktree: new place for "git prune --worktrees"

    pclouds committed with gitster
    Commit 23af91d (prune: strategies for linked checkouts - 2014-11-30)
    adds "--worktrees" to "git prune" without realizing that "git prune" is
    for object database only. This patch moves the same functionality to a
    new command "git worktree".
    
    Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Commits on Mar 12, 2015
  1. @pclouds @gitster

    t7063: tests for untracked cache

    pclouds committed with gitster
    Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Oct 20, 2014
  1. @gitster

    Merge branch 'cc/interpret-trailers'

    gitster committed
    A new filter to programatically edit the tail end of the commit log
    messages.
    
    * cc/interpret-trailers:
      Documentation: add documentation for 'git interpret-trailers'
      trailer: add tests for commands in config file
      trailer: execute command from 'trailer.<name>.command'
      trailer: add tests for "git interpret-trailers"
      trailer: add interpret-trailers command
      trailer: put all the processing together and print
      trailer: parse trailers from file or stdin
      trailer: process command line trailer arguments
      trailer: read and process config information
      trailer: process trailers from input message and arguments
      trailer: add data structures and basic functions
Commits on Oct 14, 2014
  1. @gitster

    Merge branch 'rs/sha1-array-test'

    gitster committed
    * rs/sha1-array-test:
      sha1-lookup: handle duplicates in sha1_pos()
      sha1-array: add test-sha1-array and basic tests
Commits on Oct 13, 2014
  1. @chriscool @gitster

    trailer: add interpret-trailers command

    chriscool committed with gitster
    This patch adds the "git interpret-trailers" command.
    This command uses the previously added process_trailers()
    function in trailer.c.
    
    Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Oct 1, 2014
  1. @gitster

    sha1-array: add test-sha1-array and basic tests

    René Scharfe committed with gitster
    Helped-by: Jeff King <peff@peff.net>
    Helped-by: Eric Sunshine <sunshine@sunshineco.com>
    Signed-off-by: Rene Scharfe <l.s.r@web.de>
    Acked-by: Jeff King <peff@peff.net>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jul 29, 2014
  1. @tanayabh @gitster

    test-config: add tests for the config_set API

    tanayabh committed with gitster
    Expose the `config_set` C API as a set of simple commands in order to
    facilitate testing. Add tests for the `config_set` API as well as for
    `git_config_get_*()` family for the usual config files.
    
    Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
    Signed-off-by: Tanay Abhra <tanayabh@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jul 16, 2014
  1. @gitster

    Merge branch 'nd/split-index'

    gitster committed
    An experiment to use two files (the base file and incremental
    changes relative to it) to represent the index to reduce I/O cost
    of rewriting a large index when only small part of the working tree
    changes.
    
    * nd/split-index: (32 commits)
      t1700: new tests for split-index mode
      t2104: make sure split index mode is off for the version test
      read-cache: force split index mode with GIT_TEST_SPLIT_INDEX
      read-tree: note about dropping split-index mode or index version
      read-tree: force split-index mode off on --index-output
      rev-parse: add --shared-index-path to get shared index path
      update-index --split-index: do not split if $GIT_DIR is read only
      update-index: new options to enable/disable split index mode
      split-index: strip pathname of on-disk replaced entries
      split-index: do not invalidate cache-tree at read time
      split-index: the reading part
      split-index: the writing part
      read-cache: mark updated entries for split index
      read-cache: save deleted entries in split index
      read-cache: mark new entries for split index
      read-cache: split-index mode
      read-cache: save index SHA-1 after reading
      entry.c: update cache_changed if refresh_cache is set in checkout_entry()
      cache-tree: mark istate->cache_changed on prime_cache_tree()
      cache-tree: mark istate->cache_changed on cache tree update
      ...
Commits on Jul 15, 2014
  1. @sunny256 @gitster

    .gitignore: "git-verify-commit" is a generated file

    sunny256 committed with gitster
    builtin/verify-commit.c was added in commit d07b00b ("verify-commit:
    scriptable commit signature verification", 2014-06-23), update
    .gitignore to ignore the generated file.
    
    Signed-off-by: Øyvind A. Holm <sunny@sunbase.org>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jun 13, 2014
  1. @pclouds @gitster

    t1700: new tests for split-index mode

    pclouds committed with gitster
    Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jun 6, 2014
  1. @gitster

    Merge branch 'tb/unicode-6.3-zero-width'

    gitster committed
    Update the logic to compute the display width needed for utf8
    strings and allow us to more easily maintain the tables used in
    that logic.
    
    We may want to let the users choose if codepoints with ambiguous
    widths are treated as a double or single width in a follow-up patch.
    
    * tb/unicode-6.3-zero-width:
      utf8: make it easier to auto-update git_wcwidth()
      utf8.c: use a table for double_width
Commits on May 12, 2014
  1. @tboegi @gitster

    utf8: make it easier to auto-update git_wcwidth()

    tboegi committed with gitster
    The function git_wcwidth() returns for a given unicode code point the
    width on the display:
    
     -1 for control characters,
      0 for combining or other non-visible code points
      1 for e.g. ASCII
      2 for double-width code points.
    
    This table had been originally been extracted for one Unicode
    version, probably 3.2.
    
    We now use two tables these days, one for zero-width and another for
    double-width.  Make it easier to update these tables to a later
    version of Unicode by factoring out the table from utf8.c into
    unicode_width.h and add the script update_unicode.sh to update the
    table based on the latest Unicode specification files.
    
    Thanks to Peter Krefting <peter@softwolves.pp.se> and Kevin Bracey
    <kevin@bracey.fi> for helping with their Unicode knowledge.
    
    Signed-off-by: Torsten Bögershausen <tboegi@web.de>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Feb 27, 2014
  1. @gitster

    Merge branch 'kb/fast-hashmap'

    gitster committed
    Improvements to our hash table to get it to meet the needs of the
    msysgit fscache project, with some nice performance improvements.
    
    * kb/fast-hashmap:
      name-hash: retire unused index_name_exists()
      hashmap.h: use 'unsigned int' for hash-codes everywhere
      test-hashmap.c: drop unnecessary #includes
      .gitignore: test-hashmap is a generated file
      read-cache.c: fix memory leaks caused by removed cache entries
      builtin/update-index.c: cleanup update_one
      fix 'git update-index --verbose --again' output
      remove old hash.[ch] implementation
      name-hash.c: remove cache entries instead of marking them CE_UNHASHED
      name-hash.c: use new hash map implementation for cache entries
      name-hash.c: remove unreferenced directory entries
      name-hash.c: use new hash map implementation for directories
      diffcore-rename.c: use new hash map implementation
      diffcore-rename.c: simplify finding exact renames
      diffcore-rename.c: move code around to prepare for the next patch
      buitin/describe.c: use new hash map implementation
      add a hashtable implementation that supports O(1) removal
      submodule: don't access the .gitmodules cache entry after removing it
Commits on Feb 24, 2014
  1. @jrn @gitster

    .gitignore: test-hashmap is a generated file

    jrn committed with gitster
    Prevent the "test-hashmap" program from being accidentally tracked
    with "git add" or cluttering "git status" output.
    
    Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Dec 12, 2013
  1. @gitster

    Merge branch 'jk/remove-deprecated'

    gitster committed
    * jk/remove-deprecated:
      stop installing git-tar-tree link
      peek-remote: remove deprecated alias of ls-remote
      lost-found: remove deprecated command
      tar-tree: remove deprecated command
      repo-config: remove deprecated alias for "git config"
Commits on Nov 18, 2013
  1. @jrn @gitster

    Makefile: rebuild perl scripts when perl paths change

    jrn committed with gitster
    Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Nov 12, 2013
  1. @johnkeeping @gitster

    peek-remote: remove deprecated alias of ls-remote

    johnkeeping committed with gitster
    This has been deprecated since commit 87194d2 (Deprecate peek-remote,
    2007-11-24), included in version 1.5.4.
    
    Signed-off-by: John Keeping <john@keeping.me.uk>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  2. @johnkeeping @gitster

    lost-found: remove deprecated command

    johnkeeping committed with gitster
    "git lost-found" has been deprecated since commit fc8b5f0 (Deprecate
    git-lost-found, 2007-11-08), included in version 1.5.4.
    
    Signed-off-by: John Keeping <john@keeping.me.uk>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  3. @johnkeeping @gitster

    tar-tree: remove deprecated command

    johnkeeping committed with gitster
    "git tar-tree" has been a thin wrapper around "git archive" since commit
    fd88d9c (Remove upload-tar and make git-tar-tree a thin wrapper to
    git-archive, 2006-09-24), which also made it print a message indicating
    that git-tar-tree is deprecated.
    
    Signed-off-by: John Keeping <john@keeping.me.uk>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  4. @johnkeeping @gitster

    repo-config: remove deprecated alias for "git config"

    johnkeeping committed with gitster
    The release notes for Git 1.5.4 say that "git repo-config" will be
    removed in the next feature release.  Since Git 2.0 is nearly here,
    remove it.
    
    Signed-off-by: John Keeping <john@keeping.me.uk>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Sep 9, 2013
  1. @gitster

    Merge branch 'jc/url-match'

    gitster committed
    Allow section.<urlpattern>.var configuration variables to be
    treated as a "virtual" section.var given a URL, and use the
    mechanism to enhance http.* configuration variables.
    
    This is a reroll of Kyle J. McKay's work.
    
    * jc/url-match:
      builtin/config.c: compilation fix
      config: "git config --get-urlmatch" parses section.<url>.key
      builtin/config: refactor collect_config()
      config: parse http.<url>.<variable> using urlmatch
      config: add generic callback wrapper to parse section.<url>.key
      config: add helper to normalize and match URLs
      http.c: fix parsing of http.sslCertPasswordProtected variable
Commits on Aug 5, 2013
  1. @mackyle @gitster

    config: parse http.<url>.<variable> using urlmatch

    mackyle committed with gitster
    Use the urlmatch_config_entry() to wrap the underlying
    http_options() two-level variable parser in order to set
    http.<variable> to the value with the most specific URL in the
    configuration.
    
    Signed-off-by: Jeff King <peff@peff.net>
    Signed-off-by: Kyle J. McKay <mackyle@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jul 22, 2013
  1. @gitster

    Merge branch 'es/check-mailmap'

    gitster committed
    A new command to allow scripts to query the mailmap information.
    
    * es/check-mailmap:
      t4203: test check-mailmap command invocation
      builtin: add git-check-mailmap command
Commits on Jul 13, 2013
  1. @sunshineco @gitster

    builtin: add git-check-mailmap command

    sunshineco committed with gitster
    Introduce command check-mailmap, similar to check-attr and check-ignore,
    which allows direct testing of .mailmap configuration.
    
    As plumbing accessible to scripts and other porcelain, check-mailmap
    publishes the stable, well-tested .mailmap functionality employed by
    built-in Git commands.  Consequently, script authors need not
    re-implement .mailmap functionality manually, thus avoiding potential
    quirks and behavioral differences.
    
    Signed-off-by: Eric Sunshine <sunshine@sunshineco.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jul 1, 2013
  1. @gitster

    Merge branch 'jc/topo-author-date-sort'

    gitster committed
    "git log" learned the "--author-date-order" option, with which the
    output is topologically sorted and commits in parallel histories
    are shown intermixed together based on the author timestamp.
    
    * jc/topo-author-date-sort:
      t6003: add --author-date-order test
      topology tests: teach a helper to set author dates as well
      t6003: add --date-order test
      topology tests: teach a helper to take abbreviated timestamps
      t/lib-t6000: style fixes
      log: --author-date-order
      sort-in-topological-order: use prio-queue
      prio-queue: priority queue of pointers to structs
      toposort: rename "lifo" field
Commits on Jun 20, 2013
  1. @gitster

    Merge branch 'rs/discard-index-discard-array'

    gitster committed
    * rs/discard-index-discard-array:
      read-cache: free cache in discard_index
      read-cache: add simple performance test
Commits on Jun 11, 2013
  1. @gitster

    prio-queue: priority queue of pointers to structs

    gitster committed
    Traditionally we used a singly linked list of commits to hold a set
    of in-flight commits while traversing history.  The most typical use
    of the list is to add commits that are newly discovered to it, keep
    the list sorted by commit timestamp, pick up the newest one from the
    list, and keep digging.  The cost of keeping the singly linked list
    sorted is nontrivial, and this typical use pattern better matches a
    priority queue.
    
    Introduce a prio-queue structure, that can be used either as a LIFO
    stack, or a priority queue.  This will be used in the next patch to
    hold in-flight commits during sort-in-topological-order.
    
    Tests and the idea to make it usable for any "void *" pointers to
    "things" are by Jeff King.  Bugs are mine.
    
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jun 10, 2013
  1. @gitster

    read-cache: add simple performance test

    René Scharfe committed with gitster
    Add the helper test-read-cache, which can be used to call read_cache and
    discard_cache in a loop as well as a performance check based on it.
    
    Signed-off-by: René Scharfe <rene.scharfe@lsrfire.ath.cx>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jun 4, 2013
  1. @patthoyts

    Provide a Windows version resource for the git executables.

    patthoyts committed
    Embeds the git version and description into the git executable thus
    implementing the request in issue #5.
    
    Acked-by: Heiko Voigt <hvoigt@hvoigt.net>
    Acked-by: Sebastian Schuberth <sschuberth@gmail.com>
    Acked-by: Johannes Schindelin <johannes.schindelin@gmx.de>
    Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
Commits on Apr 28, 2013
  1. @gitster

    git-remote-testgit: build it to run under $SHELL_PATH

    gitster committed
    Just like all the other shell scripts, replace the shebang line to
    make sure it runs under the shell the user specified.
    
    As this no longer depends on bashisms, t5801 does not have to say
    bash must be available somewhere on the system.
    
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jan 24, 2013
  1. @gitster

    Merge branch 'as/check-ignore'

    gitster committed
    Add a new command "git check-ignore" for debugging .gitignore
    files.
    
    The variable names may want to get cleaned up but that can be done
    in-tree.
    
    * as/check-ignore:
      clean.c, ls-files.c: respect encapsulation of exclude_list_groups
      t0008: avoid brace expansion
      add git-check-ignore sub-command
      setup.c: document get_pathspec()
      add.c: extract new die_if_path_beyond_symlink() for reuse
      add.c: extract check_path_for_gitlink() from treat_gitlinks() for reuse
      pathspec.c: rename newly public functions for clarity
      add.c: move pathspec matchers into new pathspec.c for reuse
      add.c: remove unused argument from validate_pathspec()
      dir.c: improve docs for match_pathspec() and match_pathspec_depth()
      dir.c: provide clear_directory() for reclaiming dir_struct memory
      dir.c: keep track of where patterns came from
      dir.c: use a single struct exclude_list per source of excludes
    
    Conflicts:
    	builtin/ls-files.c
    	dir.c
Something went wrong with that request. Please try again.