summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2008-08-31Merge branch 'tr/rev-list-docs' into tr/filter-branchLibravatar Junio C Hamano4-26/+192
This prepares the necessary parts to merge filter-branch fix based on simplify-merges to master.
2008-08-30Merge branch 'jc/post-simplify' (early part) into tr/filter-branchLibravatar Junio C Hamano2-14/+45
* 'jc/post-simplify' (early part): revision --simplify-merges: make it a no-op without pathspec revision --simplify-merges: do not leave commits unprocessed revision --simplify-merges: use decoration instead of commit->util field
2008-08-18revision --simplify-merges: make it a no-op without pathspecLibravatar Junio C Hamano1-1/+4
When we are not pruning there is no reason to run the merge simplification. Also avoid running topo-order sort twice. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-18revision --simplify-merges: do not leave commits unprocessedLibravatar Junio C Hamano1-1/+3
When we still do not know how parents of a commit simplify to, we should defer processing of the commit, not discard it. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-14revision --simplify-merges: use decoration instead of commit->util fieldLibravatar Junio C Hamano2-12/+38
The users of revision walking machinery may want to use the util pointer for their own use. Use decoration to hold the data needed during merge simplification instead. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-12Documentation: rev-list-options: move --simplify-merges documentationLibravatar Thomas Rast1-6/+42
Fits --simplify-merges documentation into the 'History Simplification' section, including example. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-12Merge branch 'jc/post-simplify' into tr/rev-list-docsLibravatar Junio C Hamano4-21/+251
* jc/post-simplify: Topo-sort before --simplify-merges revision traversal: show full history with merge simplification revision.c: whitespace fix Conflicts: Documentation/rev-list-options.txt
2008-08-12Documentation: rev-list-options: Rewrite simplification descriptions for clarityLibravatar Thomas Rast1-17/+136
This completely rewrites the documentation of --full-history with lots of examples. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-12filter-branch: use --simplify-mergesLibravatar Thomas Rast1-3/+4
Use rev-list --simplify-merges everywhere. This changes the behaviour of --subdirectory-filter in cases such as O -- A -\ \ \ \- B -- M where A and B bring the same changes to the subdirectory: It now keeps both sides of the merge. Previously, the history would have been simplified to 'O -- A'. Merges of unrelated side histories that never touch the subdirectory are still removed. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-12Merge branch 'jc/post-simplify' into tr/filter-branchLibravatar Junio C Hamano4-23/+253
* jc/post-simplify: Topo-sort before --simplify-merges revision traversal: show full history with merge simplification revision.c: whitespace fix
2008-08-12filter-branch: fix ref rewriting with --subdirectory-filterLibravatar Thomas Rast2-17/+12
The previous ancestor discovery code failed on any refs that are (pre-rewrite) ancestors of commits marked for rewriting. This means that in a situation A -- B(topic) -- C(master) where B is dropped by --subdirectory-filter pruning, the 'topic' was not moved up to A as intended, but left unrewritten because we asked about 'git rev-list ^master topic', which does not return anything. Instead, we use the straightforward git rev-list -1 $ref -- $filter_subdir to find the right ancestor. To justify this, note that the nearest ancestor is unique: We use the output of git rev-list --parents -- $filter_subdir to rewrite commits in the first pass, before any ref rewriting. If B is a non-merge commit, the only candidate is its parent. If it is a merge, there are two cases: - All sides of the merge bring the same subdirectory contents. Then rev-list already pruned away the merge in favour for just one of its parents, so there is only one candidate. - Some merge sides, or the merge outcome, differ. Then the merge is not pruned and can be rewritten directly. So it is always safe to use rev-list -1. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-12filter-branch: Extend test to show rewriting bugLibravatar Thomas Rast1-3/+7
This extends the --subdirectory-filter test in t7003 to demonstrate a rewriting bug: when rewriting two refs A and B such that B is an ancestor of A, it fails to rewrite B. The underlying issue is that the rev-list invocation at git-filter-branch.sh:332 more or less boils down to git rev-list B --boundary ^A which outputs nothing because B is an ancestor of A. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-12Teach git diff about BibTeX head hunk patternsLibravatar Gustaf Hendeby2-0/+3
All BibTeX entries starts with an @ followed by an entry type. Since there are many entry types and own can be defined, the pattern matches legal entry type names instead of just the default types (which would be a long list). The pattern also matches strings and comments since they will also be useful to position oneself in a bib-file. Signed-off-by: Gustaf Hendeby <hendeby@isy.liu.se> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-12gitattributes: Document built in hunk header patternsLibravatar Gustaf Hendeby1-3/+10
Since the hunk header pattern text was written patterns for Ruby and Pascal/Delphi have been added. For users to be able to find them they should be documented not only in code. Signed-off-by: Gustaf Hendeby <hendeby@isy.liu.se> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-12git-daemon: SysV needs the signal handler reinstated.Libravatar Stephen R. van den Berg1-0/+1
Fixes the bug on (amongst others) Solaris that only the first child ever is reaped. Signed-off-by: Stephen R. van den Berg <srb@cuci.nl> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-11diff --check: do not unconditionally complain about trailing empty linesLibravatar Junio C Hamano2-2/+21
Recently "git diff --check" learned to detect new trailing blank lines just like "git apply --whitespace" does. However this check should not trigger unconditionally. This patch makes it honor the whitespace settings from core.whitespace and gitattributes. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-11Merge branch 'maint'Libravatar Junio C Hamano1-1/+2
* maint: git-bisect: fix wrong usage of read(1)
2008-08-11Documentation: rev-list-options: Fix a typoLibravatar Thomas Rast1-1/+1
Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-11Adjust for the new way of enabling the default post-update hookLibravatar Petr Baudis4-14/+21
The post-update hook, which is required to be enabled in order for the repository to be accessible over HTTP, is not enabled by chmod a+x anymore, but instead by dropping the .sample suffix. This patch emphasizes this change in the release notes (since I believe this is rather noticeable backwards-incompatible change). It also adjusts the documentation which still described the old way and fixes t/t5540-http-push.sh, which was broken for 1.5 month but apparently noone ever runs this test. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-11git-bisect: fix wrong usage of read(1)Libravatar Francis Moreau1-1/+2
Signed-off-by: Francis Moreau <francis.moro@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-11Fix typo in comments of longest_ancestor_length()Libravatar Nguyễn Thái Ngọc Duy1-1/+1
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-11Merge branch 'maint'Libravatar Junio C Hamano1-2/+1
* maint: Re-fix rev-list-options documentation
2008-08-11Re-fix rev-list-options documentationLibravatar Junio C Hamano1-2/+1
18a2197 (Documentation: rev-list-options: Fix -g paragraph formatting, 2008-08-10) introduced the third paragraph that is continued, but it seems to confuse docbook toolchain on FC9 machines. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-11Merge branch 'maint'Libravatar Junio C Hamano4-9/+23
* maint: Documentation: fix invalid reference to 'mybranch' in user manual Fix deleting reflog entries from HEAD reflog reflog test: add more tests for 'reflog delete' Documentation: rev-list-options: Fix -g paragraph formatting Conflicts: Documentation/user-manual.txt
2008-08-10Documentation: fix invalid reference to 'mybranch' in user manualLibravatar Ivan Stankovic1-1/+1
Signed-off-by: Ivan Stankovic <pokemon@fly.srk.fer.hr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-10Fix deleting reflog entries from HEAD reflogLibravatar Junio C Hamano2-3/+3
dwim_ref() used to resolve HEAD symbolic ref to its target (i.e. current branch). This incorrectly removed the reflog entry from the current branch when 'git reflog delete HEAD@{1}' was asked for. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-10reflog test: add more tests for 'reflog delete'Libravatar Pieter de Bie1-4/+18
This adds more tests for 'reflog delete' and marks it as broken, as currently a call to 'git reflog delete HEAD@{1}' deletes entries in the currently checked out branch's log, not the HEAD log. Noticed by John Wiegley Signed-off-by: Pieter de Bie <pdebie@ai.rug.nl> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-10Documentation: rev-list-options: Fix -g paragraph formattingLibravatar Thomas Rast1-2/+2
- Add an escape to @{now}. Without the escape, the brace does something magic and eats half the sentence up to the closing brace at 'timestamp}'. - Join the last paragraph with a '+'. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-09Update draft RelNotes for 1.6.0Libravatar Junio C Hamano1-3/+3
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-09Merge branch 'maint'Libravatar Junio C Hamano4-14/+11
* maint: asciidoc markup fixes Fail properly when cloning from invalid HTTP URL Conflicts: Documentation/git-push.txt
2008-08-09mailinfo: fix MIME multi-part message boundary handlingLibravatar Junio C Hamano6-7/+76
After finding a MIME multi-part message boundary line, the handle_body() function is supposed to first flush any accumulated contents from the previous part to the output stream. However, the code mistakenly output the boundary line it found. The old code that used one global, fixed-length buffer line[] used an alternate static buffer newline[] for keeping track of this accumulated contents and flushed newline[] upon seeing the boundary; when 3b6121f (git-mailinfo: use strbuf's instead of fixed buffers, 2008-07-13) converted a fixed-length buffer in this program to use strbuf,these two buffers were converted to "line" and "prev" (the latter of which now has a much more sensible name) strbufs, but the code mistakenly flushed "line" (which contains the boundary we have just found), instead of "prev". This resulted in the first boundary to be output in front of the first line of the message. The rewritten implementation of handle_boundary() lost the terminating newline; this would then result in the second line of the message to be stuck with the first line. The is_multipart_boundary() was designed to catch both the internal boundary and the terminating one (the one with trailing "--"); this also was broken with the rewrite, and the code in the handle_boundary() to handle the terminating boundary was never triggered. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08builtin-rm: Add a --force flagLibravatar Pieter de Bie2-2/+3
This adds a --force flag to git-rm, making it somewhat easier for subversion people to switch. Signed-off-by: Pieter de Bie <pdebie@ai.rug.nl> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08git-svn: wrap long lines in a few placesLibravatar Eric Wong1-2/+5
Oops, I let a few patches slip by with long lines in them. Extracted from an unrelated patch by: Marcus Griep <marcus@griep.us> Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08git-svn: Allow deep branch names by supporting multi-globsLibravatar Marcus Griep4-20/+246
Some repositories use a deep branching strategy, such as: branches/1.0/1.0.rc1 branches/1.0/1.0.rc2 branches/1.0/1.0.rtm branches/1.0/1.0.gold Only allowing a single glob stiffles this. This change allows for a single glob 'set' to accept this deep branching strategy. The ref glob depth must match the branch glob depth. When using the -b or -t options for init or clone, this is automatically done. For example, using the above branches: svn-remote.svn.branches = branches/*/*:refs/remote/*/* gives the following branch names: 1.0/1.0.rc1 1.0/1.0.rc2 1.0/1.0.rtm 1.0/1.0.gold [ew: * removed unrelated line-wrapping changes * fixed line-wrapping in a few more places * removed trailing whitespace * fixed bashism in test * removed unnecessary httpd startup in test * changed copyright on tests to 2008 Marcus Griep * added executable permissions to new tests ] Signed-off-by: Marcus Griep <marcus@griep.us> Acked-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08Fix multi-glob assertion in git-svnLibravatar Marcus Griep2-8/+33
Fixes bad regex match check for multiple globs (would always return one glob regardless of actual number). [ew: fixed a bashism in the test and some minor line-wrapping] Signed-off-by: Marcus Griep <marcus@griep.us> Acked-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08filter-branch: be more helpful when an annotated tag changesLibravatar Thomas Rast1-3/+11
Previously, git-filter-branch failed if it attempted to update an annotated tag. Now we ignore this condition if --tag-name-filter is given, so that we can later rewrite the tag. If no such option was provided, we warn the user that he might want to run with "--tag-name-filter cat" to achieve the intended effect. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08Documentation: filter-branch: document how to filter all refsLibravatar Thomas Rast1-5/+16
Document the '--' option that can be used to pass rev-list options (not just arguments), and give an example usage of '-- --all'. Remove reference to "the new branch name"; filter-branch takes arbitrary arguments to rev-list since dfd05e3. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08Makefile: add a target which will abort compilation with ancient shellsLibravatar Brandon Casey1-1/+7
This adds a make target which can be used to try to execute certain shell constructs which are required for compiling and running git. This patch provides a test for the $() notation for command substition which is used in the Makefile and extensively in the git scripts. The make target is named in such a way as to be a hint to the user that SHELL_PATH should be set to an appropriate shell. If the shell command fails, the user should receive a message similar to the following: make: *** [please_set_SHELL_PATH_to_a_more_modern_shell] Error 2 Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08bash: remove redundant check for 'git stash apply' optionsLibravatar SZEDER Gábor1-1/+1
It will never trigger anyway because of the first check, and even if it would, it would not offer the command line option. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de> Acked-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08GIT-VERSION-GEN: mark the version 'dirty' only if there are modified filesLibravatar Junio C Hamano1-0/+1
We used to mark the version string with '-dirty' if the cache was not up to date, but the only thing we want to know is if the binaries are built from modified source. Refresh the cache to avoid false dirtyness. Christian Jaeger noticed this issue while building under fakeroot environment (without -u) that lies about the file ownership data. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08Makefile: set SHELL to value of SHELL_PATHLibravatar Brandon Casey1-0/+2
Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08Documentation: user-manual: "git commit -a" doesn't motivate .gitignoreLibravatar Jonathan Nieder1-2/+2
"git commit -a" ignores untracked files and follows all tracked files, regardless of whether they are listed in .gitignore. So don't use it to motivate gitignore. Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu> Acked-by: J. Bruce Fields <bfields@fieldses.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08git-svn: add ability to specify --commit-url for dcommitLibravatar Eric Wong2-3/+15
This allows one to use public svn:// URLs for fetch and svn+ssh:// URLs for committing (without using the complicated rewriteRoot option, reimporting or git-filter-branch). Using this can also help avoid unnecessary server authentication/encryption overhead on busy SVN servers. Along with the new --revision option, this can also be allowed to override the branch detection in dcommit, too. This is potentially dangerous and not recommended! (And also purposely undocumented, but the loaded gun is there in case somebody wants to make it safe). Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-08Documentation: commit-tree: remove 16 parents restrictionLibravatar Thomas Rast1-5/+5
ef98c5ca lifted the 16 parents restriction in builtin-commit-tree.c, but forgot to update the documentation. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-07asciidoc markup fixesLibravatar Junio C Hamano3-5/+5
I see quite a few pages on k.org site, e.g. http://www.kernel.org/pub/software/scm/git/docs/git-rerere.html (scroll down to find "After this test merge") are misformatted to lose teletype text '+' that is followed by a comma, and turns the following paragraph all typeset in teletype. This patch seems to fix the issue at the site (meaning, with the particular vintage of asciidoc and docbook toolchain), without breaking things with the version I have at my primary development machine, but wider testing is very much appreciated. After this patch, git grep '`+`,' -- Documentation should report noting. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-07clone --mirror: avoid storing repeated tagsLibravatar Johannes Schindelin2-1/+14
With --mirror, clone asks for refs/* already, so it does not need to ask for ref/tags/*, too. Noticed by Cesar Eduardo Barros. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-07Merge branch 'lt/config-fsync' into maintLibravatar Junio C Hamano5-21/+74
* lt/config-fsync: Add config option to enable 'fsync()' of object files Split up default "i18n" and "branch" config parsing into helper routines Split up default "user" config parsing into helper routine Split up default "core" config parsing into helper routine
2008-08-07Merge branch 'jc/reflog-expire' into maintLibravatar Junio C Hamano1-19/+137
* jc/reflog-expire: Make default expiration period of reflog used for stash infinite Per-ref reflog expiry configuration
2008-08-07Merge branch 'ag/rewrite_one' into maintLibravatar Junio C Hamano1-6/+24
* ag/rewrite_one: Fix quadratic performance in rewrite_one.
2008-08-07Fail properly when cloning from invalid HTTP URLLibravatar Petr Baudis1-8/+5
Currently, when cloning from invalid HTTP URL, git clone will possibly return curl error, then a confusing message about remote HEAD and then return success and leave an empty repository behind, confusing either the end-user or the automated service calling it (think repo.or.cz). This patch changes the error() calls in get_refs_via_curl() to die()s, akin to the other get_refs_*() functions. Cc: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <gitster@pobox.com>