]> asedeno.scripts.mit.edu Git - git.git/log
git.git
17 years agoFix up duplicate parents removal
Linus Torvalds [Sat, 21 Jul 2007 06:11:19 +0000 (23:11 -0700)]
Fix up duplicate parents removal

This removes duplicate parents properly, making gitk happy again.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogitweb cleanup: Move @diff_opts declaration earlier
Jakub Narebski [Fri, 20 Jul 2007 00:15:09 +0000 (02:15 +0200)]
gitweb cleanup: Move @diff_opts declaration earlier

Move @diff_opts declaration earlier, so that all gitweb options are
together (and not separated by %feature hash and some subroutines),
with the exception of $GITWEB_CONFIG which must be after all option
variables including %feature hash.

While at it, in the moved comment, note that diff option '-C' implies
'-M', instead of suggesting that '-M', '-C' is required.

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoAdd GIT_EDITOR environment and core.editor configuration variables
Adam Roben [Fri, 20 Jul 2007 05:09:35 +0000 (22:09 -0700)]
Add GIT_EDITOR environment and core.editor configuration variables

These variables let you specify an editor that will be launched in
preference to the EDITOR and VISUAL environment variables. The order
of preference is GIT_EDITOR, core.editor, EDITOR, VISUAL.

[jc: added a test and config variable documentation]

Signed-off-by: Adam Roben <aroben@apple.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoDocument how to tell git to not launch a pager
Steven Grimm [Thu, 19 Jul 2007 10:43:51 +0000 (03:43 -0700)]
Document how to tell git to not launch a pager

Signed-off-by: Steven Grimm <koreth@midwinter.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogit-gui: Completely remove support for creating octopus merges
Shawn O. Pearce [Thu, 19 Jul 2007 06:24:25 +0000 (02:24 -0400)]
git-gui: Completely remove support for creating octopus merges

I'm working on refactoring the UI of the merge dialog, because as it
currently stands the dialog is absolutely horrible, especially when
you have 200+ branches available from a single remote system.

In that refactoring I plan on using the choose_rev widget to allow
the user to select exactly which branch/commit they want to merge.
However since that only selects a single commit I'm first removing
the code that supports octopus merges.

A brief consultation on #git tonight seemed to indicate that the
octopus merge strategy is not as useful as originally thought when
it was invented, and that most people don't commonly use them.  So
making users fall back to the command line to create an octopus is
actually maybe a good idea here, as they might think twice before
they use it.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Don't show blame tooltips that we have no data for
Shawn O. Pearce [Thu, 19 Jul 2007 05:45:42 +0000 (01:45 -0400)]
git-gui: Don't show blame tooltips that we have no data for

If we haven't yet loaded any commit information for a given line but
our tooltip timer fired and tried to draw the tooltip we shouldn't;
there is nothing to show.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Translate standard encoding names to Tcl ones
Shawn O. Pearce [Thu, 19 Jul 2007 05:13:29 +0000 (01:13 -0400)]
git-gui: Translate standard encoding names to Tcl ones

This is a essentially a copy of Paul Mackerras encoding support from
gitk.  I stole the code from gitk commit fd8ccbec4f0161, as Paul has
already done all of the hard work setting up this translation table.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Avoid unnecessary global statements when possible
Shawn O. Pearce [Thu, 19 Jul 2007 04:43:16 +0000 (00:43 -0400)]
git-gui: Avoid unnecessary global statements when possible

Running global takes slightly longer than just accessing the variable
via its package name, especially if the variable is just only once in
the procedure, or isn't even used at all in the procedure.  So this is
a minor cleanup for some of our commonly invoked procedures.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Bind Ctrl/Cmd-M to merge action
Shawn O. Pearce [Thu, 19 Jul 2007 04:39:23 +0000 (00:39 -0400)]
git-gui: Bind Ctrl/Cmd-M to merge action

Users who merge often may want to access the merge action quickly,
so we now bind M to the merge action.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agoDon't offer my special Tools/Migrate hack unless in multicommit
Shawn O. Pearce [Wed, 18 Jul 2007 13:37:27 +0000 (09:37 -0400)]
Don't offer my special Tools/Migrate hack unless in multicommit

Users shouldn't see this menu option if they startup a browser or
blame from the command line, especially if they are doing so on a
bare repository.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agoRename read_pipe() with read_fd() and make its buffer nul-terminated.
Carlos Rica [Wed, 18 Jul 2007 18:31:03 +0000 (20:31 +0200)]
Rename read_pipe() with read_fd() and make its buffer nul-terminated.

The new name is closer to the purpose of the function.

A NUL-terminated buffer makes things easier when callers need that.
Since the function returns only the memory written with data,
almost always allocating more space than needed because final
size is unknown, an extra NUL terminating the buffer is harmless.
It is not included in the returned size, so the function
remains working as before.

Also, now the function allows the buffer passed to be NULL at first,
and alloc_nr is now used for growing the buffer, instead size=*2.

Signed-off-by: Carlos Rica <jasampler@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMerge branch 'master' of git://people.freedesktop.org/~hausmann/git-p4
Junio C Hamano [Thu, 19 Jul 2007 00:23:03 +0000 (17:23 -0700)]
Merge branch 'master' of git://people.freedesktop.org/~hausmann/git-p4

* 'master' of git://people.freedesktop.org/~hausmann/git-p4:
  git-p4: Cleanup, used common function for listing imported p4 branches
  git-p4: Fix upstream branch detection for submit/rebase with multiple branches.
  git-p4: Cleanup, make listExistingP4Branches a global function for later use.
  git-p4: input to "p4 files" by stdin instead of arguments
  git-p4: use subprocess in p4CmdList

17 years agofilter-branch: get rid of "set -e"
Johannes Schindelin [Wed, 18 Jul 2007 13:17:43 +0000 (14:17 +0100)]
filter-branch: get rid of "set -e"

It was reported by Alex Riesen that "set -e" can break something as
trivial as "unset CDPATH" in bash.

So get rid of "set -e".

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogit-svn: Minimalistic patch which allows svn usernames with space(s).
Richard MUSIL [Tue, 17 Jul 2007 17:02:57 +0000 (19:02 +0200)]
git-svn: Minimalistic patch which allows svn usernames with space(s).

