summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2006-07-13builtin-prune.c: forgot TYPE => OBJ changes.Libravatar Junio C Hamano1-3/+3
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-12Remove TYPE_* constant macros and use object_type enums consistently.Libravatar Linus Torvalds22-92/+87
This updates the type-enumeration constants introduced to reduce the memory footprint of "struct object" to match the type bits already used in the packfile format, by removing the former (i.e. TYPE_* constant macros) and using the latter (i.e. enum object_type) throughout the code for consistency. Eventually we can stop passing around the "type strings" entirely, and this will help - no confusion about two different integer enumeration. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-12Merge branch 'ml/trace'Libravatar Junio C Hamano6-0/+70
* ml/trace: test-lib: unset GIT_TRACE GIT_TRACE: fix a mixed declarations and code warning GIT_TRACE: show which built-in/external commands are executed
2006-07-12test-lib: unset GIT_TRACELibravatar Junio C Hamano1-0/+1
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-12git-repack: avoid redirecting stderr into git-pack-objectsLibravatar Junio C Hamano1-1/+3
We are trying to catch error condition of git-rev-list and cause the downstream pack-objects to barf, but if you run rev-list with anything that mucks with its stderr (such as GIT_TRACE), any stderr output would cause the pipeline to fail. [jc: originally from Matthias Lederhofer, with a reworded error message.] Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-12Fix grammatical error in git-revertLibravatar Junio C Hamano1-1/+1
We always talk about "commit xyz". We never talk about "xyz commit", except when we end up talking about a commit as a branch head (notably, I would say "the HEAD commit", or possibly "the top-of-master commit", but here $commit is a SHA1 name, not anything else). Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-12Merge branch 'js/merge-base'Libravatar Junio C Hamano2-190/+135
* js/merge-base: Additional merge-base tests (revised) merge-base: update the clean-up postprocessing
2006-07-12Merge branch 'lt/prune'Libravatar Junio C Hamano5-48/+266
* lt/prune: builtin "git prune"
2006-07-12Merge branch 'lt/merge-tree'Libravatar Junio C Hamano5-16/+378
* lt/merge-tree: Improved three-way blob merging code Prepare "git-merge-tree" for future work xdiff: generate "anti-diffs" aka what is common to two files
2006-07-12fmt-merge-msg fixLibravatar Junio C Hamano1-6/+10
The new C version mistranslated the original Perl version in the case to pull from the HEAD. This made it to say nonsense like this: Merge commit ...url... of HEAD * HEAD: ... Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-12gitweb: Make command invocations go through the git wrapperLibravatar Alp Toker1-33/+29
This patch makes invocations of core git commands go through the 'git' binary itself, which improves readability and might help system administrators lock down their CGI environment for security. Signed-off-by: Alp Toker <alp@atoker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-11gitweb: Include a site name in page titlesLibravatar Alp Toker1-2/+6
This helps users tell one 'git' bookmark apart from the other in their browser and improves the indexing of gitweb sites in Web search engines. The title defaults to the SERVER_NAME environment variable, often given by the webserver. Signed-off-by: Alp Toker <alp@atoker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-11gitweb: Send XHTML as 'application/xhtml+xml' where possibleLibravatar Alp Toker1-2/+12
"The 'text/html' media type [RFC2854] is primarily for HTML, not for XHTML. In general, this media type is NOT suitable for XHTML." This patch makes gitweb use content negotiation to conservatively send pages as Content-Type 'application/xhtml+xml' when the user agent explicitly claims to support it. It falls back to 'text/html' even if the user agent appears to implicitly support 'application/xhtml+xml' due to a '*/*' glob, working around an insidious bug in Internet Explorer where sending the correct media type prevents the page from being displayed. Signed-off-by: Alp Toker <alp@atoker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-11git-fetch: fix a bashism (==)Libravatar Eric Wong1-1/+1
Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-11Make the unpacked object header functions static to sha1_file.cLibravatar Linus Torvalds2-4/+2
Nobody else uses them, and I'm going to start changing them. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-11git-send-email: Remove redundant Reply-To headerLibravatar Alp Toker1-1/+0
There is no sense in duplicating the sender address in Reply-To as it's already provided in the From header. Signed-off-by: Alp Toker <alp@atoker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-11typofix (git-name-rev documentation)Libravatar Alp Toker1-1/+1
Signed-off-by: Alp Toker <alp@atoker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-11Mention the [user@] part in documentation of ssh:// urls.Libravatar Yakov Lerner1-3/+3
Signed-off-by: Yakov Lerner <iler.ml@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-11tests: Set EDITOR=: and VISUAL=: globallyLibravatar Eric Wong4-3/+5
This way we don't have to remember to set it for each test; and if we forget, we won't cause interactive editors to be spawned for non-interactive tests. Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Log ref changes made by git-fetch and git-pull.Libravatar Shawn Pearce2-6/+16
When git-fetch updates a reference record in the associated reflog what type of update took place and who caused it (git-fetch or git-pull, by invoking git-fetch). Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Record the type of commit operation in the reflog.Libravatar Shawn Pearce2-4/+21
If committing a merge (.git/MERGE_HEAD exists), an initial tree (no HEAD) or using --amend to amend the prior commit then denote the subtype of commit in the reflog. This helps to distinguish amended or merge commits from normal commits. In the case of --amend the prior sha1 is probably the commit which is being thrown away in favor of the new commit. Since it is likely that the old commit doesn't have any ref pointing to it anymore it can be interesting to know why that the commit was replaced and orphaned. In the case of a merge the prior sha1 is probably the first parent of the new merge commit. Consequently having its prior sha1 in the reflog is slightly less interesting but its still informative to know the commit was the result of a merge which had to be completed by hand. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Allow user.name and user.email to drive reflog entry.Libravatar Shawn Pearce2-1/+1
Apparently calling setup_ident() after git_config causes the user.name and user.email values read from the config file to be replaced with the data obtained from the host. This means that users who have setup their email address in user.email will instead be writing reflog entries with their hostname. Moving setup_ident() to before git_config in update-ref resolves this ordering problem. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Fix linking for not-so-clever linkers.Libravatar Johannes Schindelin2-2/+1
On one of my systems, the linker is not intelligent enough to link with pager.o (in libgit.a) when only the variable pager_in_use is needed. The consequence is that the linker complains about an undefined variable. So, put the variable into environment.o, where it is linked always. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10git-rev-list: add documentation for --parents, --no-mergesLibravatar Matthias Lederhofer1-0/+6
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Merge branch 'jc/show-merge'Libravatar Junio C Hamano1-2/+51
* jc/show-merge: git log -p --merge [[--] paths...]
2006-07-10Avoid C99 comments, use old-style C comments instead.Libravatar Pavel Roskin10-31/+33
This doesn't make the code uglier or harder to read, yet it makes the code more portable. This also simplifies checking for other potential incompatibilities. "gcc -std=c89 -pedantic" can flag many incompatible constructs as warnings, but C99 comments will cause it to emit an error. Signed-off-by: Pavel Roskin <proski@gnu.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Fix more typos, primarily in the codeLibravatar Pavel Roskin34-56/+56
The only visible change is that git-blame doesn't understand "--compability" anymore, but it does accept "--compatibility" instead, which is already documented. Signed-off-by: Pavel Roskin <proski@gnu.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10gitweb.cgi: Teach "a=blob" action to know the blob/file mime typeLibravatar Luben Tuikov1-60/+67
Now action "blob" knows the file type: if the file type is not "text/*" then action "blob" defaults to "blob_plain", i.e. the file is downloaded raw for the browser to interpret. If the file type is "text/*", then "blob" defaults to the current "cat -n"-like output, from which you can click "plain", to get the "blob_plain" output. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10gitweb.cgi: Create $git_temp if it doesn't existLibravatar Luben Tuikov1-0/+3
Unless we'd done diffs, $git_temp doesn't exist and then mime lookups fail. Explicitly create it, if it doesn't exist already. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Merge branch 'lt/gitweb'Libravatar Junio C Hamano1-0/+1
* lt/gitweb: Add "raw" output option to blobs in "tree" view format
2006-07-10git-svn: fix --file/-F option in commit-diffLibravatar Eric Wong1-3/+3
Also, allow messages from tags to be used as commit messages. Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Avoid C99 initializersLibravatar Shawn Pearce3-24/+16
In a handful places, we use C99 structure and array initializers, which some compilers do not support. This can be handy when you are trying to compile GIT on a Solaris system that has an older C compiler, for example. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-10Merge branch 'jc/rename'Libravatar Junio C Hamano1-11/+22
* jc/rename: diffcore-rename: try matching up renames without populating filespec first.
2006-07-09Merge branch 'jc/grep'Libravatar Junio C Hamano1-51/+327
* jc/grep: git-grep: boolean expression on pattern matching.
2006-07-09Merge branch 'jc/mailinfo'Libravatar Junio C Hamano1-8/+24
* jc/mailinfo: mailinfo: assume input is latin-1 on the header as we do for the body
2006-07-09Merge branch 'ew/diff'Libravatar Junio C Hamano11-17/+78
* ew/diff: templates/hooks--update: replace diffstat calls with git diff --stat diff: do not use configuration magic at the core-level Update diff-options and config documentation. diff.c: --no-color to defeat diff.color configuration. diff.c: respect diff.renames config option
2006-07-09Merge branch 'ew/svn'Libravatar Junio C Hamano15-97/+72
* ew/svn: Fix some doubled word typos Typofix in Makefile comment. Makefile: export NO_SVN_TESTS git-svn: migrate out of contrib (follow-up) git-svn: migrate out of contrib
2006-07-09Additional merge-base tests (revised)Libravatar A Large Angry SCM1-0/+45
Signed-off-by: A Large Angry SCM <gitzilla@gmail.com>
2006-07-09merge-base: update the clean-up postprocessingLibravatar Junio C Hamano1-190/+90
This removes the "contaminate the well even more" approach taken in the current merge-base postprosessing code. Instead, when there are more than one merge-base results, we compute the merge-base between them and see if one is a fast-forward of the other, in which case the ancestor is removed from the result. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09Fix typos involving the word 'commit'Libravatar Alp Toker2-7/+7
Signed-off-by: Alp Toker <alp@atoker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09Fix some doubled word typosLibravatar Alp Toker1-1/+1
Signed-off-by: Alp Toker <alp@atoker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09Fix some doubled word typosLibravatar Alp Toker1-1/+1
Signed-off-by: Alp Toker <alp@atoker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09"git -p cmd" to page anywhereLibravatar Junio C Hamano4-1/+11
This allows you to say: git -p diff v2.6.16-rc5.. and the command pipes the output of any git command to your pager. [jc: this resurrects a month old RFC patch with improvement suggested by Linus to call it --paginate instead of --less.] Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09change ent to tree in git-diff documentationLibravatar Matthias Lederhofer2-10/+10
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09Typofix in Makefile comment.Libravatar Pavel Roskin1-1/+1
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09Assorted typo fixesLibravatar Pavel Roskin21-34/+34
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09GIT_TRACE: fix a mixed declarations and code warningLibravatar Timo Hirvonen1-1/+1
Signed-off-by: Timo Hirvonen <tihirvon@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09GIT_TRACE: show which built-in/external commands are executedLibravatar Matthias Lederhofer5-0/+69
With the environment variable GIT_TRACE set git will show - alias expansion - built-in command execution - external command execution on stderr. Signed-off-by: Matthias Lederhofer <matled@gmx.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09builtin "git prune"Libravatar Linus Torvalds5-48/+266
This actually removes the objects to be pruned, unless you specify "-n" (at which point it will just tell you which files it would prune). This doesn't do the pack-file pruning that the shell-script used to do, but if somebody really wants to, they could add it easily enough. I wonder how useful it is, though, considering that "git repack -a -d" is just a lot more efficient and generates a better end result. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-07-09Add "raw" output option to blobs in "tree" view formatLibravatar Luben Tuikov1-0/+1
Add a "raw" output option to blobs in "tree" view format, so that the user doesn't have to click on "blob", wait for the (binary) file to be uploaded and shown in "blob" mode, and then click on "plain" to download the (binary) file. This is useful when the file is clearly binary and we don't want the browser to upload and display it in "blob" mode, but we just want to download it. Case in point: pdf files, wlg. Note: the "raw" format is equivalent to the blob->plain view, not blob->head view. I.e. the view has the hash of the file as listed by git-ls-tree, not just "HEAD". Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>