summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'mk/maint-parse-careful'Junio C Hamano2008-03-0222-427/+725
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * mk/maint-parse-careful: receive-pack: use strict mode for unpacking objects index-pack: introduce checking mode unpack-objects: prevent writing of inconsistent objects unpack-object: cache for non written objects add common fsck error printing function builtin-fsck: move common object checking code to fsck.c builtin-fsck: reports missing parent commits Remove unused object-ref code builtin-fsck: move away from object-refs to fsck_walk add generic, type aware object chain walker Conflicts: Makefile builtin-fsck.c
| * receive-pack: use strict mode for unpacking objectsMartin Koegler2008-02-282-13/+29
| | | | | | | | | | Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * index-pack: introduce checking modeMartin Koegler2008-02-282-1/+90
| | | | | | | | | | | | | | | | Adds strict option, which bails out if the pack would introduces broken object or links in the repository. Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * unpack-objects: prevent writing of inconsistent objectsMartin Koegler2008-02-282-7/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch introduces a strict mode, which ensures that: - no malformed object will be written - no object with broken links will be written The patch ensures this by delaying the write of all non blob object. These object are written, after all objects they link to are written. An error can only result in unreferenced objects. Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * unpack-object: cache for non written objectsMartin Koegler2008-02-281-0/+23
| | | | | | | | | | | | | | | | | | | | | | Preventing objects with broken links entering the repository means, that write of some objects must be delayed. This patch adds a cache to keep the object data in memory. The delta resolving code must also search in the cache. Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * add common fsck error printing functionMartin Koegler2008-02-252-0/+31
| | | | | | | | | | Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * builtin-fsck: move common object checking code to fsck.cMartin Koegler2008-02-253-235/+257
| | | | | | | | | | Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * builtin-fsck: reports missing parent commitsMartin Koegler2008-02-253-1/+26
| | | | | | | | | | | | | | | | | | | | | | parse_commit ignores parent commits with certain errors (eg. a non commit object is already loaded under the sha1 of the parent). To make fsck reports such errors, it has to compare the nummer of parent commits returned by parse commit with the number of parent commits in the object or in the graft/shallow file. Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Remove unused object-ref codeMartin Koegler2008-02-2511-166/+1
| | | | | | | | | | Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * builtin-fsck: move away from object-refs to fsck_walkMartin Koegler2008-02-251-28/+71
| | | | | | | | | | Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * add generic, type aware object chain walkerMartin Koegler2008-02-254-2/+117
| | | | | | | | | | | | | | | | | | | | | | | | The requirements are: * it may not crash on NULL pointers * a callback function is needed, as index-pack/unpack-objects need to do different things * the type information is needed to check the expected <-> real type and print better error messages Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Merge branch 'sb/describe-long'Junio C Hamano2008-03-023-1/+21
|\ \ | | | | | | | | | | | | * sb/describe-long: git-describe: --long shows the object name even for a tagged commit
| * | git-describe: --long shows the object name even for a tagged commitSanti Béjar2008-02-253-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is useful when you want to see parts of the commit object name in "describe" output, even when the commit in question happens to be a tagged version. Instead of just emitting the tag name, it will describe such a commit as v1.2-0-deadbeef (0th commit since tag v1.2 that points at object deadbeef....). Signed-off-by: Santi Béjar <sbejar@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'ew/maint-svn-cert-fileprovider'Junio C Hamano2008-03-020-0/+0
|\ \ \ | | | | | | | | | | | | | | | | * ew/maint-svn-cert-fileprovider: git-svn: Don't prompt for client cert password everytime.
| * | | git-svn: Don't prompt for client cert password everytime.Sebastian Noack2008-02-271-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Acked-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'js/maint-daemon'Junio C Hamano2008-03-021-5/+13
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | * js/maint-daemon: daemon: ensure that base-path is an existing directory daemon: send more error messages to the syslog
| * | | | daemon: ensure that base-path is an existing directoryJohannes Sixt2008-02-271-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Any request to the daemon would fail if base-path (if specified) is not a directory. We now check for this condition early. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | daemon: send more error messages to the syslogJohannes Sixt2008-02-271-5/+5
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were a number of die() calls before the syslog was opened; hence, these error messages would have been sent to /dev/null in detached mode. Now we install the daemon-specific die routine before any error message is generated so that these messages go to the syslog. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Documentation: Remove --{min,max}-age option from git-log(1)Jakub Narebski2008-03-021-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The --max-age=<timestamp> and --min-age=<timestamp> are now shown only in the git-rev-list manpage (plumbing). Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | cleanup: remove unused git_checkout_configDenis Cheng2008-03-021-6/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Directly call git_default_config instead. Signed-off-by: Denis Cheng <crquan@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Fix make_absolute_path() for parameters without a slashJohannes Schindelin2008-03-022-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When passing "xyz" to make_absolute_path(), make_absolute_path() erroneously tried to chdir("xyz"), and then append "/xyz". Instead, skip the chdir() completely when no slash was found. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | diff: make sure work tree side is shown as 0{40} when differentJunio C Hamano2008-03-022-5/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ping Yin noticed that "git diff-index --raw" shows 0{40} when work tree has submodule difference, but "git diff --raw" didn't correctly do so. There was a mistake in the diffcore_skip_stat_unmatch() that was meant to clean up the stat-only difference for running diff between the index and work tree and diff between the tree and the work tree, to cause it re-read from the submodule repository HEAD. When ce_stat_match() says work tree is different, we should always say 0{40} on the work tree side. This patch fixes the issue, and adds tests. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | diff-lib.c: constness strengtheningJunio C Hamano2008-03-021-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The internal implementation of diff-index codepath used to use non const pointer to pass sha1 around, but it did not have to. With this, we can also lose the private no_sha1[] array, as we can use the public null_sha1[] array that exists exactly for the same purpose. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Clean up find_unique_abbrev() callersJunio C Hamano2008-03-013-11/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now find_unique_abbrev() never returns NULL, there is no need for callers to prepare for seeing NULL and fall back to giving the full 40-hexdigits. While we are at it, drop "..." in the "git reset" output that reports the location of the new HEAD, between the abbreviated commit object name and the one line commit summary. Because we are always showing the HEAD (which cannot be missing!), we never had a case where we show the full 40 hexdigits that is not followed by three dots, and these three dots were stealing 3 columns from the precious horizontal screen real estate out of 80 that can better be used for the one line commit summary. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | find_unique_abbrev(): redefine semanticsJunio C Hamano2008-03-011-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The function returned NULL when no object that matches the name was found, but that made the callers more complicated, as nobody used that NULL return as an indication that no object with such a name exists. They (at least the careful ones) instead took the full 40-hexdigit and used in such a case, and the careless ones segfaulted. With this "git rev-parse --short 5555555555555555555555555555555555555555" would stop segfaulting. This is based on Jeff King's rewrite to my RFC patch, but "missing" logic swapped to "exists". The final logic reads: For existing objects, make sure the abbreviated string uniquely identifies it. Otherwise, make sure the abbreviated string is long enough so that it would not name any existing object. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | git rebase --abort: always restore the right commitMike Hommey2008-03-012-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, --abort would end by git resetting to ORIG_HEAD, but some commands, such as git reset --hard (which happened in git rebase --skip, but could just as well be typed by the user), would have already modified ORIG_HEAD. Just use the orig-head we store in $dotest instead. Signed-off-by: Mike Hommey <mh@glandium.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Documentation/git-rebase.txt: Add --strategy to synopsysMike Hommey2008-03-011-0/+1
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Mike Hommey <mh@glandium.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | CodingGuidelines: spell out how we use grep in our scriptsJunio C Hamano2008-03-011-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Our scripts try to stick to fairly limited subset of POSIX BRE for portability. It is unclear from manual page from GNU grep which is GNU extension and which is portable, so let's spell it out to help new people to keep their contributions from hurting porters. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | allow git-am to run in a subdirectoryJeff King2008-03-011-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We just move to the top of the tree and proceed. This shouldn't break any existing callers, since the behavior was previously disallowed. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | rename: warn user when we have turned off rename detectionJeff King2008-03-011-3/+4
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Add test for git rebase --abortMike Hommey2008-03-011-0/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We expect git rebase --abort to come back to the original (pre-rebase) head, independently from when it's run during a rebase. Signed-off-by: Mike Hommey <mh@glandium.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | t6024: move "git reset" to prepare for a test inside the test itselfJunio C Hamano2008-03-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Noticed by Mike Hommey. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | gc: Add --quiet optionFrank Lichtenheld2008-03-012-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Pass -q option to git-repack. Signed-off-by: Frank Lichtenheld <frank@lichtenheld.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'master' of git://repo.or.cz/git-guiJunio C Hamano2008-02-295-45/+139
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 'master' of git://repo.or.cz/git-gui: git-gui: fix typo in lib/spellcheck.tcl git-gui: Shorten Aspell version strings to just Aspell version number git-gui: Gracefully display non-aspell version errors to users git-gui: Catch and display aspell startup failures to the user git-gui: Only bind the spellcheck popup suggestion hook once git-gui: Remove explicit references to 'aspell' in message strings git-gui: Ensure all spellchecker 'class' variables are initialized git-gui: Update German translation. git-gui: (i18n) Add newly added translation strings to template.
| * \ \ \ Merge branch 'maint'Shawn O. Pearce2008-02-281-1/+1
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: Paper bag fix info dialog when no files are staged at commit
| * \ \ \ \ Merge branch 'maint'Shawn O. Pearce2008-02-223-3/+25
| |\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: Focus insertion point at end of strings in repository chooser git-gui: Avoid hardcoded Windows paths in Cygwin package files git-gui: Default TCL_PATH to same location as TCLTK_PATH git-gui: Paper bag fix error dialogs opening over the main window
| * | | | | | git-gui: fix typo in lib/spellcheck.tclMichele Ballabio2008-02-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Michele Ballabio <barra_cuda@katamail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | git-gui: Shorten Aspell version strings to just Aspell version numberShawn O. Pearce2008-02-211-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We really only support Aspell, so showing the compatibility line from ispell is of little value to end users. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | git-gui: Gracefully display non-aspell version errors to usersShawn O. Pearce2008-02-211-1/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the user has somehow managed to make us execute ispell instead of aspell, even though our code is invoking aspell, and ispell is not recognizing the aspell command line options we use to invoke it then we don't want a giant usage message back from ispell. Instead we show the ispell version number, letting the user know we don't actually support that spell checker. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | git-gui: Catch and display aspell startup failures to the userShawn O. Pearce2008-02-211-4/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we feed a bad dictionary name to aspell on startup it may appear to start (as Tcl found the executable in our $PATH) but it fails to give us the version string. In such a case the close of the pipe will report the exit status of the process (failure) and that is an error in Tcl. We now trap the subprocess failure and display the stderr message from it, letting the user know why the failure is happening. We then disable the spell checker, but keep our object instance so the user can alter their preferred dictionary through the options dialog, and possibly restart the spell checker. I was also originally wrong to use "error" here for the display of the problem to the user. I meant to use "error_popup", which will open a message box and show the failure in a GUI context, rather than killing git-gui and showing the message on the console. Noticed by Ilari on #git. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | git-gui: Only bind the spellcheck popup suggestion hook onceShawn O. Pearce2008-02-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we reconnect to the spellchecker there is no reason to resetup the binding for button 3 on our text widget to show the suggestion list (if available). Plus, by moving it out of _connect and into init we can now break out of _connect earlier if there is something wrong with the pipe, for example if the dictionary we were asked to load is not valid. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | git-gui: Remove explicit references to 'aspell' in message stringsShawn O. Pearce2008-02-211-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Users may or may not be using aspell here. About the only thing we are using that is aspell specific (and not supported by ispell or an ispell variant) is some command line options when we start up aspell, and a forced encoding of UTF-8. Both of these can be corrected and/or cleaned up by users through an aspell wrapper script, or through further improvements to git-gui. There is no reason to require our translated strings to reference a specific spell checker, especially if that spell checker implementation is not very suitable for the language being translated. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | git-gui: Ensure all spellchecker 'class' variables are initializedShawn O. Pearce2008-02-212-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we somehow managed to get our spellchecker instance created but aspell wasn't startable we may not finish _connect and thus may find one or more of our fields was not initialized in the instance. If we have an instance but no version, there is no reason to show a version to the user in our about dialog. We effectively have no spellchecker available. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | Merge branch 'maint'Shawn O. Pearce2008-02-211-7/+11
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: Ensure error dialogs always appear over all other windows
| * \ \ \ \ \ \ Merge branch 'maint'Shawn O. Pearce2008-02-201-1/+1
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: relax "dirty" version detection
| * | | | | | | | git-gui: Update German translation.Christian Stimming2008-02-172-25/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Christian Stimming <stimming@tuhh.de> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | | | git-gui: (i18n) Add newly added translation strings to template.Christian Stimming2008-02-172-6/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | And markup one missing string for translation. Signed-off-by: Christian Stimming <stimming@tuhh.de> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | | | | | | | | Merge branch 'maint'Junio C Hamano2008-02-293-3/+3
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: Documentation cherry-pick: Fix cut-and-paste error git.el: find the git-status buffer whatever its name is git-gui: Paper bag fix info dialog when no files are staged at commit
| * | | | | | | | | Documentation cherry-pick: Fix cut-and-paste errorMike Ralphson2008-02-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Mike Ralphson <mike@abacus.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | | | | | git.el: find the git-status buffer whatever its name isRémi Vanicat2008-02-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git-status used the buffer name to find git-status buffers, and that can fail if the buffer has another name, for example when multiple working directories is tracked. Signed-off-by: Rémi Vanicat <vanicat@debian.org> Acked-by: Alexandre Julliard <julliard@winehq.org> Tested-by: Xavier Maillard <xma@gnu.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>