Changed filter for username in svn-authors file, so even 'user name' is accepted.

Acked-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoDo a better job at guessing unknown character sets
Linus Torvalds [Tue, 17 Jul 2007 17:34:44 +0000 (10:34 -0700)]
Do a better job at guessing unknown character sets

At least in the kernel development community, we're generally slowly
converting to UTF-8 everywhere, and the old default of Latin1 in emails is
being supplanted by UTF-8, and it doesn't necessarily show up as such in
the mail headers (because, quite frankly, when people send patches
around, they want the email client to do as little as humanly possible
about the patch)

Despite that, it's often the case that email addresses etc still have
Latin1, so I've seen emails where this is a mixed bag, with Signed-off
parts being copied from email (and containing Latin1 characters), and the
rest of the email being a patch in UTF-8.

So this suggests a very natural change: if the target character set is
utf-8 (the default), and if the source already looks like utf-8, just
assume that it doesn't need any conversion at all.

Only assume that it needs conversion if it isn't already valid utf-8, in
which case we (for historical reasons) will assume it's Latin1.

Basically no really _valid_ latin1 will ever look like utf-8, so while
this changes our historical behaviour, it doesn't do so in practice, and
makes the default behaviour saner for the case where the input was already
in proper format.

We could do a more fancy guess, of course, but this correctly handled a
series of patches I just got from Andrew that had a mixture of Latin1 and
UTF-8 (in different emails, but without any character set indication).

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoDocument "git stash message..."
しらいしななこ [Tue, 17 Jul 2007 08:15:42 +0000 (17:15 +0900)]
Document "git stash message..."

The command was recently updated to take message on the command line, but
this feature has not been documented.

Signed-off-by: Nanako Shiraishi <nanako3@bluebottle.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agounpack-trees.c: assume submodules are clean during check-out
Sven Verdoolaege [Tue, 17 Jul 2007 18:28:28 +0000 (20:28 +0200)]
unpack-trees.c: assume submodules are clean during check-out

In particular, when moving back to a commit without a given submodule
and then moving back forward to a commit with the given submodule,
we shouldn't complain that updating would lose untracked file in
the submodule, because git currently does not checkout subprojects
during superproject check-out.

Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMerge branch 'maint'
Junio C Hamano [Thu, 19 Jul 2007 00:00:36 +0000 (17:00 -0700)]
Merge branch 'maint'

* maint:
  Force listingblocks to be monospaced in manpages
  Do not expect unlink(2) to fail on a directory.

17 years agoForce listingblocks to be monospaced in manpages
Julian Phillips [Wed, 18 Jul 2007 21:33:57 +0000 (22:33 +0100)]
Force listingblocks to be monospaced in manpages

For the html output we can use a stylesheet to make sure that the
listingblocks are presented in a monospaced font.  For the manpages do
it manually by inserting a ".ft C" before and ".ft" after the block in
question.

In order for these roff commands to get through to the manpage they
have to be element encoded to prevent quoting.

Signed-off-by: Julian Phillips <julian@quantumfyre.co.uk>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogit-p4: Cleanup, used common function for listing imported p4 branches
Simon Hausmann [Wed, 18 Jul 2007 15:27:50 +0000 (17:27 +0200)]
git-p4: Cleanup, used common function for listing imported p4 branches

Signed-off-by: Simon Hausmann <simon@lst.de>
17 years agogit-p4: Fix upstream branch detection for submit/rebase with multiple branches.
Simon Hausmann [Wed, 18 Jul 2007 10:40:12 +0000 (12:40 +0200)]
git-p4: Fix upstream branch detection for submit/rebase with multiple branches.

Don't use git name-rev to locate the upstream git-p4 branch for rebase and submit but instead locate the branch by comparing the depot paths.
name-rev may produce results like wrongbranch~12 as it uses the first match.

Signed-off-by: Simon Hausmann <simon@lst.de>
Signed-off-by: Marius Storm-Olsen <marius@trolltech.com>
17 years agogit-p4: Cleanup, make listExistingP4Branches a global function for later use.
Simon Hausmann [Wed, 18 Jul 2007 08:56:31 +0000 (10:56 +0200)]
git-p4: Cleanup, make listExistingP4Branches a global function for later use.

Signed-off-by: Simon Hausmann <simon@lst.de>
Signed-off-by: Marius Storm-Olsen <marius@trolltech.com>
17 years agoDo not expect unlink(2) to fail on a directory.
Junio C Hamano [Wed, 18 Jul 2007 05:58:28 +0000 (22:58 -0700)]
Do not expect unlink(2) to fail on a directory.

When "git checkout-index" checks out path A/B/C, it makes sure A
and A/B are truly directories; if there is a regular file or
symlink at A, we prefer to remove it.

We used to do this by catching an error return from mkdir(2),
and on EEXIST did unlink(2), and when it succeeded, tried
another mkdir(2).

Thomas Glanzmann found out the above does not work on Solaris
for a root user, as unlink(2) was so old fashioned there that it
allowed to unlink a directory.

As pointed out, this still doesn't guarantee that git won't call
"unlink()" on a directory (race conditions etc), but that's
fundamentally true (there is no "funlink()" like there is
"fstat()"), and besides, that is in no way git-specific (ie it's
true of any application that gets run as root).

Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogit-gui: Convert merge dialog to use class system
Shawn O. Pearce [Wed, 18 Jul 2007 06:56:44 +0000 (02:56 -0400)]
git-gui: Convert merge dialog to use class system

I've found that the class code makes it a whole lot easier to create
more complex GUI code, especially the dialogs.  So before I make any
major improvements to the merge dialog's interface I'm going to first
switch it to use the class system, so the code is slightly cleaner.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Increase the default height of the revision picker
Shawn O. Pearce [Wed, 18 Jul 2007 06:27:39 +0000 (02:27 -0400)]
git-gui: Increase the default height of the revision picker

