summaryrefslogtreecommitdiff
path: root/Makefile
AgeCommit message (Collapse)AuthorFilesLines
2006-05-05Merge branch 'jc/bindiff' into nextLibravatar Junio C Hamano1-5/+1
* jc/bindiff: binary diff: further updates. binary patch. pack-object: squelch eye-candy on non-tty core.prefersymlinkrefs: use symlinks for .git/HEAD repo-config: trim white-space before comment Fix for config file section parsing. Clarify git-cherry documentation. Update git-unpack-objects documentation. Fix up docs where "--" isn't displayed correctly. Several trivial documentation touch ups. git-svn 1.0.0 git-svn: documentation updates delta: stricter constness Makefile: do not link rev-list any specially. builtin-push: --all and --tags _are_ explicit refspecs
2006-05-05binary patch.Libravatar Junio C Hamano1-1/+1
This adds "binary patch" to the diff output and teaches apply what to do with them. On the diff generation side, traditionally, we said "Binary files differ\n" without giving anything other than the preimage and postimage object name on the index line. This was good enough for applying a patch generated from your own repository (very useful while rebasing), because the postimage would be available in such a case. However, this was not useful when the recipient of such a patch via e-mail were to apply it, even if the preimage was available. This patch allows the diff to generate "binary" patch when operating under --full-index option. The binary patch follows the usual extended git diff headers, and looks like this: "GIT binary patch\n" <length byte><data>"\n" ... "\n" Each line is prefixed with a "length-byte", whose value is upper or lowercase alphabet that encodes number of bytes that the data on the line decodes to (1..52 -- 'A' means 1, 'B' means 2, ..., 'Z' means 26, 'a' means 27, ...). <data> is 1 or more groups of 5-byte sequence, each of which encodes up to 4 bytes in base85 encoding. Because 52 / 4 * 5 = 65 and we have the length byte, an output line is capped to 66 characters. The payload is the same diff-delta as we use in the packfiles. On the consumption side, git-apply now can decode and apply the binary patch when --allow-binary-replacement is given, the diff was generated with --full-index, and the receiving repository has the preimage blob, which is the same condition as it always required when accepting an "Binary files differ\n" patch. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-04Makefile: do not link rev-list any specially.Libravatar Junio C Hamano1-4/+0
We used to depend on bignum from openssl for rev-list to compute merge-order, but there is no reason to use different build recipe from other programs anymore. Just build it with git-%$X rule like everybody else. Noticed by Alexey Dobriyan. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-04Merge branch 'js/fetchconfig' into nextLibravatar Junio C Hamano1-2/+2
* js/fetchconfig: Add a conversion tool to migrate remote information into the config fetch, pull: ask config for remote information Add a few more words to the glossary. Added definitions for a few words: Alphabetize the glossary. sha1_to_hex() usage cleanup
2006-05-04Merge branch 'jc/logs'Libravatar Junio C Hamano1-6/+3
* jc/logs: builtin-log/whatchanged/show: make them official.
2006-05-03Merge branch 'jc/symref'Libravatar Junio C Hamano1-2/+6
* jc/symref: core.prefersymlinkrefs: use symlinks for .git/HEAD
2006-05-03Merge branch 'jc/diff'Libravatar Junio C Hamano1-3/+3
* jc/diff: builtin-diff: call it "git-diff", really. builtin-diff.c: die() formatting type fix. built-in diff: assorted updates. built-in diff.
2006-05-03Merge branch 'jc/count'Libravatar Junio C Hamano1-3/+3
* jc/count: builtin-count-objects: open packs when running -v builtin-count-objects: make it official. built-in count-objects.
2006-05-02Merge branch 'jc/symref' into nextLibravatar Junio C Hamano1-2/+6
* jc/symref: core.prefersymlinkrefs: use symlinks for .git/HEAD
2006-05-02core.prefersymlinkrefs: use symlinks for .git/HEADLibravatar Junio C Hamano1-2/+6
When inspecting a project whose build infrastructure used to assume that .git/HEAD is a symlink ref, core.prefersymlinkrefs in the config file of such a project would help to bisect its history. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-01Merge branch 'lt/push' into nextLibravatar Junio C Hamano1-2/+2
* lt/push: builtin-push: make it official.
2006-05-01builtin-push: make it official.Libravatar Junio C Hamano1-2/+3
Remove the shell script version, and hardlink the git binary to it. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-01Merge branch 'jc/count' into nextLibravatar Junio C Hamano1-2/+2
* jc/count: builtin-count-objects: make it official.
2006-05-01Merge branch 'jc/logs' into nextLibravatar Junio C Hamano1-6/+3
* jc/logs: builtin-log/whatchanged/show: make them official.
2006-05-01builtin-log/whatchanged/show: make them official.Libravatar Junio C Hamano1-6/+3
Remove the shell script version, and hardlink the git binary to them. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-01Merge branch 'jc/diff' into nextLibravatar Junio C Hamano1-2/+3
* jc/diff: builtin-diff: call it "git-diff", really.
2006-05-01builtin-diff: call it "git-diff", really.Libravatar Junio C Hamano1-2/+3
Call it "git diff" not "git diffn", remove the shell script version, and hardlink the git binary to it. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-01builtin-count-objects: make it official.Libravatar Junio C Hamano1-2/+3
Remove the shell-script version, make the hardlink from the git binary, and update the documentation to describe a new option. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-01Merge branch 'jc/grep' into nextLibravatar Junio C Hamano1-1/+1
* jc/grep: built-in "git grep"
2006-05-01built-in "git grep"Libravatar Junio C Hamano1-1/+1
This attempts to set up built-in "git grep" to further reduce our dependence on the shell, while at the same time optionally allowing to run grep against object database. You could do funky things like these: git grep --cached -e pattern ;# grep from index git grep -e pattern master ;# or in a rev git grep -e pattern master next ;# or in multiple revs git grep -e pattern pu^@ ;# even like this with an ;# extension from another topic ;-) git grep -e pattern master..next ;# or even from rev ranges git grep -e pattern master~20:Documentation ;# or an arbitrary tree git grep -e pattern next:git-commit.sh ;# or an arbitrary blob Right now, it does not understand and/or obey many options grep should accept, and the pattern must be given with -e option due to the way the parameter parser is structured, both of which obviously need to be fixed for usability. But this is going in the right direction. The shell script version is one of the worst Portability offender in the git barebone Porcelainish; it uses xargs -0 to pass paths around and shell arrays to sift flags and parameters. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-30Merge branch 'lt/push' into nextLibravatar Junio C Hamano1-1/+2
* lt/push: git builtin "push" git-format-patch: Use rfc2822 compliant date.
2006-04-30git builtin "push"Libravatar Linus Torvalds1-1/+1
This adds a builtin "push" command, which is largely just a C'ification of the "git-push.sh" script. Now, the reason I did it as a built-in is partly because it's yet another step on relying less on shell, but it's actually mostly because I've wanted to be able to push to _multiple_ repositories, and the most obvious and simplest interface for that would seem be to just have a "remotes" file that has multiple URL entries. (For "pull", having multiple entries should either just select the first one, or you could fall back on the others on failure - your choice). And quite frankly, it just became too damn messy to do that in shell. Besides, we actually have a fair amount of infrastructure in C, so it just wasn't that hard to do. Of course, this is almost totally untested. It probably doesn't work for anything but the one trial I threw at it. "Simple" doesn't necessarily mean "obviously correct". Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-29Merge branch 'jc/diff' into nextLibravatar Junio C Hamano1-1/+1
* jc/diff: built-in diff: assorted updates. built-in diff.
2006-04-28built-in diff.Libravatar Junio C Hamano1-1/+1
This starts to replace the shell script version of "git diff". Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-28Merge branch 'np/delta' into nextLibravatar Junio C Hamano1-1/+1
* np/delta: replace adler32 with Rabin's polynomial in diff-delta
2006-04-28replace adler32 with Rabin's polynomial in diff-deltaLibravatar Nicolas Pitre1-1/+1
This brings another small repacking speedup for sensibly the same pack size. On the Linux kernel repo, git-repack -a -f is 3.7% faster for a 0.4% larger pack. Credits to Geert Bosch who brought the Rabin's polynomial idea to my attention. This also eliminate the issue of adler32() reading past the data buffer, as noticed by Johannes Schindelin. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-27Merge branch 'jc/count' into nextLibravatar Junio C Hamano1-1/+1
* jc/count: built-in count-objects. pack-objects: update size heuristucs. verify-pack: check integrity in a saner order.
2006-04-27built-in count-objects.Libravatar Junio C Hamano1-1/+1
Also it learned to do -v (verbose) to report: - number of loose objects - disk occupied by loose objects - number of objects in local packs - number of loose objects that are also in pack - unrecognised garbage in .git/objects/??/. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-27Retire rabinpoly fingerprinting codeLibravatar Junio C Hamano1-4/+0
For now let's retire this and reintroduce it as part of the updated pack-objects series from Geert when it is ready. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-26Merge branch 'jc/cache-tree' into nextLibravatar Junio C Hamano1-1/+1
* jc/cache-tree: commit-tree: allow generic object name for the tree as well. Makefile: remove and create xdiff library from scratch. t0000-basic: Add ls-tree recursive test back.
2006-04-26Merge branch 'master' into jc/cache-treeLibravatar Junio C Hamano1-3/+3
* master: commit-tree: allow generic object name for the tree as well. Makefile: remove and create xdiff library from scratch. t0000-basic: Add ls-tree recursive test back. Libified diff-index: backward compatibility fix. Libify diff-index. Libify diff-files. Makefile: remove and create libgit.a from scratch. Document the configuration file Document git-var -l listing also configuration variables rev-parse: better error message for ambiguous arguments make update-index --chmod work with multiple files and --stdin socksetup: don't return on set_reuse_addr() error Fix "git show --stat" git-update-index --unresolve Add git-unresolve <paths>... Add colordiff for git to contrib/colordiff. gitk: Let git-rev-list do the argument list parsing
2006-04-26Makefile: remove and create xdiff library from scratch.Libravatar Junio C Hamano1-1/+1
... in the same spirit as 71459c193d04870076efa0a387c317390b53e3e2. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-25Merge branch 'jc/diffstat' into nextLibravatar Junio C Hamano1-1/+1
* jc/diffstat: diff --stat: show complete rewrites consistently. Makefile: remove and create libgit.a from scratch.
2006-04-25Merge branch 'jc/diff'Libravatar Junio C Hamano1-1/+1
* jc/diff: Libified diff-index: backward compatibility fix. Libify diff-index. Libify diff-files.
2006-04-25Makefile: remove and create libgit.a from scratch.Libravatar Junio C Hamano1-1/+1
Foolishly I renamed diff.o around which caused an old diff.o taken out of libgit.a and got linked into resulting binary and exhibited mysterious breakage for many people. This borrows from the kernel Makefile (scripts/Makefile.build) to first remove the target and then recreate. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-24Merge branch 'jc/cache-tree' into nextLibravatar Junio C Hamano1-0/+3
* jc/cache-tree: index: make the index file format extensible. cache-tree: protect against "git prune". Add test-dump-cache-tree
2006-04-24Merge part of 'jc/cache-tree'Libravatar Junio C Hamano1-1/+1
2006-04-24Add test-dump-cache-treeLibravatar Junio C Hamano1-0/+3
This was useful in diagnosing the corrupt index.aux format problem. But do not bother building or installing it by default. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-23Add cache-tree.Libravatar Junio C Hamano1-1/+1
The cache_tree data structure is to cache tree object names that would result from the current index file. The idea is to have an optional file to record each tree object name that corresponds to a directory path in the cache when we run write_cache(), and read it back when we run read_cache(). During various index manupulations, we selectively invalidate the parts so that the next write-tree can bypass regenerating tree objects for unchanged parts of the directory hierarchy. We could perhaps make the cache-tree data an optional part of the index file, but that would involve the index format updates, so unless we need it for performance reasons, the current plan is to use a separate file, $GIT_DIR/index.aux to store this information and link it with the index file with the checksum that is already used for index file integrity check. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-22Merge branch 'jc/diff' into nextLibravatar Junio C Hamano1-1/+1
* jc/diff: Libify diff-index. Libify diff-files.
2006-04-22Libify diff-files.Libravatar Junio C Hamano1-1/+1
This is the first installment to libify diff brothers. The updated diff-files uses revision.c::setup_revisions() infrastructure to parse its command line arguments, which means the pathname arguments are checked more strictly than before. The tests are adjusted to separate possibly missing paths from the rest of arguments with double-dashes, to show the kosher way. As Linus pointed out, renaming diff.c to diff-lib.c was simply stupid, so I am renaming it back. The new diff-lib.c is to contain pieces extracted from diff brothers. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-21Merge branch 'jc/color' into nextLibravatar Junio C Hamano1-0/+2
* jc/color: Add colordiff for git to contrib/colordiff. Makefile: dependency for builtin-help.o
2006-04-21Makefile: dependency for builtin-help.oLibravatar Junio C Hamano1-0/+2
builtin-help.c wants to include common-cmds.h which is a generated file. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-21Merge branch 'jc/fmt-patch' into nextLibravatar Junio C Hamano1-3/+6
* jc/fmt-patch: Split up builtin commands into separate files from git.c git-log produces no output
2006-04-21Split up builtin commands into separate files from git.cLibravatar Linus Torvalds1-3/+6
Right now it split it into "builtin-log.c" for log-related commands ("log", "show" and "whatchanged"), and "builtin-help.c" for the informational commands (usage printing and "help" and "version"). This just makes things easier to read, I find. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-19Merge branch 'jc/unresolve' into nextLibravatar Junio C Hamano1-2/+1
* jc/unresolve: git-update-index --unresolve
2006-04-19git-update-index --unresolveLibravatar Junio C Hamano1-2/+1
Retire git-unresolve and make it into "git-update-index --unresolve". It processes all paths that follow. During a merge, you would mark a path that is dealt with with: $ git update-index hello and you would "undo" it with: $ git update-index --unresolve hello Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-19Merge branch 'jc/unresolve' into nextLibravatar Junio C Hamano1-2/+3
* jc/unresolve: Add git-unresolve <paths>... get_tree_entry(): make it available from tree-walk sha1_name.c: no need to include diff.h; tree-walk.h will do. sha1_name.c: prepare to make get_tree_entry() reusable from others. pre-commit hook: complain about conflict markers. git-merge: a bit more readable user guidance. diff: move diff.c to diff-lib.c to make room. git log: don't do merge diffs by default Allow "git repack" users to specify repacking window/depth
2006-04-19Add git-unresolve <paths>...Libravatar Junio C Hamano1-1/+2
This is an attempt to address the issue raised on #git channel recently by Carl Worth. After a conflicted automerge, "git diff" shows a combined diff to give you how the tentative automerge result differs from what came from each branch. During a complex merge, it is tempting to be able to resolve a few paths at a time, mark them "I've dealt with them" with git-update-index to unclutter the next "git diff" output, and keep going. However, when the final result does not compile or otherwise found to be a mismerge, the workflow to fix the mismerged paths suddenly changes to "git diff HEAD -- path" (to get a diff from our HEAD before merging) and "git diff MERGE_HEAD -- path" (to get a diff from theirs), and it cannot show the combined anymore. With git-unresolve <paths>..., the versions from our branch and their branch for specified blobs are placed in stage #2 and stage #3, without touching the working tree files. This gives you the combined diff back for easier review, along with "diff --ours" and "diff --theirs". One thing it does not do is to place the base in stage #1; this means "diff --base" would behave differently between the run immediately after a conflicted three-way merge, and the run after an update-index by mistake followed by a git-unresolve. We could theoretically run merge-base between HEAD and MERGE_HEAD to find which tree to place in stage #1, but reviewing "diff --base" is not that useful so.... Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-19diff: move diff.c to diff-lib.c to make room.Libravatar Junio C Hamano1-1/+1
Now I am not doing any real "git-diff in C" yet, but this would help before doing so. Signed-off-by: Junio C Hamano <junkio@cox.net>