aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Add core.pager config variable.Brian Gernhardt2007-07-04
| | | | | | | | | This adds a configuration variable that performs the same function as, but is overridden by, GIT_PAGER. Signed-off-by: Brian Gernhardt <benji@silverinsanity.com> Acked-by: Johannes E. Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* git-submodule: Fix two instances of the same typoCJ van den Berg2007-07-04
| | | | | | They break the output of git submodule status. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Merge branch 'maint'Junio C Hamano2007-07-03
|\ | | | | | | | | | | | | | | * maint: Document -<n> for git-format-patch glossary: add 'reflog' diff --no-index: fix --name-status with added files Don't smash stack when $GIT_ALTERNATE_OBJECT_DIRECTORIES is too long
| * Document -<n> for git-format-patchMiklos Vajna2007-07-03
| | | | | | | | | | | | | | | | The -<n> option was not mentioned in git-format-patch's manpage till now. Fix this. Signed-off-by: Miklos Vajna <vmiklos@frugalware.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * glossary: add 'reflog'Johannes Schindelin2007-07-03
| | | | | | | | | | Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * diff --no-index: fix --name-status with added filesJohannes Schindelin2007-07-03
| | | | | | | | | | | | | | | | | | Without this patch, an added file would be reported as /dev/null. Noticed by David Kastrup. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Don't smash stack when $GIT_ALTERNATE_OBJECT_DIRECTORIES is too longJim Meyering2007-07-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is no restriction on the length of the name returned by get_object_directory, other than the fact that it must be a stat'able git object directory. That means its name may have length up to PATH_MAX-1 (i.e., often 4095) not counting the trailing NUL. Combine that with the assumption that the concatenation of that name and suffixes like "/info/alternates" and "/pack/---long-name---.idx" will fit in a buffer of length PATH_MAX, and you see the problem. Here's a fix: sha1_file.c (prepare_packed_git_one): Lengthen "path" buffer so we are guaranteed to be able to append "/pack/" without checking. Skip any directory entry that is too long to be appended. (read_info_alternates): Protect against a similar buffer overrun. Before this change, using the following admittedly contrived environment setting would cause many git commands to clobber their stack and segfault on a system with PATH_MAX == 4096: t=$(perl -e '$s=".git/objects";$n=(4096-6-length($s))/2;print "./"x$n . $s') export GIT_ALTERNATE_OBJECT_DIRECTORIES=$t touch g ./git-update-index --add g If you run the above commands, you'll soon notice that many git commands now segfault, so you'll want to do this: unset GIT_ALTERNATE_OBJECT_DIRECTORIES Signed-off-by: Jim Meyering <jim@meyering.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | filter-branch: add a test for the commit removal exampleJohannes Schindelin2007-07-03
| | | | | | | | | | | | | | | | | | | | In the man page, there is an example which describes how to remove single commits (although it keeps the changes which were not reverted in the next non-removed commit). Better make sure that it works as expected. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | fsck --lost-found writes to subdirectories in .git/lost-found/Jonas Fonseca2007-07-03
| | | | | | | | | | Signed-off-by: Jonas Fonseca <fonseca@diku.dk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Add diff-option --ext-diffJohannes Schindelin2007-07-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To prevent funky games with external diff engines, git-log and friends prevent external diff engines from being called. That makes sense in the context of git-format-patch or git-rebase. However, for "git log -p" it is not so nice to get the message that binary files cannot be compared, while "git diff" has no problems with them, if you provided an external diff driver. With this patch, "git log --ext-diff -p" will do what you expect, and the option "--no-ext-diff" can be used to override that setting. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Document git-filter-branchJohannes Schindelin2007-07-03
| | | | | | | | | | | | | | | | | | This moves the documentation in git-filter-branch.sh to its own man page, with a few touch ups (incorporating comments by Frank Lichtenheld). Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | stash: end commit log with a newlineUwe Kleine-König2007-07-03
| | | | | | | | | | | | | | | | | | | | | | | | If I do git cat-file commit $commitid for a commit created by stash, the next prompt starts directly after the shortlog of HEAD. Signed-off-by: Uwe Kleine-König <ukleinek@informatik.uni-freiburg.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Update draft Release Notes for 1.5.3Junio C Hamano2007-07-03
| | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Mark disused commit walkers officially deprecated.v1.5.3-rc0Junio C Hamano2007-07-02
| | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | git-stash: make "save" the default action again.Junio C Hamano2007-07-02
| | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Rewrite "git-frotz" to "git frotz"Junio C Hamano2007-07-02
| | | | | | | | | | | | This uses the remove-dashes target to replace "git-frotz" to "git frotz". Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Start deprecating "git-command" in favor of "git command"Linus Torvalds2007-07-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I realize that a lot of people use the "git-xyzzy" format, and we have various historical reasons for it, but I also think that most people have long since started thinking of the git command as a single command with various subcommands, and we've long had the documentation talk about it that way. Slowly migrating away from the git-xyzzy format would allow us to eventually no longer install hundreds of binaries (even if most of them are symlinks or hardlinks) in users $PATH, and the _original_ reasons for it (implementation issues and bash completion) are really long long gone. Using "git xyzzy" also has some fundamental advantages, like the ability to specify things like paging ("git -p xyzzy") and making the whole notion of aliases act like other git commands (which they already do, but they do *not* have a "git-xyzzy" form!) Anyway, while actually removing the "git-xyzzy" things is not practical right now, we can certainly start slowly to deprecate it internally inside git itself - in the shell scripts we use, and the test vectors. This patch adds a "remove-dashes" makefile target, which does that. It isn't particularly efficient or smart, but it *does* successfully rewrite a lot of our shell scripts to use the "git xyzzy" form for all built-in commands. (For non-builtins, the "git xyzzy" format implies an extra execve(), so this script leaves those alone). So apply this patch, and then run make remove-dashes make test git commit -a to generate a much larger patch that actually starts this transformation. (The only half-way subtle thing about this is that it also fixes up git-filter-branch.sh for the new world order by adding quoting around the use of "git-commit-tree" as an argument. It doesn't need it in that format, but when changed into "git commit-tree" it is no longer a single word, and the quoting maintains the old behaviour). NOTE! This does not yet mean that you can actually stop installing the "git-xyzzy" binaries for the builtins. There are some remaining places that want to use the old form, this just removes the most obvious ones that can easily be done automatically. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Merge branch 'jo/init'Junio C Hamano2007-07-02
|\ \ | | | | | | | | | | | | | | | * jo/init: Quiet the output from git-init when cloning, if requested. Add an option to quiet git-init.
| * | Quiet the output from git-init when cloning, if requested.Jeffrey C. Ollie2007-06-27
| | | | | | | | | | | | | | | | | | | | | | | | Now that git-init has an option to quiet itself, use it if the -q option was specified on the clone command line. Signed-off-by: Jeffrey C. Ollie <jeff@ocjtech.us> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | Add an option to quiet git-init.Jeffrey C. Ollie2007-06-27
| | | | | | | | | | | | | | | | | | | | | | | | git-init lacks an option to suppress non-error and non-warning output - this patch adds one. Signed-off-by: Jeffrey C. Ollie <jeff@ocjtech.us> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | git-fsck: add --lost-found optionJohannes Schindelin2007-07-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With this option, dangling objects are not only reported, but also written to .git/lost-found/commit/ or .git/lost-found/other/. This option implies '--full' and '--no-reflogs'. 'git fsck --lost-found' is meant as a replacement for git-lost-found. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'maint'Junio C Hamano2007-07-02
|\ \ \ | | |/ | |/| | | | | | | * maint: Correctly document the name of the global excludes file configuration
| * | Correctly document the name of the global excludes file configurationMichael Hendricks2007-07-02
| | | | | | | | | | | | | | | Signed-off-by: Michael Hendricks <michael@ndrix.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | format-patch: Add format.subjectprefix config optionAdam Roben2007-07-02
| | | | | | | | | | | | | | | | | | | | | | | | This change lets you use the format.subjectprefix config option to override the default subject prefix. Signed-off-by: Adam Roben <aroben@apple.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Test 'git add' for unmerged entries when core.symlinks=false.Johannes Sixt2007-07-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In 20314271679e169f324c118c69c8d9e0399feec9 git add was fixed if unmerged entries are in the index and core.filemode=false. core.symlinks=false is a similar case, which touches the same code path. Here is a test that makes sure that the symlink property in the index is preserved, too. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | "git-push $URL" without refspecs pushes only matching branchesJunio C Hamano2007-07-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When "git push" is run without any refspec (neither on the command line nor in the config), we used to push "matching refs" in the sense that anything under refs/ hierarchy that exist on both ends were updated. This used to be a sane default for publishing your repository to another back when we did not have refs/remotes/ hierarchy, but it does not make much sense these days. This changes the semantics to push only "matching branches". Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'maint'Junio C Hamano2007-07-02
|\ \ \ | |/ / | | | | | | | | | * maint: Make git-prune submodule aware (and fix a SEGFAULT in the process)
| * | Make git-prune submodule aware (and fix a SEGFAULT in the process)Andy Parkins2007-07-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I ran git-prune on a repository and got this: $ git-prune error: Object 228f8065b930120e35fc0c154c237487ab02d64a is a blob, not a commit Segmentation fault (core dumped) This repository was a strange one in that it was being used to provide its own submodule. That is, the repository was cloned into a subdirectory, an independent branch checked out in that subdirectory, and then it was marked as a submodule. git-prune then failed in the above manner. The problem was that git-prune was not submodule aware in two areas. Linus said: > So what happens is that something traverses a tree object, looks at each > entry, sees that it's not a tree, and tries to look it up as a blob. But > subprojects are commits, not blobs, and then when you look at the object > more closely, you get the above kind of object type confusion. and included a patch to add an S_ISGITLINK() test to reachable.c's process_tree() function. That fixed the first git-prune error, and stopped it from trying to process the gitlink entries in trees as if they were pointers to other trees (and of course failing, because gitlinks _aren't_ trees). That part of this patch is his. The second area is add_cache_refs(). This is called before starting the reachability analysis, and was calling lookup_blob() on every object hash found in the index. However, it is no longer true that every hash in the index is a pointer to a blob, some of them are gitlinks, and are not backed by any object at all, they are commits in another repository. Normally this bug was not causing any problems, but in the case of the self-referencing repository described above, it meant that the gitlink hash was being marked as being of type OBJ_BLOB by add_cache_refs() call to lookup_blob(). Then later, because that hash was also pointed to by a ref, add_one_ref() would treat it as a commit; lookup_commit() would return a NULL because that object was already noted as being an OBJ_BLOB, not an OBJ_COMMIT; and parse_commit_buffer() would SEGFAULT on that NULL pointer. The fix made by this patch is to not blindly call lookup_blob() in reachable.c's add_cache_refs(), and instead skip any index entries that are S_ISGITLINK(). Signed-off-by: Andy Parkins <andyparkins@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'ew/svn'Junio C Hamano2007-07-02
|\ \ \ | | | | | | | | | | | | | | | | * ew/svn: git-svn: allow dcommit to retain local merge information
| * | | git-svn: allow dcommit to retain local merge informationEric Wong2007-06-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | dcommit will still rewrite the HEAD commit and the history of the first parents of each HEAD~1, HEAD~2, HEAD~3 as it always has. However, any merge parents (HEAD^2, HEAD^^2, HEAD~2^2) will now be preserved when the new HEAD and HEAD~[0-9]+ commits are rewritten to SVN with dcommit. Commits written to SVN will still not have any merge information besides anything in the commit message. Thanks to Joakim Tjernlund, Junio C Hamano and Steven Grimm for explanations, feedback, examples and test case. Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'ns/stash'Junio C Hamano2007-07-02
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ns/stash: Documentation: quote {non-attributes} for asciidoc git-stash: don't complain when listing in a repo with no stash git-stash: fix "can't shift that many" with no arguments git-stash: fix "no arguments" case in documentation git-stash: require "save" to be explicit and update documentation Document git-stash Add git-stash script
| * | | | Documentation: quote {non-attributes} for asciidocJeff King2007-07-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Asciidoc treats {foo} as an attribute to be substituted; if 'foo' doesn't exist as an attribute, then the entire line gets dropped. When the literal {foo} is desired, \{foo} is required. The exceptions to this rule are: - inside literal blocks - if the 'foo' contains non-alphanumeric characters (e.g., {foo|bar} is assumed not to be an attribute) Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | git-stash: don't complain when listing in a repo with no stashJeff King2007-07-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, the git-log invocation would complain if a repo had not had any stashes created in it yet: $ git-init $ git-stash fatal: ambiguous argument 'refs/stash': unknown revision or path not in the working tree. Use '--' to separate paths from revisions Instead, we only call git-log if we actually have a refs/stash. We could alternatively create the ref when any stash command is called, but it's better for the 'list' command to not require write access to the repo. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | git-stash: fix "can't shift that many" with no argumentsJeff King2007-07-01
| | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | git-stash: fix "no arguments" case in documentationJeff King2007-07-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 9488e875 changed this from 'save' to 'list', but missed this spot in the documentation. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | git-stash: require "save" to be explicit and update documentationJunio C Hamano2007-07-01
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | Document git-stashしらいしななこ2007-06-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This describes the git-stash command. I borrowed a few paragraphs from Johannes's version, and added a few examples. Signed-off-by: Nanako Shiraishi <nanako3@bluebottle.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | Add git-stash scriptしらいしななこ2007-06-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When my boss has something to show me and I have to update, for some reason I am always in the middle of doing something else, and git pull command refuses to work in such a case. I wrote this little script to save the changes I made, perform the update, and then come back to where I was, but on top of the updated commit. This is how you would use the script: $ git stash $ git pull $ git stash apply [jc: with a few fixlets from the list] Signed-off-by: Nanako Shiraishi <nanako3@bluebottle.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'js/rebase'Junio C Hamano2007-07-02
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * js/rebase: Teach rebase -i about --preserve-merges rebase -i: provide reasonable reflog for the rebased branch rebase -i: several cleanups ignore git-rebase--interactive Teach rebase an interactive mode Move the pick_author code to git-sh-setup
| * | | | | Teach rebase -i about --preserve-mergesJohannes Schindelin2007-06-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The option "-p" (or long "--preserve-merges") makes it possible to rebase side branches including merges, without straightening the history. Example: X \ A---M---B / ---o---O---P---Q When the current HEAD is "B", "git rebase -i -p --onto Q O" will yield X \ ---o---O---P---Q---A'---M'---B' Note that this will - _not_ touch X [*1*], it does - _not_ work without the --interactive flag [*2*], it does - _not_ guess the type of the merge, but blindly uses recursive or whatever strategy you provided with "-s <strategy>" for all merges it has to redo, and it does - _not_ make use of the original merge commit via git-rerere. *1*: only commits which reach a merge base between <upstream> and HEAD are reapplied. The others are kept as-are. *2*: git-rebase without --interactive is inherently patch based (at least at the moment), and therefore merges cannot be preserved. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | rebase -i: provide reasonable reflog for the rebased branchJohannes Schindelin2007-06-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If your rebase succeeded, the HEAD's reflog will still show the whole mess, but "<branchname>@{1}" now shows the state _before_ the rebase, so that you can reset (or compare) the original and the rebased revisions more easily. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | rebase -i: several cleanupsJohannes Schindelin2007-06-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Support "--verbose" in addition to "-v", show short names in the list comment, clean up if there is nothing to do, and add several "test_ticks" in the test script. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | ignore git-rebase--interactiveMatthias Lederhofer2007-06-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Lederhofer <matled@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Teach rebase an interactive modeJohannes Schindelin2007-06-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Don't you just hate the fact sometimes, that git-rebase just applies the patches, without any possibility to edit them, or rearrange them? With "--interactive", git-rebase now lets you edit the list of patches, so that you can reorder, edit and delete patches. Such a list will typically look like this: pick deadbee The oneline of this commit pick fa1afe1 The oneline of the next commit ... By replacing the command "pick" with the command "edit", you can amend that patch and/or its commit message, and by replacing it with "squash" you can tell rebase to fold that patch into the patch before that. It is derived from the script sent to the list in <Pine.LNX.4.63.0702252156190.22628@wbgn013.biozentrum.uni-wuerzburg.de> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Move the pick_author code to git-sh-setupJohannes Schindelin2007-06-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At the moment, only git-commit uses that code, to pick the author name, email and date from a given commit. This code will be reused in git rebase --interactive. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | Merge branch 'jc/diffcore'Junio C Hamano2007-07-02
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jc/diffcore: diffcore-delta.c: Ignore CR in CRLF for text files diffcore-delta.c: update the comment on the algorithm. diffcore_filespec: add is_binary diffcore_count_changes: pass diffcore_filespec
| * | | | | | diffcore-delta.c: Ignore CR in CRLF for text filesJunio C Hamano2007-06-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This ignores CR byte in CRLF sequence in text file when computing similarity of two blobs. Usually this should not matter as nobody sane would be checking in a file with CRLF line endings to the repository (they would use autocrlf so that the repository copy would have LF line endings). Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | | diffcore-delta.c: update the comment on the algorithm.Junio C Hamano2007-06-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The comment at the top of the file described an old algorithm that was neutral to text/binary differences (it hashed sliding window of N-byte sequences and counted overlaps), but long time ago we switched to a new heuristics that are more suitable for line oriented (read: text) files that are much faster. Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | | diffcore_filespec: add is_binaryJunio C Hamano2007-06-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | diffcore-break and diffcore-rename would want to behave slightly differently depending on the binary-ness of the data, so add one bit to the filespec, as the structure is now passed down to diffcore_count_changes() function. Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | | diffcore_count_changes: pass diffcore_filespecJunio C Hamano2007-06-30
| | |/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We may want to use richer information on the data we are dealing with in this function, so instead of passing a buffer address and length, just pass the diffcore_filespec structure. Existing callers always call this function with parameters taken from a filespec anyway, so there is no functionality changes. Signed-off-by: Junio C Hamano <gitster@pobox.com>