Showing only five lines of heads/tags is not very useful to a user
when they have about 10 branches that match the filter expression.
The list is just too short to really be able to read easily, at
least not without scrolling up and down.  Expanding the list out
to 10 really makes the revision picker easier to read and access,
as you can read the matching branches much more quickly.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Clarify the visualize history menu options
Shawn O. Pearce [Wed, 18 Jul 2007 05:48:41 +0000 (01:48 -0400)]
git-gui: Clarify the visualize history menu options

Users who are new to Git may not realize that visualizing things in
a repository involves looking at history.  Adding in a small amount
of text to the menu items really helps to understand what the action
might do, before you invoke it.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Allow users to browse any branch, not just the current one
Shawn O. Pearce [Wed, 18 Jul 2007 05:39:27 +0000 (01:39 -0400)]
git-gui: Allow users to browse any branch, not just the current one

We now allow users to pick which commit they want to browse through
our revision picking mega-widget.  This opens up in a dialog first,
and then opens a tree browser for that selected commit.  It is a very
simple approach and requires minimal code changes.

I also clarified the language a bit in the Repository menu, to show
that these actions will access files.  Just in case a user is not
quite sure what specific action they are looking for, but they know
they want some sort of file thing.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Allow browser subcommand to start in subdirectory
Shawn O. Pearce [Wed, 18 Jul 2007 04:53:14 +0000 (00:53 -0400)]
git-gui: Allow browser subcommand to start in subdirectory

Like our blame subcommand the browser subcommand now accepts both
a revision and a path, just a revision or just a path.  This way
the user can start the subcommand on any branch, or on any subtree.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Allow blame/browser subcommands on bare repositories
Shawn O. Pearce [Wed, 18 Jul 2007 03:58:56 +0000 (23:58 -0400)]
git-gui: Allow blame/browser subcommands on bare repositories

A long time ago Linus Torvalds tried to run git-gui on a bare
repository to look at the blame viewer, but it failed to start
because we required that the user run us only from within a
working directory that had a normal git repository associated
with it.

This change relaxes that requirement so that you can start the
tree browser or the blame viewer against a bare repository. In
the latter case we do require that you provide a revision and a
pathname if we cannot find the pathname in the current working
directory.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Move feature option selection before GIT_DIR init
Shawn O. Pearce [Wed, 18 Jul 2007 03:23:56 +0000 (23:23 -0400)]
git-gui: Move feature option selection before GIT_DIR init

By moving our feature option determination up before we look for GIT_DIR
we can make a decision about whether or not we need a working tree up
front, before we look for GIT_DIR.  A future change could then allow
us to start in a bare Git repository if we only need access to the ODB.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Delay the GC hint until after we are running
Shawn O. Pearce [Wed, 18 Jul 2007 03:20:56 +0000 (23:20 -0400)]
git-gui: Delay the GC hint until after we are running

I'm moving the code related to looking to see if we should GC now
into a procedure closer to where it belongs, the database module.
This reduces our script by a few lines for the single commit case
(aka citool).  But really it just is to help organize the code.

We now perform the check after we have been running for at least
1 second.  This way the main window has time to open up and our
dialog (if we open it) will attach to the main window, instead of
floating out in no-mans-land like it did before on Mac OS X.

I had to use a wait of a full second here as a wait of 1 millisecond
made our console install itself into the main window.  Apparently we
had a race condition with the console code where both the console and
the main window thought they were the main window.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Let the user continue even if we cannot understand git version
Shawn O. Pearce [Wed, 18 Jul 2007 03:09:31 +0000 (23:09 -0400)]
git-gui: Let the user continue even if we cannot understand git version

Some users may do odd things, like tag their own private version of
Git with an annotated tag such as 'testver', then compile that git
and try to use it with git-gui.  In such a case `git --version` will
give us 'git version testver', which is not a numeric argument that
we can pass off to our version comparsion routine.

We now check that the cleaned up git version is a going to pass the
version comparsion routine without failure.  If it has a non-numeric
component, or lacks at least a minor revision then we ask the user to
confirm they really want to use this version of git within git-gui.
If they do we shall assume it is git 1.5.0 and run with only the code
that will support.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Change our initial GC hint to be an estimate
Shawn O. Pearce [Wed, 18 Jul 2007 02:49:44 +0000 (22:49 -0400)]
git-gui: Change our initial GC hint to be an estimate

Instead of running a full git-count-objects to count all of the loose
objects we can get a reasonably close approximation by counting the
number of files in the .git/objects/42 subdirectory. This works out
reasonably well because the SHA-1 hash has a fairly even distribution,
so every .git/objects/?? subdirectory should get a relatively equal
number of files.  If we have at least 8 files in .git/objects/42 than it
is very likely there is about 8 files in every other directory, leaving
us with around 2048 loose objects.

This check is much faster, as we need to only perform a readdir of
a single directory, and we can do it directly from Tcl and avoid the
costly fork+exec.

All of the credit on how clever this is goes to Linus Torvalds; he
suggested using this trick in a post commit hook to repack every so
often.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Don't crash in ask_popup if we haven't mapped main window yet
Shawn O. Pearce [Wed, 18 Jul 2007 02:45:53 +0000 (22:45 -0400)]
git-gui: Don't crash in ask_popup if we haven't mapped main window yet

If we have more than our desired number of objects and we try to
open the "Do you want to repack now?" dialog we cannot include a
-parent . argument if the main window has not been mapped yet.
On Mac OS X it appears this window isn't mapped right away, so we
had better hang avoid including it.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Delay searching for 'nice' until its really asked for
Shawn O. Pearce [Wed, 18 Jul 2007 02:31:16 +0000 (22:31 -0400)]
git-gui: Delay searching for 'nice' until its really asked for

Not every caller of 'git' or 'git_pipe' wants to use nice to lower the
priority of the process its executing.  In many cases we may never use
the nice process to launch git.  So we can avoid searching our $PATH
to locate a suitable nice if we'll never actually use it.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Handle git versions of the form n.n.n.GIT
Julian Phillips [Tue, 17 Jul 2007 21:14:06 +0000 (22:14 +0100)]
git-gui: Handle git versions of the form n.n.n.GIT

