summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2009-05-03Merge branch 'mm/maint-add-p-quit' into maintLibravatar Junio C Hamano1-1/+1
* mm/maint-add-p-quit: git add -p: add missing "q" to patch prompt
2009-05-03Merge branch 'lt/pack-object-memuse' into maintLibravatar Junio C Hamano7-43/+56
* lt/pack-object-memuse: show_object(): push path_name() call further down process_{tree,blob}: show objects without buffering
2009-04-29Merge branch 'maint-1.6.1' into maintLibravatar Junio C Hamano2-12/+65
* maint-1.6.1: diff -c -p: do not die on submodules
2009-04-29Merge branch 'maint-1.6.0' into maint-1.6.1Libravatar Junio C Hamano2-12/+65
* maint-1.6.0: diff -c -p: do not die on submodules
2009-04-29diff -c -p: do not die on submodulesLibravatar Junio C Hamano2-12/+65
The combine diff logic knew only about blobs (and their checked-out form in the work tree, either regular files or symlinks), and barfed when fed submodules. This "externalizes" gitlinks in the same way as the normal patch generation codepath does (i.e. "Subproject commit Xxx\n") to fix the issue. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-28Merge branch 'maint-1.6.1' into maintLibravatar Junio C Hamano4-4/+12
* maint-1.6.1: grep: fix segfault when "git grep '('" is given Documentation: fix a grammatical error in api-builtin.txt builtin-merge: fix a typo in an error message
2009-04-28Merge branch 'maint-1.6.0' into maint-1.6.1Libravatar Junio C Hamano4-4/+12
* maint-1.6.0: grep: fix segfault when "git grep '('" is given Documentation: fix a grammatical error in api-builtin.txt builtin-merge: fix a typo in an error message
2009-04-27grep: fix segfault when "git grep '('" is givenLibravatar Linus Torvalds2-2/+10
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-27Documentation: fix a grammatical error in api-builtin.txtLibravatar Allan Caffee1-1/+1
Signed-off-by: Allan Caffee <allan.caffee@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-27builtin-merge: fix a typo in an error messageLibravatar Allan Caffee1-1/+1
Signed-off-by: Allan Caffee <allan.caffee@gmail.com> Acked-by: Miklos Vajna <vmiklos@frugalware.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-24Merge branch 'maint-1.6.1' into maintLibravatar Junio C Hamano1-1/+1
* maint-1.6.1: test-genrandom: Add newline to usage string
2009-04-24Merge branch 'maint-1.6.0' into maint-1.6.1Libravatar Junio C Hamano1-1/+1
* maint-1.6.0: test-genrandom: Add newline to usage string
2009-04-23test-genrandom: Add newline to usage stringLibravatar Stephen Boyd1-1/+1
A minor fix to place the terminal input on a new line if test-genrandom is run with no arguments. Signed-off-by: Stephen Boyd <bebarino@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-20gitcvs-migration: Link to git-cvsimport documentationLibravatar Frank Lichtenheld1-1/+1
Signed-off-by: Frank Lichtenheld <flichtenheld@astaro.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-20Fix off-by-one in read_tree_recursiveLibravatar Johannes Schindelin1-0/+1
Found by valgrind. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-20git add -p: add missing "q" to patch promptLibravatar Wincent Colaiuta1-1/+1
Commit cbd3a01 added a new "q" subcommand to the "git add -p" command loop, but forgot to add it to the prompt. Signed-off-by: Wincent Colaiuta <win@wincent.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19GIT 1.6.2.4Libravatar Junio C Hamano2-2/+10
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19Makefile: remove {fetch,send}-pack from PROGRAMS as they are builtinsLibravatar Nguyễn Thái Ngọc Duy1-2/+0
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19Merge branch 'ef/maint-fast-export' into maintLibravatar Junio C Hamano2-2/+26
* ef/maint-fast-export: builtin-fast-export.c: handle nested tags builtin-fast-export.c: fix crash on tagged trees builtin-fast-export.c: turn error into warning test-suite: adding a test for fast-export with tag variants
2009-04-19Merge branch 'mm/maint-add-p-quit' into maintLibravatar Junio C Hamano2-39/+38
* mm/maint-add-p-quit: Update git-add.txt according to the new possibilities of 'git add -p'. add-interactive: refactor mode hunk handling git add -p: new "quit" command at the prompt.
2009-04-19Merge branch 'lt/maint-reflog-expire' into maintLibravatar Junio C Hamano1-6/+70
* lt/maint-reflog-expire: Speed up reflog pruning of unreachable commits Clean up reflog unreachability pruning decision
2009-04-19Merge branch 'jc/maint-shared-literally' into maintLibravatar Junio C Hamano3-11/+23
* jc/maint-shared-literally: Update docs on behaviour of 'core.sharedRepository' and 'git init --shared' t1301-shared-repo: fix forced modes test
2009-04-19Update git-add.txt according to the new possibilities of 'git add -p'.Libravatar Matthieu Moy1-1/+3
The text is merely cut-and-pasted from git-add--interactive.perl. The cut-and-paste also fixes a typo. Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19add-interactive: refactor mode hunk handlingLibravatar Jeff King1-43/+21
The original implementation considered the mode separately from the rest of the hunks, asking about it outside the main hunk-selection loop. This patch instead places a mode change as the first hunk in the loop. This has two advantages: 1. less duplicated code (since we use the main selection loop). This also cleans up an inconsistency, which is that the main selection loop separates options with a comma, whereas the mode prompt used slashes. 2. users can now skip the mode change and come back to it, search for it (via "/mode"), etc, as they can with other hunks. To facilitate this, each hunk is now marked with a "type". Mode hunks are not considered for splitting (which would make no sense, and also confuses the split_hunk function), nor are they editable. In theory, one could edit the mode lines and change to a new mode. In practice, there are only two modes that git cares about (0644 and 0755), so either you want to move from one to the other or not (and you can do that by staging or not staging). Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19git add -p: new "quit" command at the prompt.Libravatar Matthieu Moy2-1/+20
There's already 'd' to stop staging hunks in a file, but no explicit command to stop the interactive staging (for the current files and the remaining ones). Of course you can do 'd' and then ^C, but it would be more intuitive to allow 'quit' action. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19Speed up reflog pruning of unreachable commitsLibravatar Junio Hamano1-0/+44
Instead of doing the (potentially very expensive) "in_merge_base()" check for each commit that might be pruned if it is unreachable, do a preparatory reachability graph of the commit space, so that the common case of being reachable can be tested directly. [ Cleaned up a bit and tweaked to actually work. - Linus ] Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19Clean up reflog unreachability pruning decisionLibravatar Linus Torvalds1-6/+26
This clarifies the pruning rules for unreachable commits by having a separate helpder function for the unreachability decision. It's preparation for actual bigger changes to come to speed up the decision when the reachability calculations become a bottleneck. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19builtin-fast-export.c: handle nested tagsLibravatar Erik Faye-Lund2-3/+6
When tags that points to tags are passed to fast-export, an error is given, saying "Tag [TAGNAME] points nowhere?". This fix calls parse_object() on the object before referencing it's tag, to ensure the tag-info is fully initialized. In addition, it inserts a comment to point out where nested tags are handled. This is consistent with the comment for signed tags. Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19builtin-fast-export.c: fix crash on tagged treesLibravatar Erik Faye-Lund2-3/+6
If a tag object points to a tree (or another unhandled type), the commit- pointer is left uninitialized and later dereferenced. This patch adds a default case to the switch that issues a warning and skips the object. Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19builtin-fast-export.c: turn error into warningLibravatar Erik Faye-Lund1-2/+4
fast-import doesn't have a syntax to support tree-objects (and some other object-types), so fast-export shouldn't handle them. However, aborting the operation is a bit drastic. This patch turns the error into a warning instead. Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-19test-suite: adding a test for fast-export with tag variantsLibravatar Erik Faye-Lund1-0/+16
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-18Describe fixes since 1.6.2.3Libravatar Junio C Hamano2-1/+32
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-18Merge branch 'maint-1.6.1' into maintLibravatar Junio C Hamano0-0/+0
* maint-1.6.1:
2009-04-18Merge branch 'maint-1.6.0' into maint-1.6.1Libravatar Junio C Hamano3-9/+20
* maint-1.6.0: doc/git-daemon: add missing arguments to options init: Do not segfault on big GIT_TEMPLATE_DIR environment variable
2009-04-18Merge branch 'bs/maint-1.6.0-tree-walk-prefix' into maintLibravatar Junio C Hamano4-5/+29
* bs/maint-1.6.0-tree-walk-prefix: match_tree_entry(): a pathspec only matches at directory boundaries tree_entry_interesting: a pathspec only matches at directory boundary
2009-04-18Merge branch 'js/maint-submodule-checkout' into maintLibravatar Junio C Hamano2-3/+42
* js/maint-submodule-checkout: Fix 'git checkout <submodule>' to update the index
2009-04-18Merge branch 'cb/maint-merge-recursive-submodule-fix' into maintLibravatar Junio C Hamano2-12/+78
* cb/maint-merge-recursive-submodule-fix: simplify output of conflicting merge update cache for conflicting submodule entries add tests for merging with submodules
2009-04-18doc/git-daemon: add missing arguments to max-connections optionLibravatar Markus Heidelberg1-1/+1
Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-18Merge branch 'maint-1.6.0' into maintLibravatar Junio C Hamano3-9/+20
* maint-1.6.0: doc/git-daemon: add missing arguments to options init: Do not segfault on big GIT_TEMPLATE_DIR environment variable
2009-04-18doc/git-daemon: add missing arguments to optionsLibravatar Markus Heidelberg1-8/+8
Also fix some spellings and typos. Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-18init: Do not segfault on big GIT_TEMPLATE_DIR environment variableLibravatar Frank Lichtenheld2-1/+12
Signed-off-by: Frank Lichtenheld <flichtenheld@astaro.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-18imap-send: use correct configuration variable in documentationLibravatar Paul Bolle1-1/+1
It's imap.pass (not imap.password). Signed-off-by: Paul Bolle <pebolle@tiscali.nl> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-18Update docs on behaviour of 'core.sharedRepository' and 'git init --shared'Libravatar Johan Herland2-7/+15
This documentation update is needed to reflect the recent changes where "core.sharedRepository = 0mode" was changed to set, not loosen, the repository permissions. Signed-off-by: Johan Herland <johan@herland.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-17doc/gitattributes: clarify location of config textLibravatar Jeff King1-3/+6
The gitattributes documentation has a section on the "diff" attribute, with subsections for each of the things you might want to configure in your diff config section (external diff, hunk headers, etc). The first such subsection specifically notes that the definition of the diff driver should go into $GIT_DIR/config, but subsequent sections do not. This location is implied if you are reading the documentation sequentially, but it is not uncommon for a new user to jump to (or be referred to) a specific section. For a new user who does not know git well enough to recognize the config syntax, it is not clear that those directives don't also go into the gitattributes file. This patch just mentions the config file in each subsection, similar to the way it is mentioned in the first. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-17Merge branch 'maint-1.6.1' into maintLibravatar Junio C Hamano2-2/+9
* maint-1.6.1: Fix buffer overflow in config parser
2009-04-17Merge branch 'maint-1.6.0' into maint-1.6.1Libravatar Junio C Hamano2-2/+9
* maint-1.6.0: Fix buffer overflow in config parser
2009-04-17Fix buffer overflow in config parserLibravatar Thomas Jarosch2-2/+9
When interpreting a config value, the config parser reads in 1+ space character(s) and puts -one- space character in the buffer as soon as the first non-space character is encountered (if not inside quotes). Unfortunately the buffer size check lacks the extra space character which gets inserted at the next non-space character, resulting in a crash with a specially crafted config entry. The unit test now uses Java to compile a platform independent .NET framework to output the test string in C# :o) Read: Thanks to Johannes Sixt for the correct printf call which replaces the perl invocation. Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-16git-apply: fix option descriptionLibravatar Ulrich Windl1-1/+1
Do not use non ASCII single quote. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-12show_object(): push path_name() call further downLibravatar Linus Torvalds7-14/+20
In particular, pushing the "path_name()" call _into_ the show() function would seem to allow - more clarity into who "owns" the name (ie now when we free the name in the show_object callback, it's because we generated it ourselves by calling path_name()) - not calling path_name() at all, either because we don't care about the name in the first place, or because we are actually happy walking the linked list of "struct name_path *" and the last component. Now, I didn't do that latter optimization, because it would require some more coding, but especially looking at "builtin-pack-objects.c", we really don't even want the whole pathname, we really would be better off with the list of path components. Why? We use that name for two things: - add_preferred_base_object(), which actually _wants_ to traverse the path, and now does it by looking for '/' characters! - for 'name_hash()', which only cares about the last 16 characters of a name, so again, generating the full name seems to be just unnecessary work. Anyway, so I didn't look any closer at those things, but it did convince me that the "show_object()" calling convention was crazy, and we're actually better off doing _less_ in list-objects.c, and giving people access to the internal data structures so that they can decide whether they want to generate a path-name or not. This patch does that, and then for people who did use the name (even if they might do something more clever in the future), it just does the straightforward "name = path_name(path, component); .. free(name);" thing. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-04-12process_{tree,blob}: show objects without bufferingLibravatar Linus Torvalds7-41/+48
Here's a less trivial thing, and slightly more dubious one. I was looking at that "struct object_array objects", and wondering why we do that. I have honestly totally forgotten. Why not just call the "show()" function as we encounter the objects? Rather than add the objects to the object_array, and then at the very end going through the array and doing a 'show' on all, just do things more incrementally. Now, there are possible downsides to this: - the "buffer using object_array" _can_ in theory result in at least better I-cache usage (two tight loops rather than one more spread out one). I don't think this is a real issue, but in theory.. - this _does_ change the order of the objects printed. Instead of doing a "process_tree(revs, commit->tree, &objects, NULL, "");" in the loop over the commits (which puts all the root trees _first_ in the object list, this patch just adds them to the list of pending objects, and then we'll traverse them in that order (and thus show each root tree object together with the objects we discover under it) I _think_ the new ordering actually makes more sense, but the object ordering is actually a subtle thing when it comes to packing efficiency, so any change in order is going to have implications for packing. Good or bad, I dunno. - There may be some reason why we did it that odd way with the object array, that I have simply forgotten. Anyway, now that we don't buffer up the objects before showing them that may actually result in lower memory usage during that whole traverse_commit_list() phase. This is seriously not very deeply tested. It makes sense to me, it seems to pass all the tests, it looks ok, but... Does anybody remember why we did that "object_array" thing? It used to be an "object_list" a long long time ago, but got changed into the array due to better memory usage patterns (those linked lists of obejcts are horrible from a memory allocation standpoint). But I wonder why we didn't do this back then. Maybe there's a reason for it. Or maybe there _used_ to be a reason, and no longer is. Signed-off-by: Junio C Hamano <gitster@pobox.com>