1. 22 7月, 2008 6 次提交
  2. 21 7月, 2008 14 次提交
  3. 20 7月, 2008 20 次提交
    • J
      refresh-index: fix bitmask assignment · 3f1b7b60
      Junio C Hamano 提交于
      5fdeacb0 (Teach update-index about --ignore-submodules, 2008-05-14) added a
      new refresh option flag but did not assign a unique bit for it correctly,
      and broke "update-index --ignore-missing".
      
      This fixes it.
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      3f1b7b60
    • J
      git-add --all: documentation · da98053a
      Junio C Hamano 提交于
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      da98053a
    • J
      git-add --all: tests · 340ce9e2
      Junio C Hamano 提交于
      And here is a small test script that makes sure that:
      
       - both modified and new files are included,
       - removed file is noticed, and
       - no ignored file is included.
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      340ce9e2
    • J
      git-add --all: add all files · 3ba1f114
      Junio C Hamano 提交于
      People sometimes find that "git add -u && git add ." are 13 keystrokes too
      many.  This reduces it by nine.
      
      The support of this has been very low priority for me personally, because
      I almost never do "git add ." in a directory with already tracked files,
      and in a new directory, there is no point saying "git add -u".
      
      However, for two types of people (that are very different from me), this
      mode of operation may make sense and there is no reason to leave it
      unsupported.  That is:
      
       (1) If you are extremely well disciplined and keep perfect .gitignore, it
           always is safe to say "git add ."; or
      
       (2) If you are extremely undisciplined and do not even know what files
           you created, and you do not very much care what goes in your history,
           it does not matter if "git add ." included everything.
      
      So there it is, although I suspect I will not use it myself, ever.
      
      It will be too much of a change that is against the expectation of the
      existing users to allow "git commit -a" to include untracked files, and
      it would be inconsistent if we named this new option "-a", so the short
      option is "-A".  We _might_ want to later add "git commit -A" but that is
      a separate topic.
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      3ba1f114
    • J
      builtin-add.c: restructure the code for maintainability · c972ec04
      Junio C Hamano 提交于
      The implementation of "git add" has four major codepaths that are mutually
      exclusive:
      
       - if "--interactive" or "--patch" is given, spawn "git add--interactive"
         and exit without doing anything else.  Otherwise things are handled
         internally in this C code;
      
       - if "--update" is given, update the modified files and exit without
         doing anything else;
      
       - if "--refresh" is given, do refresh and exit without doing anything
         else;
      
       - otherwise, find the paths that match pathspecs and stage their
         contents.
      
      It led to an unholy mess in the code structure; each of the latter three
      codepaths has a separate call to read_cache(), even though they are all
      about "read the current index, update it and write it back", and logically
      they should read the index once _anyway_.
      
      This cleans up the latter three cases by introducing a pair of helper
      variables:
      
       - "add_new_files" is set if we need to scan the working tree for paths
         that match the pathspec.  This variable is false for "--update" and
         "--refresh", because they only work on already tracked files.
      
       - "require_pathspec" is set if the user must give at least one pathspec.
         "--update" does not need it but all the other cases do.
      
      This is in preparation for introducing a new option "--all", that does the
      equivalent of "git add -u && git add ." (aka "addremove").
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      c972ec04
    • J
      Getting closer to 1.6.0-rc0 · 09651dd8
      Junio C Hamano 提交于
      Update the links to "stale" versions of documentation to link to 1.5.6.4
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      09651dd8
    • N
      git am --abort · 3e5057a8
      Nanako Shiraishi 提交于
      After failing to apply patches in the middle of a series, "git am --abort"
      lets you go back to the original commit.
      
      [jc: doc/help update from Olivier, and fixups for "am -3" squashed in]
      Signed-off-by: NNanako Shiraishi <nanako3@lavabit.com>
      Signed-off-by: NOlivier Marin <dkr@freesurf.fr>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      3e5057a8
    • J
      Merge branch 'maint' · 67963990
      Junio C Hamano 提交于
      * maint:
        GIT 1.5.6.4
        builtin-rm: fix index lock file path
        http-fetch: do not SEGV after fetching a bad pack idx file
        rev-list: honor --quiet option
        api-run-command.txt: typofix
      67963990
    • A
      Support gitlinks in fast-import. · 03db4525
      Alexander Gavrilov 提交于
      Currently fast-import/export cannot be used for
      repositories with submodules. This patch extends
      the relevant programs to make them correctly
      process gitlinks.
      
      Links can be represented by two forms of the
      Modify command:
      
      M 160000 SHA1 some/path
      
      which sets the link target explicitly, or
      
      M 160000 :mark some/path
      
      where the mark refers to a commit. The latter
      form can be used by importing tools to build
      all submodules simultaneously in one physical
      repository, and then simply fetch them apart.
      Signed-off-by: NAlexander Gavrilov <angavrilov@gmail.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      03db4525
    • J
      .mailmap update · 4a3fedd5
      Junio C Hamano 提交于
      A few people sent in patches under slightly different spelling recently.
      Hopefully this catches most of them if not all (with help from Dscho).
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      4a3fedd5
    • P
      Documentation/git-merge.txt: Partial rewrite of How Merge Works · c0be8aa0
      Petr Baudis 提交于
      The git-merge documentation's "HOW MERGE WORKS" section is confusingly
      composed and actually omits the most interesting part, the merging of
      the arguments into HEAD itself, surprisingly not actually mentioning
      the fast-forward merge anywhere.
      
      This patch replaces the "[NOTE]" screenful of highly technical details
      by a single sentence summing up the interesting information, and instead
      explains how are the arguments compared with HEAD and the three possible
      inclusion states that are named "Already up-to-date", "Fast-forward"
      and "True merge". It also makes it clear that the rest of the section
      talks only about the true merge situation, and slightly expands the
      talk on solving conflicts.
      
      Junio initiated the removal of the Note screenful altogether and
      offered many stylistical fixes.
      Signed-off-by: NPetr Baudis <pasky@suse.cz>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      c0be8aa0
    • R
      archive: remove unused headers · 8575ea55
      René Scharfe 提交于
      Remove obsolete #includes.
      Signed-off-by: NRene Scharfe <rene.scharfe@lsrfire.ath.cx>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      8575ea55
    • R
      archive: make zip compression level independent from core git · 3a176c6c
      René Scharfe 提交于
      zlib_compression_level is the compression level used for git's object store.
      It's 1 by default, which is the fastest setting.  This variable is also used
      as the default compression level for ZIP archives created by git archive.
      
      For archives, however, zlib's own default of 6 is more appropriate, as it's
      favouring small size over speed -- archive creation is not that performance
      critical most of the time.
      
      This patch makes git archive independent from git's internal compression
      level setting.  It affects invocations of git archive without explicitly
      specified compression level option, only.
      Signed-off-by: NRene Scharfe <rene.scharfe@lsrfire.ath.cx>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      3a176c6c
    • P
      Documentation: How to ignore local changes in tracked files · 6259ac66
      Petr Baudis 提交于
      This patch explains more carefully that `.gitignore` concerns only
      untracked files and refers the reader to
      
      	git update-index --assume-unchanged
      
      in the need of ignoring uncommitted changes in already tracked files.
      The description of this option is lifted to a more "porcelainish"
      level and explains the caveats of this usecase.
      
      Whether feasible or not, I believe adding this functionality to
      the porcelain is out of the scope of this patch. (And I personally
      think that referring to the plumbing in the case of such a special
      usage is fine.)
      
      This is currently probably one of the top FAQs at #git and the
      --assume-unchanged switch is not widely known; gitignore(5) is the first
      place where people are likely to look for it.
      Signed-off-by: NPetr Baudis <pasky@suse.cz>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      6259ac66
    • P
      Documentation/git-submodule.txt: Further clarify the description · c47f1024
      Petr Baudis 提交于
      This patch rewrites the general description yet again, first clarifying
      the high-level concept, mentioning the difference to remotes and using
      the subtree merge strategy, then getting to the details about tree
      entries and .gitmodules file.
      
      The patch also makes few smallar grammar fixups within the rest of the
      description and clarifies how does 'init' relate to 'update --init'.
      
      Cc: Heikki Orsila <shdl@zakalwe.fi>
      Signed-off-by: NPetr Baudis <pasky@suse.cz>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      c47f1024
    • P
      Add ANSI control code emulation for the Windows console · c09df8a7
      Peter Harris 提交于
      This adds only the minimum necessary to keep git pull/merge's diffstat from
      wrapping. Notably absent is support for the K (erase) operation, and support
      for POSIX write.
      Signed-off-by: NPeter Harris <git@peter.is-a-geek.org>
      Signed-off-by: NJohannes Sixt <johannes.sixt@telecom.at>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      c09df8a7
    • J
      builtin-clone: rewrite guess_dir_name() · b8c5db35
      Johannes Sixt 提交于
      The function has to do three small and independent tasks, but all of them
      were crammed into a single loop. This rewrites the function entirely by
      unrolling these tasks.
      
      We also now use is_dir_sep(c) instead of c == '/' to increase portability.
      Signed-off-by: NJohannes Sixt <johannes.sixt@telecom.at>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      b8c5db35
    • E
      Teach lookup_prog not to select directories · fe77b695
      Eric Raible 提交于
      Without this simple fix "git gui" in the git source directory
      finds the git-gui directory instead of the tcl script in /usr/bin.
      Signed-off-by: NEric Raible <raible@gmail.com>
      Signed-off-by: NJohannes Sixt <johannes.sixt@telecom.at>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      fe77b695
    • F
      testsuite for cvs co -c · 42f7a2da
      Fabian Emmes 提交于
      Check that all branches are displayed.
      Signed-off-by: NFabian Emmes <fabian.emmes@rwth-aachen.de>
      Signed-off-by: NLars Noschinski <lars@public.noschinski.de>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      42f7a2da
    • L
      cvsserver: Add cvs co -c support · 89a9167f
      Lars Noschinski 提交于
      Implement cvs checkout's -c option by returning a list of all "modules".
      This is more useful than displaying a perl warning if -c is given.
      Signed-off-by: NLars Noschinski <lars@public.noschinski.de>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      89a9167f