The git-gui version check doesn't handle versions of the form
n.n.n.GIT which you can get by installing from an tarball produced by
git-archive.

Without this change you get an error of the form:
'Error in startup script: expected version number but got "1.5.3.GIT"'

Signed-off-by: Julian Phillips <julian@quantumfyre.co.uk>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agoUpdate INSTALL
Junio C Hamano [Tue, 17 Jul 2007 06:59:54 +0000 (23:59 -0700)]
Update INSTALL

We haven't used bignum in rev-list from openssl nor elsewhere
for a long time.  Also git-gui is now part of git.git itself,
and depends on wish.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogit-p4: input to "p4 files" by stdin instead of arguments
Scott Lamb [Mon, 16 Jul 2007 03:58:11 +0000 (20:58 -0700)]
git-p4: input to "p4 files" by stdin instead of arguments

This approach, suggested by Alex Riesen, bypasses the need for xargs-style
argument list handling. The handling in question looks broken in a corner
case with SC_ARG_MAX=4096 and final argument over 96 characters.

Signed-off-by: Scott Lamb <slamb@slamb.org>
Signed-off-by: Simon Hausmann <simon@lst.de>
17 years agogit-p4: use subprocess in p4CmdList
Scott Lamb [Mon, 16 Jul 2007 03:58:10 +0000 (20:58 -0700)]
git-p4: use subprocess in p4CmdList

This allows bidirectional piping - useful for "-x -" to avoid commandline
arguments - and is a step toward bypassing the shell.

Signed-off-by: Scott Lamb <slamb@slamb.org>
Signed-off-by: Simon Hausmann <simon@lst.de>
17 years agogit-gui: Always disable the Tcl EOF character when reading
Shawn O. Pearce [Tue, 17 Jul 2007 05:50:10 +0000 (01:50 -0400)]
git-gui: Always disable the Tcl EOF character when reading

On Windows (which includes Cygwin) Tcl defaults to leaving the EOF
character of input file streams set to the ASCII EOF character, but
if that character were to appear in the data stream then Tcl will
close the channel early.  So we have to disable eofchar on Windows.
Since the default is disabled on all platforms except Windows, we
can just disable it everywhere to prevent any sort of read problem.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agoFix git-branch documentation when using remote refs
Francis Moreau [Mon, 16 Jul 2007 11:38:47 +0000 (13:38 +0200)]
Fix git-branch documentation when using remote refs

Signed-off-by: Francis Moreau <francis.moro@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogit-gui: Brown paper bag "dirty git version fix"
Shawn O. Pearce [Mon, 16 Jul 2007 22:44:23 +0000 (18:44 -0400)]
git-gui: Brown paper bag "dirty git version fix"

My prior change to allow git-gui to run with a version of Git
that was built from a working directory that had uncommitted
changes didn't account for the pattern starting with -, and
that confused Tcl.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-gui: Skip -dirty suffix on core git versions
Shawn O. Pearce [Mon, 16 Jul 2007 06:39:07 +0000 (02:39 -0400)]
git-gui: Skip -dirty suffix on core git versions

If the user is running a 'dirty' version of git (one compiled in a
working directory with modified files) we want to just assume it
was a committed version, as we really only look at the part that
came from a real annotated tag anyway.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-svn: fix commiting renames over DAV with funky file names
Eric Wong [Mon, 16 Jul 2007 04:53:50 +0000 (21:53 -0700)]
git-svn: fix commiting renames over DAV with funky file names

Renaming files with non-URI friendly characters caused
breakage when committing to DAV repositories (over http(s)).

Even if I try leaving out the $self->{url} from the return value
of url_path(), a partial (without host), unescaped path name
does not work.

Filenames for DAV repos need to be URI-encoded before being
passed to the library.  Since this bug did not affect file://
and svn:// repos, the git-svn test library needed to be expanded
to include support for starting Apache with mod_dav_svn enabled.

This new test is not enabled by default, but can be enabled by
setting SVN_HTTPD_PORT to any available TCP/IP port on
127.0.0.1.

Additionally, for running this test, the following variables
(with defaults shown) can be changed for the suitable system.
The default values are set for Debian systems:

  SVN_HTTPD_MODULE_PATH=/usr/lib/apache2/modules
  SVN_HTTPD_PATH=/usr/sbin/apache2

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agocontrib/emacs/Makefile: Also install .el files.
David Kastrup [Sun, 15 Jul 2007 09:46:11 +0000 (11:46 +0200)]
contrib/emacs/Makefile: Also install .el files.

Signed-off-by: David Kastrup <dak@gnu.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoGIT v1.5.3-rc2 v1.5.3-rc2
Junio C Hamano [Sun, 15 Jul 2007 23:41:17 +0000 (16:41 -0700)]
GIT v1.5.3-rc2

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoDemote git-p4import to contrib status.
Sean [Sun, 15 Jul 2007 19:52:32 +0000 (15:52 -0400)]
Demote git-p4import to contrib status.

Move git-p4import.py and Documentation/git-p4import.txt into
a contrib/p4import directory.   Add a README there directing
people to contrib/fast-import/git-p4 as a better alternative.

Signed-off-by: Sean Estabrooks <seanlkml@sympatico.ca>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoRemove p4 rpm from git.spec.in.
Sean [Sun, 15 Jul 2007 19:51:01 +0000 (15:51 -0400)]
Remove p4 rpm from git.spec.in.

Signed-off-by: Sean Estabrooks <seanlkml@sympatico.ca>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoRemove "WITH_P4IMPORT" knob from the Makefile
Sean [Sun, 15 Jul 2007 19:49:33 +0000 (15:49 -0400)]
Remove "WITH_P4IMPORT" knob from the Makefile

Signed-off-by: Sean Estabrooks <seanlkml@sympatico.ca>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogit-cvsserver: detect/diagnose write failure, etc.
Jim Meyering [Sat, 14 Jul 2007 18:48:42 +0000 (20:48 +0200)]
git-cvsserver: detect/diagnose write failure, etc.

There were many operations that did not notice and report errors
to the CVS client, which would have resulted in corrupt working
tree.

