summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* whitespace cleanup.Junio C Hamano2006-02-021-11/+10
| | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* combine-diff: cleanup.Junio C Hamano2006-02-021-37/+65
| | | | | | | | | | The flag on the surviving lines meant "this parent is not different" while the parent_map flag on the lost lines meant "this parent is different", which was confusing. So swap the meaning of on-bit in the flag. Also more heavily comment the code. Signed-off-by: Junio C Hamano <junkio@cox.net>
* combine-diff: show parent line numbers as well.Junio C Hamano2006-02-021-11/+59
| | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* combine-diff: add a bit more comments.Junio C Hamano2006-02-021-1/+7
| | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-send-email: Add --quiet to reduce some of the chatter when sending emails.Ryan Anderson2006-02-021-3/+6
| | | | | Signed-off-by: Ryan Anderson <ryan@michonline.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Provide a more meaningful initial "From " line when using --compose in ↵Ryan Anderson2006-02-021-1/+1
| | | | | | | | | | | | git-send-email. git-send-email, when used with --compose, provided the user with a mbox-format file to edit. Some users, however, were confused by the leading, blank, "From " line, so this change puts the value that will appear on the From: line of the actual email on this line, along with a note that the line is ignored. Signed-off-by: Ryan Anderson <ryan@michonline.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* commit.c: "Merge" fix in pretty_print_commit.Junio C Hamano2006-02-021-5/+5
| | | | | | | | Earlier, f2d4227530499db3e273ae84f30adfd4b70791c6 commit broke Merge: lines for unabbreviated case. Do not emit extra dots if we do not abbreviate. Signed-off-by: Junio C Hamano <junkio@cox.net>
* merge-recursive: Speed up commit graph constructionFredrik Kuivinen2006-02-021-1/+4
| | | | | | | | Use __slots__ to speed up construction and decrease memory consumption of the Commit objects. Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
* merge-recursive: Make use of provided basesFredrik Kuivinen2006-02-021-10/+21
| | | | | | | This makes some cases faster as we don't have to build the commit graph. Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Documentation: git-diff-tree --cc also omits empty commitsJunio C Hamano2006-02-021-1/+1
| | | | | | | | | | | A misguided attempt to show logs at all time was inserted only to the documentation of this flag. Worse yet, it was not even implemented, causing more confusion. Drop it. We might want to have an option to show --pretty even when there is no diff output, but that is applicable to all forms of diff, not just --cc. Signed-off-by: Junio C Hamano <junkio@cox.net>
* combine-diff: fix placement of deletion.Junio C Hamano2006-02-021-1/+13
| | | | | | | | | The code misplaced a raw hunk that consists of solely deleted lines by one line. This showed e.g. Len's 12-way octopus (9fdb62af in the linux-2.6), kernel/power/disk.c, hunk starting at line 95, incorrectly. Signed-off-by: Junio C Hamano <junkio@cox.net>
* combine-diff: add safety check to --cc.Junio C Hamano2006-02-021-2/+18
| | | | | | | | | The earlier change implemented "only two version" check but without checking if the change rewrites from all the parents. This implements a check to make sure that a change introduced by the merge from all the parents is caught to be interesting. Signed-off-by: Junio C Hamano <junkio@cox.net>
* combine-diff: update --cc "uninteresting hunks" logic.Junio C Hamano2006-02-021-69/+33
| | | | | | | | | | Earlier logic was discarding hunks that has difference from only one parent or the same difference from all but one parent. This changes it to check if the differences on all lines are from the same sets of parents. This discards more uninteresting hunks and seems to match expectations more naturally. Signed-off-by: Junio C Hamano <junkio@cox.net>
* combine-diff: reuse diff from the same blob.Junio C Hamano2006-02-021-2/+37
| | | | | | | | | When dealing with an insanely large Octopus, it is possible to optimize by noticing that more than one parents have the same blob and avoid running diff between a parent and the merge result by reusing an earlier result. Signed-off-by: Junio C Hamano <junkio@cox.net>
* Allow diff and index commands to be interruptedPetr Baudis2006-02-012-0/+4
| | | | | | | | | | | | | | So far, e.g. git-update-index --refresh was basically uninterruptable by ctrl-c, since it hooked the SIGINT handler, but that handler would only unlink the lockfile but not actually quit. This makes it propagate the signal to the default handler. Note that I expected it to work without resetting the signal handler to SIG_DFL, but without that it ended in an infinite loop of tgkill()s - is my glibc violating SUS or what? Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
* rev-list: omit duplicated parents.Junio C Hamano2006-02-011-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Showing the same parent more than once for a commit does not make much sense downstream, so stop it. This can happen with an incorrectly made merge commit that merges the same parent twice, but can happen in an otherwise sane development history while squishing the history by taking into account only commits that touch specified paths. For example, $ git rev-list --max-count=1 --parents addafaf -- rev-list.c would have to show this commit ancestry graph: .---o---. / \ .---*---o---. / 93b74bc \ ---*---o---o-----o---o-----o addafaf d8f6b34 \ / .---o---o---. \ / .---*---. 3815f42 where 5 independent development tracks, only two of which have changes in the specified paths since they forked. The last change for the other three development tracks was done by the same commit before they forked, and we were showing that three times. Signed-off-by: Junio C Hamano <junkio@cox.net>
* update-index --index-info: allow stage 0 entries.Junio C Hamano2006-02-011-1/+1
| | | | | | | | Somehow we did not allow stuffing the index with stage 0 entries through --index-info interface. I do not think of a reason to forbid it offhand. Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-svnimport.perl: fix for 'arg list too long...'Sasha Khapyorsky2006-02-011-9/+16
| | | | | | | | | | This fixes 'arg list too long..' problem with git-ls-files. Note that second arg list separation loop (with 'git-update-index') is needed since git-ls-files arguments can be directories. Signed-off-by: Sasha Khapyorsky <sashak@voltaire.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Use local structs for HTTP slot callback dataNick Hengeveld2006-01-311-5/+5
| | | | | | | | There's no need for these structures to be static, and it could potentially cause problems down the road. Signed-off-by: Nick Hengeveld <nickh@reactrix.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* rev-list: allow -<n> as shorthand for --max-count=<n>Eric Wong2006-01-312-0/+9
| | | | | | | | | | This builds on top of the previous one. Traditionally, head(1) and tail(1) allow their line limits to be parsed this way. Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
* rev-list: allow -n<n> as shorthand for --max-count=<n>Eric Wong2006-01-312-0/+25
| | | | | | | | | | | Both -n<n> and -n <n> are supported. POSIX versions of head(1) and tail(1) allow their line limits to be parsed this way. I find --max-count to be a commonly used option, and also similar in spirit to head/tail, so I decided to make life easier on my worn out (and lazy :) fingers with this patch. Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Make apply accept the -pNUM option like patch does.Daniel Barkalow2006-01-312-3/+11
| | | | | | | This only applies to traditional diffs, not to git diffs. Signed-off-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Fix HTTP request result processing after slot reuseNick Hengeveld2006-01-313-7/+29
| | | | | | | | Add a way to store the results of an HTTP request when a slot finishes so the results can be processed after the slot has been reused. Signed-off-by: Nick Hengeveld <nickh@reactrix.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Make git-tar-tree use the tree_desc abstractionsLinus Torvalds2006-01-311-23/+24
| | | | | Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Make the "struct tree_desc" operations available to othersLinus Torvalds2006-01-312-6/+9
| | | | | | | | | | We have operations to "extract" and "update" a "struct tree_desc", but we only used them in tree-diff.c and they were static to that file. But other tree traversal functions can use them to their advantage Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
*-. Merge branches 'bf/doc' and 'db/tartree'Junio C Hamano2006-01-303-284/+193
|\ \
| | * Use struct commit in tar-treeDaniel Barkalow2006-01-301-35/+6
| | | | | | | | | | | | | | | | | | | | | It was open-coding getting the commit date from a commit. Signed-off-by: Daniel Barkalow <barkalow@iabervon> Signed-off-by: Junio C Hamano <junkio@cox.net>
| | * Use struct tree in tar-treeDaniel Barkalow2006-01-301-26/+24
| |/ |/| | | | | | | | | | | It was using an open-coded tree parser; use a struct tree instead. Signed-off-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * documentation: cvs migration - typofix.Junio C Hamano2006-01-301-1/+1
| | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
| * cvs-migration documentation updateJ. Bruce Fields2006-01-302-223/+163
|/ | | | | | | | | | | | | | | | | | | | | | | Here's some changes to the cvs-migration.txt. As usual, in my attempt to make things clearer someone may have found I've made them less so, or I may have just gotten something wrong; so any review is welcomed. I can break up this sort of thing into smaller steps if preferred, the monolothic patch is just a bit simpler for me for this sort of thing. I moved the material describing shared repository management from core-tutorial.txt to cvs-migration.txt, where it seems more appropriate, and combined two sections to eliminate some redundancy. I also revised the earlier sections of cvs-migration.txt, mainly trying to make it more concise. I've left the last section of cvs-migration.txt (on CVS annotate alternatives) alone for now. Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Junio C Hamano <junkio@cox.net>
* cvsexportcommit: add some examples to the documentationMartin Langhoff2006-01-291-0/+21
| | | | | | | Updated with Randall Schwartz's suggestion. Signed-off-by: Martin Langhoff <martin@catalyst.net.nz> Signed-off-by: Junio C Hamano <junkio@cox.net>
* exportcommit: replace backticks with safe_pipe_capture() or system() - ↵Martin Langhoff2006-01-291-20/+33
| | | | | | | | | | initial pass Replaced backticks with potentially troublesome unescaped input with safe_pipe_capture(). Signed-off-by: Martin Langhoff <martin@catalyst.net.nz> Signed-off-by: Junio C Hamano <junkio@cox.net>
* cvsimport: Add -S <skipfileregex> support and -v announces files retrievedMartin Langhoff2006-01-291-4/+15
| | | | | | | | | | A couple of things that seem to help importing broken CVS repos... -S '<slash-delimited-regex>' skips files with a matching path -v prints file name and version before fetching from cvs Signed-off-by: Martin Langhoff <martin@catalyst.net.nz> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Merge fixes up to GIT 1.1.6Junio C Hamano2006-01-295-15/+30
|\
| * GIT 1.1.6v1.1.6Junio C Hamano2006-01-295-15/+30
| |\
| | * git push -f documentationJ. Bruce Fields2006-01-291-4/+4
| | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
| | * git-branch: Documentation fixesFredrik Kuivinen2006-01-292-3/+6
| | | | | | | | | | | | | | | Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
| | * merge-recursive: Improve the error message printed when merge(1) isn't found.Fredrik Kuivinen2006-01-291-5/+10
| | | | | | | | | | | | | | | Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
| | * [PATCH] pre-commit sample hook: do not barf on the initial importJunio C Hamano2006-01-291-3/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The example hook barfs on the initial import. Ideally it should produce a diff from an empty tree, but for now let's stop at squelching the bogus error message. Often an initial import involves tons of badly formatted files from foreign SCM, so not complaining about them like this patch does might actually be a better idea than enforcing the "Perfect Patch" format on them. Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Documentation: diff -c/--ccJunio C Hamano2006-01-283-3/+73
| | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | diff-files -c/--cc: combine only when both ours and theirs exist.Junio C Hamano2006-01-281-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previous round forgot to make sure there actually are two versions to compare against the working tree version. Otherwise using -c/--cc would not make much sense. Also plug a small memory leak. Signed-off-by: Junio C Hamano <junkio@cox.net>
| | |
| \ \
| \ \
| \ \
| \ \
| \ \
*-----. \ \ Merge lt/revlist,jc/diff,jc/revparse,jc/abbrevJunio C Hamano2006-01-2815-107/+932
|\ \ \ \ \ \
| | | | * | | diff --abbrev=<n> option fix.Junio C Hamano2006-01-281-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Earier specifying an abbreviation shorter than minimum fell back to full 40 letters, which was nonsense. Make it to fall back to the minimum number (currently 4). Signed-off-by: Junio C Hamano <junkio@cox.net>
| | | | * | | pretty_print_commit: honor grafts.Junio C Hamano2006-01-281-26/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When displaying Merge: lines, we used to take the real commit parents from the commit objects. Use the parsed parents from the commit object instead, so that we honor fake parent information from info/grafts. Signed-off-by: Junio C Hamano <junkio@cox.net>
| | | | * | | pretty_print_commit(): pass commit object instead of commit->buffer.Junio C Hamano2006-01-285-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
| | | | * | | Rename rev-parse --abbrev to --short.Junio C Hamano2006-01-281-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The usage of rev-parse to serve as a flag/option parser for git-whatchanged and other commands have serious limitation that the flags cannot be something that is supported by rev-parse itself, and it cannot worked around easily. Since this is rarely used "poor-man's describe", rename the option for now as an easier workaround. Signed-off-by: Junio C Hamano <junkio@cox.net>
| | | | * | | rev-parse --abbrev: do not try abbrev shorter than minimum.Junio C Hamano2006-01-281-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We do not allow abbreviation shorter than 4 letters in other parts of the system so do not attempt to generate such. Noticed by Uwe Zeisberger. Signed-off-by: Junio C Hamano <junkio@cox.net>
| | | | * | | diff-tree: abbreviate merge parent object names with --abbrev --pretty.Junio C Hamano2006-01-285-9/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When --abbrev is in effect, abbreviate the merge parent names in prettyprinted output. Signed-off-by: Junio C Hamano <junkio@cox.net>
| | | | * | | rev-parse: --abbrev option.Junio C Hamano2006-01-281-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new option behaves just like --verify, but outputs an abbreviated object name that is unique within the repository. Signed-off-by: Junio C Hamano <junkio@cox.net>
| | | | * | | abbrev cleanup: use symbolic constantsJunio C Hamano2006-01-285-8/+7
| |_|_|/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The minimum length of abbreviated object name was hardcoded in different places to be 4, risking inconsistencies in the future. Also there were three different "default abbreviation precision". Use two C preprocessor symbols to clean up this mess. Signed-off-by: Junio C Hamano <junkio@cox.net>