Signed-off-by: Jim Meyering <jim@meyering.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoUse $(RM) in Makefiles instead of 'rm -f'
Emil Medve [Sat, 14 Jul 2007 17:51:44 +0000 (12:51 -0500)]
Use $(RM) in Makefiles instead of 'rm -f'

Signed-off-by: Emil Medve <Emilian.Medve@Freescale.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMerge branch 'master' of git://repo.or.cz/git/fastimport
Junio C Hamano [Sun, 15 Jul 2007 05:57:47 +0000 (22:57 -0700)]
Merge branch 'master' of git://repo.or.cz/git/fastimport

* 'master' of git://repo.or.cz/git/fastimport:
  Teach fast-import to recursively copy files/directories
  Fix git-p4 on Windows to not use the Posix sysconf function.
  Correct trivial typo in fast-import documentation

17 years agoDocumentation/git-commit-tree: remove description of a nonexistent limitation
Junio C Hamano [Sun, 15 Jul 2007 05:56:47 +0000 (22:56 -0700)]
Documentation/git-commit-tree: remove description of a nonexistent limitation

Noticed by Geoff Richards.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMake every builtin-*.c file #include "builtin.h"
Peter Hagervall [Sat, 14 Jul 2007 23:14:45 +0000 (01:14 +0200)]
Make every builtin-*.c file #include "builtin.h"

Make every builtin-*.c file #include "builtin.h".

Also takes care of some declaration/definition mismatches.

Signed-off-by: Peter Hagervall <hager@cs.umu.se>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoTeach fast-import to recursively copy files/directories
Shawn O. Pearce [Sun, 15 Jul 2007 05:40:37 +0000 (01:40 -0400)]
Teach fast-import to recursively copy files/directories

Some source material (e.g. Subversion dump files) perform directory
renames by telling us the directory was copied, then deleted in the
same revision.  This makes it difficult for a frontend to convert
such data formats to a fast-import stream, as all the frontend has
on hand is "Copy a/ to b/; Delete a/" with no details about what
files are in a/, unless the frontend also kept track of all files.

The new 'C' subcommand within a commit allows the frontend to make a
recursive copy of one path to another path within the branch, without
needing to keep track of the individual file paths.  The metadata
copy is performed in memory efficiently, but is implemented as a
copy-immediately operation, rather than copy-on-write.

With this new 'C' subcommand frontends could obviously implement an
'R' (rename) on their own as a combination of 'C' and 'D' (delete),
but since we have already offered up 'R' in the past and it is a
trivial thing to keep implemented I'm not going to deprecate it.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agoFix git-p4 on Windows to not use the Posix sysconf function.
Marius Storm-Olsen [Fri, 13 Jul 2007 12:39:05 +0000 (14:39 +0200)]
Fix git-p4 on Windows to not use the Posix sysconf function.

Add condition for Windows, since it doesn't support the os.sysconf module.
We hardcode the commandline limit to 2K, as that should work on most
Windows platforms.

Signed-off-by: Marius Storm-Olsen <marius@trolltech.com>
Acked-by: Simon Hausmann <simon@lst.de>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agogit-svn: remove leading slashes from fetch lines in the generate config
Eric Wong [Sat, 14 Jul 2007 19:40:32 +0000 (12:40 -0700)]
git-svn: remove leading slashes from fetch lines in the generate config

We were previously sensitive to leading slashes in the fetch
lines and incorrectly writing them to the config if the user
used them (needlessly) in the command-line.

This fixes the issue and allows us to play nicely with legacy
configs that have leading slashes in fetch lines.

Thanks to Bradford Smith for figuring this out for me:
>
> This works:
>
> git-svn clone https://my.server.net/repos/path/ -Ttrunk/testing
>   -ttags/testing -bbranches/testing testing
>
> This doesn't:
>
> git-svn clone https://my.server.net/repos/path -T/trunk/testing
>   -t/tags/testing -b/branches/testing testing

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoUpdate .mailmap
Junio C Hamano [Sat, 14 Jul 2007 20:44:58 +0000 (13:44 -0700)]
Update .mailmap

The script "contrib/stats/mailmap.pl" found a few missed ones.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoAdd contrib/stats/mailmap.pl script
Junio C Hamano [Sat, 14 Jul 2007 20:43:09 +0000 (13:43 -0700)]
Add contrib/stats/mailmap.pl script

This script reads the existing commit log and .mailmap file,
and outputs author e-mail addresses that would map to more
than one names (most likely due to difference in the way they
are spelled, but some are due to ancient botched commits).

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoRemove useless uses of cat, and replace with filename arguments
Josh Triplett [Sat, 14 Jul 2007 08:05:43 +0000 (01:05 -0700)]
Remove useless uses of cat, and replace with filename arguments

Replace uses of cat that do nothing but writing the contents of
a single file to another command via pipe.

[jc: Original patch from Josh was somewhat buggy and rewrote
"cat $file | wc -l" to "wc -l $file", but this one should be Ok.]

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMore permissive "git-rm --cached" behavior without -f.
Matthieu Moy [Fri, 13 Jul 2007 17:41:38 +0000 (19:41 +0200)]
More permissive "git-rm --cached" behavior without -f.

In the previous behavior, "git-rm --cached" (without -f) had the same
restriction as "git-rm". This forced the user to use the -f flag in
situations which weren't actually dangerous, like:

$ git add foo           # oops, I didn't want this
$ git rm --cached foo   # back to initial situation

Previously, the index had to match the file *and* the HEAD. With
--cached, the index must now match the file *or* the HEAD. The behavior
without --cached is unchanged, but provides better error messages.

Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoDocument new --date=<format>
Junio C Hamano [Sat, 14 Jul 2007 06:48:03 +0000 (23:48 -0700)]
Document new --date=<format>

Now, git-log family can take full range of internally supported date format
to their --date=<format> argument.  Document it.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoWire new date formats to --date=<format> parser.
Junio C Hamano [Sat, 14 Jul 2007 06:03:37 +0000 (23:03 -0700)]
Wire new date formats to --date=<format> parser.

Now we can use all internally supported date formats with

git log --date=<format>

syntax.  Earlier, we only allowed relative/local/default.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMake show_rfc2822_date() just another date output format.
Junio C Hamano [Sat, 14 Jul 2007 06:14:52 +0000 (23:14 -0700)]
Make show_rfc2822_date() just another date output format.

These days, show_date() takes a date_mode parameter to specify
the output format, and a separate specialized function for dates
in E-mails does not make much sense anymore.

This retires show_rfc2822_date() function and make it just
another date output format.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoSupport output ISO 8601 format dates
Robin Rosenberg [Fri, 13 Jul 2007 23:00:42 +0000 (01:00 +0200)]
Support output ISO 8601 format dates

Support output of full ISO 8601 style dates in e.g. git log
and other places that use interpolation for formatting.

Signed-off-by: Robin Rosenberg <robin.rosenberg@dewire.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/gitk/gitk
Junio C Hamano [Sat, 14 Jul 2007 05:37:42 +0000 (22:37 -0700)]
Merge branch 'master' of git://git.kernel.org/pub/scm/gitk/gitk

* 'master' of git://git.kernel.org/pub/scm/gitk/gitk:
  gitk: Fix bug introduced by previous commit

17 years agoFix git-rebase -i to allow squashing of fast-forwardable commits
Alex Riesen [Thu, 12 Jul 2007 22:30:35 +0000 (00:30 +0200)]
Fix git-rebase -i to allow squashing of fast-forwardable commits

Without this change the commits will be left standalone, with
duplicated commit message.

Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agolockfile.c: schedule remove_lock_file only once.
Sven Verdoolaege [Fri, 13 Jul 2007 14:14:50 +0000 (16:14 +0200)]
lockfile.c: schedule remove_lock_file only once.

Removing a lockfile once should be enough.

Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agosend-email: discard blank around address in extract_valid_address as well.
Stephen Rothwell [Fri, 13 Jul 2007 15:54:06 +0000 (08:54 -0700)]
send-email: discard blank around address in extract_valid_address as well.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogitk: Show changes in index and changes in working directory separately
Paul Mackerras [Fri, 13 Jul 2007 09:49:37 +0000 (19:49 +1000)]
gitk: Show changes in index and changes in working directory separately

This makes gitk show up to two fake commits when there are local changes
in the repository; one to represent the state of the index and one to
represent the state of the working directory.  The commit representing
the working directory is colored red as before; the commit representing
the index state is colored magenta (as being between red and blue in
some sense).

Signed-off-by: Paul Mackerras <paulus@samba.org>
17 years agomake git-send-email.perl handle email addresses with no names when Email::Valid is...
Greg KH [Fri, 13 Jul 2007 04:17:49 +0000 (21:17 -0700)]
make git-send-email.perl handle email addresses with no names when Email::Valid is present

When using git-send-email.perl on a changeset that has:
Cc: <stable@kernel.org>
in the body of the description, and the Email::Valid perl module is
installed on the system, the email address will be deemed "invalid" for
some reason (Email::Valid isn't smart enough to handle this?) and
complain and not send the address the email.

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogitk: Fix bug introduced by previous commit
Paul Mackerras [Fri, 13 Jul 2007 03:45:55 +0000 (13:45 +1000)]
gitk: Fix bug introduced by previous commit

When I added the "--" case to the code scanning the arguments, I missed
the fact that since the switch statement uses -regexp, the "--" case
will match any argument containing "--", e.g. "--all".  This fixes it
by taking out the -regexp (since we don't actually need regular
expression matching) and adjusting the match strings.

A side effect of this is that previously any argument starting with
"-d" would be taken to indicate date mode; now the argument has to be
exactly "-d" if you want date mode.

Signed-off-by: Paul Mackerras <paulus@samba.org>
17 years agoDocument git commit --untracked-files and --verbose
Jakub Narebski [Thu, 12 Jul 2007 23:54:08 +0000 (01:54 +0200)]
Document git commit --untracked-files and --verbose

Documentation based on description of commit 443f8338 which added
'-u'|'--untracked-files' option to git-status, and on git-runstatus(1)
man page.

Note that those options apply also to git-status.

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoDocument long options '--message=<msg>' and '--no-commit'
Jakub Narebski [Thu, 12 Jul 2007 23:54:07 +0000 (01:54 +0200)]
Document long options '--message=<msg>' and '--no-commit'

Document that '--message=<msg>' is long version of '-m <msg>' in
git-commit, and that '--no-checkout' is long version of '-n' in
git-clone.

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoUpdate git-merge documentation.
Jakub Narebski [Thu, 12 Jul 2007 23:54:06 +0000 (01:54 +0200)]
Update git-merge documentation.

Add "Configuration" section to describe merge.summary
configuration variable (which is mentioned in git-fmt-merge-msg(1)
man page, but it is a plumbing command), and merge.verbosity
configuration variable (so there is a place to make reference
from "Environment Variables" section of git(7) man page) to the
git-merge(1) man page.  Also describe GIT_MERGE_VERBOSITY
environment.

The configuration variable merge.verbosity and environment variable
GIT_MERGE_VERBOSITY were introduced in commit 8c3275ab, which also
documented configuration variable but not environment variable.

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoPack-objects: properly initialize the depth value
Nicolas Pitre [Fri, 13 Jul 2007 02:27:12 +0000 (22:27 -0400)]
Pack-objects: properly initialize the depth value

Commit 5a235b5e was missing this little detail.  Otherwise your pack
will explode.

Problem noted by Brian Downing.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoGIT v1.5.3-rc1 v1.5.3-rc1
Junio C Hamano [Thu, 12 Jul 2007 21:54:33 +0000 (14:54 -0700)]
GIT v1.5.3-rc1

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/gitk/gitk
Junio C Hamano [Thu, 12 Jul 2007 21:50:57 +0000 (14:50 -0700)]
Merge branch 'master' of git://git.kernel.org/pub/scm/gitk/gitk

* 'master' of git://git.kernel.org/pub/scm/gitk/gitk:
  gitk: Improve handling of -- and ambiguous arguments
  gitk: Use git log and add support for --left-right
  gitk: Fix bug causing "can't read commitrow(0,n)" error
  [PATCH] gitk: Fix for tree view ending in nested directories
  gitk: Remove the unused stopfindproc function
  gitk: Fix bug in the anc_or_desc routine
  gitk: Fix the find and highlight functions

17 years agogitweb: new cgi parameter: opt
Miklos Vajna [Thu, 12 Jul 2007 18:39:27 +0000 (20:39 +0200)]
gitweb: new cgi parameter: opt

Currently the only supported value is '--no-merges' for the 'rss', 'atom',
'log', 'shortlog' and 'history' actions, but it can be easily extended to allow
other parameters for other actions.

Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoAdd missing functions to contrib/emacs/vc-git.el
David Kastrup [Thu, 12 Jul 2007 14:48:48 +0000 (16:48 +0200)]
Add missing functions to contrib/emacs/vc-git.el

This is necessary to make several editing functions work, like
C-u C-x v =

Signed-off-by: David Kastrup <dak@gnu.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoDocumentation for git-log --follow
Steven Walter [Thu, 12 Jul 2007 14:52:30 +0000 (10:52 -0400)]
Documentation for git-log --follow

After vainly searching the Documentation for how to follow renames, I
finally broke down and grepped the source.  It would appear that Linus
didn't add write and docs for this feature when he wrote it.  The
following patch rectifies that, hopefully sparing future users from
resorting to the source code.

Signed-off-by: Steven Walter <stevenrwalter@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoreduce git-pack-objects memory usage a little more
Nicolas Pitre [Thu, 12 Jul 2007 21:07:59 +0000 (17:07 -0400)]
reduce git-pack-objects memory usage a little more

The delta depth doesn't have to be stored in the global object array
structure since it is only used during the deltification pass.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoAdd documentation for --window-memory, pack.windowMemory
Brian Downing [Thu, 12 Jul 2007 12:55:52 +0000 (07:55 -0500)]
Add documentation for --window-memory, pack.windowMemory

Signed-off-by: Brian Downing <bdowning@lavos.net>
Acked-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoAdd --window-memory option to git-repack
Brian Downing [Thu, 12 Jul 2007 12:55:51 +0000 (07:55 -0500)]
Add --window-memory option to git-repack

Signed-off-by: Brian Downing <bdowning@lavos.net>
Acked-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoAdd pack-objects window memory usage limit
Brian Downing [Thu, 12 Jul 2007 13:07:46 +0000 (08:07 -0500)]
Add pack-objects window memory usage limit

This adds an option (--window-memory=N) and configuration variable
(pack.windowMemory = N) to limit the memory size of the pack-objects
delta search window.  This works by removing the oldest unpacked objects
whenever the total size goes above the limit.  It will always leave
at least one object, though, so as not to completely eliminate the
possibility of computing deltas.

This is an extra limit on top of the normal window size (--window=N);
the window will not dynamically grow above the fixed number of entries
specified to fill the memory limit.

With this, repacking a repository with a mix of large and small objects
is possible even with a very large window.

Cleaner and correct circular buffer handling courtesy of Nicolas Pitre.

Signed-off-by: Brian Downing <bdowning@lavos.net>
Acked-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoAdd functions for parsing integers with size suffixes
Brian Downing [Thu, 12 Jul 2007 13:32:26 +0000 (08:32 -0500)]
Add functions for parsing integers with size suffixes

Split out the nnn{k,m,g} parsing code from git_config_int into
git_parse_long, so command-line parameters can enjoy the same
functionality.  Also add get_parse_ulong for unsigned values.

Make git_config_int use git_parse_long, and add get_config_ulong
as well.

Signed-off-by: Brian Downing <bdowning@lavos.net>
Acked-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoSupport fetching the memory usage of a delta index
Brian Downing [Thu, 12 Jul 2007 12:55:48 +0000 (07:55 -0500)]
Support fetching the memory usage of a delta index

Delta indices, at least on 64-bit platforms, tend to be larger than
the actual uncompressed data.  As such, keeping track of this storage
is important if you want to successfully limit the memory size of your
pack window.

Squirrel away the total allocation size inside the delta_index struct,
and add an accessor "sizeof_delta_index" to access it.

Signed-off-by: Brian Downing <bdowning@lavos.net>
Acked-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoDon't try to delta if target is much smaller than source
Brian Downing [Thu, 12 Jul 2007 12:55:47 +0000 (07:55 -0500)]
Don't try to delta if target is much smaller than source

Add a new try_delta heuristic.  Don't bother trying to make a delta if
the target object size is much smaller (currently 1/32) than the source,
as it's very likely not going to get a match.  Even if it does, you will
have to read at least 32x the size of the new file to reassemble it,
which isn't such a good deal.  This leads to a considerable performance
improvement when deltifying a mix of small and large files with a very
large window, because you don't have to wait for the large files to
percolate out of the window before things start going fast again.

Signed-off-by: Brian Downing <bdowning@lavos.net>
Acked-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoCorrect shebang line for contrib/stats/packinfo.pl
Brian Downing [Thu, 12 Jul 2007 14:16:11 +0000 (09:16 -0500)]
Correct shebang line for contrib/stats/packinfo.pl

"/bin/perl"?  What was I thinking?

Signed-off-by: Brian Downing <bdowning@lavos.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoscript to display a distribution of longest common hash prefixes
Nicolas Pitre [Thu, 12 Jul 2007 07:40:18 +0000 (03:40 -0400)]
script to display a distribution of longest common hash prefixes

This script was originally posted on the git mailing list by
Randal L. Schwartz <merlyn@stonehenge.com>.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoapply delta depth bias to already deltified objects
Nicolas Pitre [Thu, 12 Jul 2007 18:33:21 +0000 (14:33 -0400)]
apply delta depth bias to already deltified objects

We already apply a bias on the initial delta attempt with max_size being
a function of the base object depth.  This has the effect of favoring
shallower deltas even if deeper deltas could be smaller, and therefore
creating a wider delta tree (see commits 4e8da195 and c3b06a69).

This principle should also be applied to all delta attempts for the same
object and not only the first attempt.  With this the criteria for the
best delta is not only its size but also its depth, so that a shallower
delta might be selected even if it is larger than a deeper one.  Even if
some deltas get larger, they allow for wider delta trees making the
depth limit less quickly reached and therefore better deltas can be
subsequently found, keeping the resulting pack size even smaller.
Runtime access to the pack should also benefit from shallower deltas.

Testing on different repositories showed slighter faster repacks,
smaller resulting packs, and a much nicer curve for delta depth
distribution with no more peak at the maximum depth level.
Improvements are even more significant with smaller depth limits.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoUpdate list of older git docs
Junio C Hamano [Thu, 12 Jul 2007 21:17:26 +0000 (14:17 -0700)]
Update list of older git docs

17 years agoMerge commit 'git-gui/master'
Junio C Hamano [Thu, 12 Jul 2007 21:14:51 +0000 (14:14 -0700)]
Merge commit 'git-gui/master'

* commit 'git-gui/master': (36 commits)
  git-gui: Change prior tree SHA-1 verification to use git_read
  git-gui: Include a space in Cygwin shortcut command lines
  git-gui: Use sh.exe in Cygwin shortcuts
  git-gui: Paper bag fix for Cygwin shortcut creation
  git-gui: Improve the Windows and Mac OS X shortcut creators
  git-gui: Teach console widget to use git_read
  git-gui: Perform our own magic shbang detection on Windows
  git-gui: Treat `git version` as `git --version`
  git-gui: Assume unfound commands are known by git wrapper
  git-gui: Correct gitk installation location
  git-gui: Always use absolute path to all git executables
  git-gui: Show a progress meter for checking out files
  git-gui: Change the main window progress bar to use status_bar
  git-gui: Extract blame viewer status bar into mega-widget
  git-gui: Allow double-click in checkout dialog to start checkout
  git-gui: Default selection to first matching ref
  git-gui: Unabbreviate commit SHA-1s prior to display
  git-gui: Refactor branch switch to support detached head
  git-gui: Refactor our ui_status_value update technique
  git-gui: Better handling of detached HEAD
  ...

17 years agoMerge branch 'maint'
Junio C Hamano [Thu, 12 Jul 2007 21:12:38 +0000 (14:12 -0700)]
Merge branch 'maint'

* maint:
  GIT 1.5.2.4
  Teach read-tree 2-way merge to ignore intermediate symlinks
  git-gui: Work around bad interaction between Tcl and cmd.exe on ^{tree}
  git-gui: Don't linewrap within console windows
  git-gui: Correct ls-tree buffering problem in browser
  git-gui: Skip nicknames when selecting author initials
  git-gui: Ensure windows shortcuts always have .bat extension
  git-gui: Include a Push action on the left toolbar
  git-gui: Bind M1-P to push action
  git-gui: Don't bind F5/M1-R in all windows
  git-gui: Unlock the index when cancelling merge dialog
  git-gui: properly popup error if gitk should be started but is not installed

17 years agoGIT 1.5.2.4 v1.5.2.4
Junio C Hamano [Thu, 12 Jul 2007 19:01:47 +0000 (12:01 -0700)]
GIT 1.5.2.4

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agogitk: Improve handling of -- and ambiguous arguments
Paul Mackerras [Thu, 12 Jul 2007 12:29:49 +0000 (22:29 +1000)]
gitk: Improve handling of -- and ambiguous arguments

This makes gitk more consistent with git rev-list and git log in its
handling of arguments that could be either a revision or a filename;
now gitk displays an error message and quits, rather than treating it
as a revision and getting an error in the underlying git log.  Now
gitk always passes "--" to git log even if no filenames are being
specified.

It also makes gitk display errors in invoking git log in a window
rather than on stderr, and makes gitk stop looking for a -d flag
when it sees a "--" argument.

Signed-off-by: Paul Mackerras <paulus@samba.org>
17 years agoTeach read-tree 2-way merge to ignore intermediate symlinks
Junio C Hamano [Thu, 12 Jul 2007 08:04:16 +0000 (01:04 -0700)]
Teach read-tree 2-way merge to ignore intermediate symlinks

Earlier in 16a4c61, we taught "read-tree -m -u" not to be
confused when switching from a branch that has a path frotz/filfre
to another branch that has a symlink frotz that points at xyzzy/
directory.  The fix was incomplete in that it was still confused
when coming back (i.e. switching from a branch with frotz -> xyzzy/
to another branch with frotz/filfre).

This fix is rather expensive in that for a path that is created
we would need to see if any of the leading component of that
path exists as a symbolic link in the filesystem (in which case,
we know that path itself does not exist, and the fact we already
decided to check it out tells us that in the index we already
know that symbolic link is going away as there is no D/F
conflict).

Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 years agoMerge branch 'maint' of git://repo.or.cz/git-gui into maint
Junio C Hamano [Thu, 12 Jul 2007 08:45:56 +0000 (01:45 -0700)]
Merge branch 'maint' of git://repo.or.cz/git-gui into maint

* 'maint' of git://repo.or.cz/git-gui:
  git-gui: Work around bad interaction between Tcl and cmd.exe on ^{tree}
  git-gui: Don't linewrap within console windows
  git-gui: Correct ls-tree buffering problem in browser
  git-gui: Skip nicknames when selecting author initials
  git-gui: Ensure windows shortcuts always have .bat extension
  git-gui: Include a Push action on the left toolbar
  git-gui: Bind M1-P to push action
  git-gui: Don't bind F5/M1-R in all windows
  git-gui: Unlock the index when cancelling merge dialog
  git-gui: properly popup error if gitk should be started but is not installed

17 years agogit-gui: Change prior tree SHA-1 verification to use git_read
Shawn O. Pearce [Thu, 12 Jul 2007 06:45:23 +0000 (02:45 -0400)]
git-gui: Change prior tree SHA-1 verification to use git_read

This cat-file was done on maint, where we did not have git_read
available to us.  But here on master we do, so we should make
use of it.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
17 years agoMerge branch 'maint'
Shawn O. Pearce [Thu, 12 Jul 2007 06:40:54 +0000 (02:40 -0400)]
Merge branch 'maint'

* maint:
  git-gui: Work around bad interaction between Tcl and cmd.exe on ^{tree}