Code

git.git
19 years agoGIT v0.99.7d v0.99.7d
Junio C Hamano [Sun, 25 Sep 2005 07:36:26 +0000 (00:36 -0700)]
GIT v0.99.7d

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoMerge branch 'fixes'
Junio C Hamano [Sun, 25 Sep 2005 07:32:06 +0000 (00:32 -0700)]
Merge branch 'fixes'

19 years agoshow-branch: fix commit naming breakage.
Junio C Hamano [Sun, 25 Sep 2005 06:33:02 +0000 (23:33 -0700)]
show-branch: fix commit naming breakage.

It was ignoring the generation number of the commit when naming 2nd
and later parents, showing "(linus^n)^2" for any <n> incorrectly as
"linus^2".

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agogit-grep: fix 'git grep -e $pattern' handling
Junio C Hamano [Sat, 24 Sep 2005 22:09:48 +0000 (15:09 -0700)]
git-grep: fix 'git grep -e $pattern' handling

People typically say 'grep -e $pattern' because $pattern has a leading
dash which would be mistaken as a grep flag.  Make sure we pass -e in
front of $pattern when we invoke grep.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoGIT 0.99.7c v0.99.7c
Junio C Hamano [Sat, 24 Sep 2005 18:38:43 +0000 (11:38 -0700)]
GIT 0.99.7c

Contains the following post-0.99.7b fixes:

 - rsh.c string termination fix by H. Peter Anvin
 - further fetch fixes by Sergey Vlasov
 - diff-tree documentation by Robert Watson.
 - 'git diff --cached' synonymous to 'git diff --cached HEAD'.
 - subprocess.py licensing status clarification.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoReally ignore generated distribution material.
Junio C Hamano [Sat, 24 Sep 2005 18:19:07 +0000 (11:19 -0700)]
Really ignore generated distribution material.
Signed-off-by: Junio C Hamano <junkio@cox.net>
(cherry picked from e558e33b7bdb4a7c633bedd1606f7dd7ef912933 commit)

19 years agoMerge 'fixes' branch
Junio C Hamano [Sat, 24 Sep 2005 01:51:02 +0000 (18:51 -0700)]
Merge 'fixes' branch
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoFurther clarify licensing status of compat/subprocess.py.
Junio C Hamano [Sat, 24 Sep 2005 01:43:53 +0000 (18:43 -0700)]
Further clarify licensing status of compat/subprocess.py.

PSF license explicitly states the files in Python distribution is
compatible with GPL, and upstream clarified the licensing terms by
shortening its file header.  This version is a verbatim copy from
release24-maint branch form Python CVS.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] rsh.c unterminated string
H. Peter Anvin [Fri, 23 Sep 2005 23:30:50 +0000 (16:30 -0700)]
[PATCH] rsh.c unterminated string

The change I made to rsh.c would leave the string unterminated under
certain conditions, which unfortunately always applied!  This patch
fixes this.  For some reason this never bit on i386 or ppc, but bit me
on x86-64.

Fix situation where the buffer was not properly null-terminated.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] git-local-fetch: Avoid confusing error messages on packed repositories
Sergey Vlasov [Fri, 23 Sep 2005 12:28:38 +0000 (16:28 +0400)]
[PATCH] git-local-fetch: Avoid confusing error messages on packed repositories

If the source repository was packed, and git-local-fetch needed to
fetch a pack file, it spewed a misleading error message about not
being able to find the unpacked object.  Fixed by adding the
warn_if_not_exists argument to copy_file(), which controls printing
of error messages in case the source file does not exist.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Fix "git-local-fetch -s" with packed source repository
Sergey Vlasov [Fri, 23 Sep 2005 12:28:33 +0000 (16:28 +0400)]
[PATCH] Fix "git-local-fetch -s" with packed source repository

"git-local-fetch -s" did not work with a packed repository, because
symlink() happily created a link to a non-existing object file,
therefore fetch_file() always returned success, and fetch_pack() was
not called.  Fixed by calling stat() before symlink() to ensure the
file really exists.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] git-local-fetch: Avoid calling close(-1)
Sergey Vlasov [Fri, 23 Sep 2005 12:28:28 +0000 (16:28 +0400)]
[PATCH] git-local-fetch: Avoid calling close(-1)

After open() failure, copy_file() called close(ifd) with ifd == -1
(harmless, but causes Valgrind noise).  The same thing was possible
for the destination file descriptor.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] git-local-fetch: Fix error checking and leak in setup_indices()
Sergey Vlasov [Fri, 23 Sep 2005 12:28:23 +0000 (16:28 +0400)]
[PATCH] git-local-fetch: Fix error checking and leak in setup_indices()

setup_indices() did not check the return value of opendir(), and
did not have a corresponding closedir() call.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Plug memory leak in process_tree()
Sergey Vlasov [Fri, 23 Sep 2005 12:28:18 +0000 (16:28 +0400)]
[PATCH] fetch.c: Plug memory leak in process_tree()

When freeing a tree entry, must free its name too.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Do not build object ref lists
Sergey Vlasov [Fri, 23 Sep 2005 12:28:13 +0000 (16:28 +0400)]
[PATCH] fetch.c: Do not build object ref lists

The fetch code does not need object ref lists; by disabling them we
can save some time and memory.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] document command to show diff of a commit
Robert Watson [Fri, 23 Sep 2005 10:06:04 +0000 (11:06 +0100)]
[PATCH] document command to show diff of a commit

Document the best way to show the change introduced by a
commit, based on the suggestion by Linus on the list.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoIgnore a bit more generated files.
Junio C Hamano [Fri, 23 Sep 2005 21:02:57 +0000 (14:02 -0700)]
Ignore a bit more generated files.
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoMake 'git diff --cached' synonymous to 'git diff --cached HEAD'.
Junio C Hamano [Fri, 23 Sep 2005 07:53:02 +0000 (00:53 -0700)]
Make 'git diff --cached' synonymous to 'git diff --cached HEAD'.

When making changes to different files (i.e. dirty working tree) and
committing logically separate changes in groups, often it is necessary
to run 'git diff --cached HEAD' to make sure that the changes being
committed makes sense.  Saying 'git diff --cached' by mistake gives
rather uninformative error message from git-diff-files complaining it
does not understand --cached flag.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoGIT 0.99.7b v0.99.7b
Junio C Hamano [Fri, 23 Sep 2005 04:53:33 +0000 (21:53 -0700)]
GIT 0.99.7b
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoMerge branch 'fixes'
Junio C Hamano [Fri, 23 Sep 2005 04:52:34 +0000 (21:52 -0700)]
Merge branch 'fixes'

19 years ago[PATCH] fetch.c: Remove call to parse_object() from process()
Sergey Vlasov [Wed, 21 Sep 2005 16:34:29 +0000 (20:34 +0400)]
[PATCH] fetch.c: Remove call to parse_object() from process()

The call to parse_object() in process() is not actually needed - if
the object type is unknown, parse_object() will be called by loop();
if the type is known, the object will be parsed by the appropriate
process_*() function.

After this change blobs which exist locally are no longer parsed,
which gives about 2x CPU usage improvement; the downside is that there
will be no warnings for existing corrupted blobs, but detecting such
corruption is the job of git-fsck-objects, not the fetch programs.
Newly fetched objects are still checked for corruption in http-fetch.c
and ssh-fetch.c (local-fetch.c does not seem to do it, but the removed
parse_object() call would not be reached for new objects anyway).

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Clean up object flag definitions
Sergey Vlasov [Wed, 21 Sep 2005 16:34:24 +0000 (20:34 +0400)]
[PATCH] fetch.c: Clean up object flag definitions

Remove holes left after deleting flags, and use shifts to emphasize
that flags are single bits.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Remove redundant test of TO_SCAN in process()
Sergey Vlasov [Wed, 21 Sep 2005 16:34:19 +0000 (20:34 +0400)]
[PATCH] fetch.c: Remove redundant test of TO_SCAN in process()

If the SEEN flag was not set, the TO_SCAN flag cannot be set,
therefore testing it is pointless.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Remove some duplicated code in process()
Sergey Vlasov [Wed, 21 Sep 2005 16:34:14 +0000 (20:34 +0400)]
[PATCH] fetch.c: Remove some duplicated code in process()

It does not matter if we call prefetch() or set the TO_SCAN flag before
or after adding the object to process_queue.  However, doing it before
object_list_insert() allows us to kill 3 lines of duplicated code.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Remove redundant TO_FETCH flag
Sergey Vlasov [Wed, 21 Sep 2005 16:34:09 +0000 (20:34 +0400)]
[PATCH] fetch.c: Remove redundant TO_FETCH flag

The TO_FETCH flag also became redundant after adding the SEEN flag -
it was set and checked in process() to prevent adding the same object
to process_queue multiple times, but now SEEN guards against this.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Remove redundant SCANNED flag
Sergey Vlasov [Wed, 21 Sep 2005 16:34:04 +0000 (20:34 +0400)]
[PATCH] fetch.c: Remove redundant SCANNED flag

After adding the SEEN flag, the SCANNED flag became obviously
redundant - each object can get into process_queue through process()
only once, and therefore multiple calls to process_object() for the
same object are not possible.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Make process() look at each object only once
Sergey Vlasov [Wed, 21 Sep 2005 16:33:59 +0000 (20:33 +0400)]
[PATCH] fetch.c: Make process() look at each object only once

The process() function is very often called multiple times for the
same object (because lots of trees refer to the same blobs), but did
not have a fast check for this, therefore a lot of useless calls to
has_sha1_file() and parse_object() were made before discovering that
nothing needs to be done.

This patch adds the SEEN flag which is used in process() to make it
look at each object only once.  When testing git-local-fetch on the
repository of GIT, this gives a 14x improvement in CPU usage (mainly
because the redundant calls to parse_object() are now avoided -
parse_object() always unpacks and parses the object data, even if it
was already parsed before).

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: Remove useless lookup_object_type() call in process()
Sergey Vlasov [Wed, 21 Sep 2005 16:33:54 +0000 (20:33 +0400)]
[PATCH] fetch.c: Remove useless lookup_object_type() call in process()

In all places where process() is called except the one in pull() (which
is executed only once) the pointer to the object is already available,
so pass it as the argument to process() instead of sha1 and avoid an
unneeded call to lookup_object_type().

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoDo not give alarming error message from rsync in fetch and clone.
Junio C Hamano [Tue, 20 Sep 2005 06:52:33 +0000 (23:52 -0700)]
Do not give alarming error message from rsync in fetch and clone.

When we check the optional objects/info/alternates file at the remote
repository, we forgot to really squelch error message from rsync.

Not having that file is not a crime.

Signed-off-by: Junio C Hamano <junkio@cox.net>
(cherry picked from 89d844d084f14bc9506f63cd3c9aa44b21b49067 commit)

19 years agoFix documentation dependency.
Junio C Hamano [Wed, 21 Sep 2005 19:29:59 +0000 (12:29 -0700)]
Fix documentation dependency.

Randal L. Schwartz noticed that 'make install' does not rebuild what
is installed.  Make the 'install' rule depend on 'man'.

I noticed also 'touch' of the source files were used to express include
dependencies, which is a no-no.  Rewrite it to do dependencies properly,
and add missing include dependencies while we are at it.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoMake object creation in http fetch a bit safer.
Junio C Hamano [Wed, 21 Sep 2005 09:46:32 +0000 (02:46 -0700)]
Make object creation in http fetch a bit safer.

Unlike write_sha1_file() that tries to create the object file in a
temporary location and then move it to the final location, fetch_object
could have been interrupted in the middle, leaving a corrupt file.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoClarify dual license status of subprocess.py file. v0.99.7a
Junio C Hamano [Wed, 21 Sep 2005 07:58:32 +0000 (00:58 -0700)]
Clarify dual license status of subprocess.py file.

The author of the file we stole from Python 2.4 distribution, Peter
Astrand <astrand@lysator.liu.se>, OK'ed to add this at the end of the
licensing terms section of the file:

    Use of this file within git is permitted under GPLv2.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoMerge branch 'fixes'
Junio C Hamano [Wed, 21 Sep 2005 07:45:25 +0000 (00:45 -0700)]
Merge branch 'fixes'

19 years agoFix extended short SHA1 name completion
Linus Torvalds [Mon, 19 Sep 2005 22:16:03 +0000 (15:16 -0700)]
Fix extended short SHA1 name completion

get_sha1() would not do sha1 completion of short SHA1's when they were
part of a more complex expression.  So doing

git-rev-parse 727132834e6be48a93c1bd6458a29d474ce7d5d5^

would work, and return 87c6aeb4efdd4355918d127a91bd0adc5a02f8ff. But using
the shorthand version

git-rev-list 72713^

wouldn't work.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoGIT 0.99.7a
Junio C Hamano [Tue, 20 Sep 2005 02:50:09 +0000 (19:50 -0700)]
GIT 0.99.7a
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoShip our own copy of subprocess.py
Junio C Hamano [Tue, 20 Sep 2005 02:47:54 +0000 (19:47 -0700)]
Ship our own copy of subprocess.py

so people without the latest Python could run merge-recursive.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoshow-branch: Be nicer when running in a corrupt repository.
Junio C Hamano [Mon, 19 Sep 2005 08:12:18 +0000 (01:12 -0700)]
show-branch: Be nicer when running in a corrupt repository.

We may end up trying to print a commit we do not actually have but we
know about its existence only because another commit we do have refers
to it.

Signed-off-by: Junio C Hamano <junkio@cox.net>
(cherry picked from b204feab9371040982d2c60611925e7693106c84 commit)

19 years ago[PATCH] Fix git-init-db creating crap directories.
Petr Baudis [Tue, 20 Sep 2005 00:19:50 +0000 (02:19 +0200)]
[PATCH] Fix git-init-db creating crap directories.

The base target directory for the templates copying was initialized
to git_dir, but git_dir[len] is not zero but / at the time we do the
initialization. This is not what we want for our target directory string
since we pass it to mkdir(), so make it zero-terminated manually.

Signed-off-by: Petr Baudis <pasky@suse.cz>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Do not install compatibility symlink for what we do not install
Patrick Mauritz [Mon, 19 Sep 2005 14:11:19 +0000 (16:11 +0200)]
[PATCH] Do not install compatibility symlink for what we do not install

We sometimes do not install git-send-email nor git-http-pull; do not
unconditionally create symlinks to them.

Signed-off-by: Patrick Mauritz <oxygene@studentenbude.ath.cx>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Remove total confusion from "git checkout"
Linus Torvalds [Mon, 19 Sep 2005 17:11:18 +0000 (10:11 -0700)]
[PATCH] Remove total confusion from "git checkout"

The target to check out does not need to be a branch. The _result_ of the
checkout needs to be a branch. Don't confuse the two, and then insult the
user.

Insulting is ok, but I personally get really pissed off is a tool is both
confused and insulting. At least be _correct_ and insulting.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] strcasestr compatibility replacement
Linus Torvalds [Mon, 19 Sep 2005 01:30:50 +0000 (18:30 -0700)]
[PATCH] strcasestr compatibility replacement

Some C libraries lack strcasestr(); add a stupid replacement
to help folks with such.

[jc: original Linus posting, updated with his "also need <ctype.h>",
 updated further with a fix from Joachim B Haga <cjhaga@fys.uio.no>"]

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoGIT 0.99.7 v0.99.7
Junio C Hamano [Sun, 18 Sep 2005 22:45:59 +0000 (15:45 -0700)]
GIT 0.99.7

19 years agoArrgh -- another asciidoc caret workaround.
Junio C Hamano [Sun, 18 Sep 2005 22:45:09 +0000 (15:45 -0700)]
Arrgh -- another asciidoc caret workaround.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Improve git-update-index error reporting
Petr Baudis [Sun, 18 Sep 2005 19:09:22 +0000 (21:09 +0200)]
[PATCH] Improve git-update-index error reporting

This makes git-update-index error reporting much less confusing. The
user will know what went wrong with better precision, and will be given
a hopefully less confusing advice.

Signed-off-by: Petr Baudis <pasky@suse.cz>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Improved "git add"
Linus Torvalds [Sun, 18 Sep 2005 18:27:45 +0000 (11:27 -0700)]
[PATCH] Improved "git add"

This fixes everybodys favourite complaint about "git add", namely that it
doesn't take directories.

We use "git-ls-files --others" to generate an arbitrary list of filenames,
and thus also automatically honor ignore-files while we're at it.

Side note: there's a lot of room for improvement here. In particular, if
we have a long list of filenames (importing a big archive), this will just
do a big stupid for-loop and add them one at a time. Maybe it should use

generate-list | xargs -0 git-update-idex --add --

instead.

Also, I think we should have a default ignore list if we don't find a
.git/info/exclude file. Ignoring "*.o" and ".*" by default would probably
be the right thing to do.

But I think this is a good first step.

Use the "-n" flag to just show the list of files to be added without
adding them.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Add "--git-dir" flag to git-rev-parse
Linus Torvalds [Sun, 18 Sep 2005 18:18:30 +0000 (11:18 -0700)]
[PATCH] Add "--git-dir" flag to git-rev-parse

Especially when you're deep inside the git repository, it's not all that
trivial for scripts to figure out where GIT_DIR is if it isn't set.

So add a flag to git-rev-parse to show where it is, since it will have
figured it out anyway.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Support alternates and http-alternates in http-fetch
Daniel Barkalow [Sun, 18 Sep 2005 18:14:19 +0000 (14:14 -0400)]
[PATCH] Support alternates and http-alternates in http-fetch

This allows the remote repository to refer to additional repositories
in a file objects/info/http-alternates or
objects/info/alternates. Each line may be:

 a relative path, starting with ../, to get from the objects directory
  of the starting repository to the objects directory of the added
  repository.

 an absolute path of the objects directory of the added repository (on
  the same server).

 (only in http-alternates) a full URL of the objects directory of the
  added repository.

Signed-off-by: Daniel Barkalow <barkalow@iabervon.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoDocument extended SHA1 used by git-rev-parse.
Junio C Hamano [Sun, 18 Sep 2005 18:13:58 +0000 (11:13 -0700)]
Document extended SHA1 used by git-rev-parse.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agofetch() assumes we do not have the object.
Junio C Hamano [Sun, 18 Sep 2005 21:11:53 +0000 (14:11 -0700)]
fetch() assumes we do not have the object.

Bugfix for the previous one.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoMerge branch 'master' of .
Junio C Hamano [Sun, 18 Sep 2005 08:18:15 +0000 (01:18 -0700)]
Merge branch 'master' of .

19 years agoImprove the safety check used in fetch.c
Junio C Hamano [Sun, 18 Sep 2005 08:01:07 +0000 (01:01 -0700)]
Improve the safety check used in fetch.c

The recent safety check to trust only the commits we have made
things impossibly slow and turn out to waste a lot of memory.

This commit fixes it with the following improvements:

 - mark already scanned objects and avoid rescanning the same
   object again;

 - free the tree entries when we have scanned the tree entries;
   this is the same as b0d8923ec01fd91b75ab079034f89ced91500157
   which reduced memory usage by rev-list;

 - plug memory leak from the object_list dequeuing code;

 - use the process_queue not just for fetching but for scanning,
   to make things tail recursive to avoid deep recursion; the
   deep recursion was especially prominent when we cloned a big
   pack.

 - avoid has_sha1_file() call when we already know we do not have
   that object.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoArchive-destroying "git repack -a -d" bug.
Junio C Hamano [Sun, 18 Sep 2005 06:35:49 +0000 (23:35 -0700)]
Archive-destroying "git repack -a -d" bug.

Using "git repack -a -d" can destroy your git archive if you use it
twice in succession, because the new pack can be called the same as
the old pack.  Found by Linus.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoDo not fail after calling bisect_auto_next()
Junio C Hamano [Sat, 17 Sep 2005 20:51:03 +0000 (13:51 -0700)]
Do not fail after calling bisect_auto_next()

As a convenience measure, 'bisect bad' or 'bisect good' automatically
does 'bisect next' when it knows it can, but the result of that test
to see if it can was leaking through as the exit code from the whole
thing, which was bad.  Noticed by Anton Blanchard.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Add support for alternates in HTTP
Daniel Barkalow [Thu, 15 Sep 2005 03:26:08 +0000 (23:26 -0400)]
[PATCH] Add support for alternates in HTTP

This tries .../objects/info/http-alternates and then
.../objects/info/alternates, looking for a file which specifies where
else to download objects and packs from.

It currently only supports absolute paths, and doesn't support full URLs.

Signed-off-by: Daniel Barkalow <barkalow@iabervon.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoFix typo in test comment.
Junio C Hamano [Sat, 17 Sep 2005 06:27:52 +0000 (23:27 -0700)]
Fix typo in test comment.

I do not know why it was spelled git-rev-tree when I meant to say
git-read-tree, but the typo was left since day one.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] getdomainname should be usable on SunOS with -lnsl
Junio C Hamano [Mon, 12 Sep 2005 05:25:49 +0000 (22:25 -0700)]
[PATCH] getdomainname should be usable on SunOS with -lnsl

Jason Riedy suggests that we should be able to use getdomainname
if we properly specify which libraries to link.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Make "git shortlog" understand raw logs
Linus Torvalds [Sat, 17 Sep 2005 01:02:46 +0000 (18:02 -0700)]
[PATCH] Make "git shortlog" understand raw logs

This is a nicer fix for git-shortlog being unable to handle the raw log
format. Just use a more permissive regexp instead of doing two nearly
identical ones.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Fix "git-rev-list" revision range parsing
Linus Torvalds [Sat, 17 Sep 2005 00:53:19 +0000 (17:53 -0700)]
[PATCH] Fix "git-rev-list" revision range parsing

There were two bugs in there:
 - if the range didn't end up working, we restored the '.' character in
   the wrong place.
 - an empty end-of-range should be interpreted as HEAD.

See rev-parse.c for the reference implementation of this.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoAdd git-send-email to .gitignore
Junio C Hamano [Sat, 17 Sep 2005 03:40:12 +0000 (20:40 -0700)]
Add git-send-email to .gitignore

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoTeach rsync transport about alternates.
Junio C Hamano [Sat, 17 Sep 2005 18:56:41 +0000 (11:56 -0700)]
Teach rsync transport about alternates.

For local operations and downloading and uploading via git aware protocols,
use of $GIT_OBJECT_DIRECTORY/info/alternates is recommended on the server
side for big projects that are derived from another one (like Linux kernel).

However, dumb protocols and rsync transport needs to resolve this on the
client end, which we did not bother doing until this week.

I noticed we use "rsync -z" but most of our payload is already compressed,
which was not quite right.  This commit also fixes it.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Avoid building object ref lists when not needed
Linus Torvalds [Fri, 16 Sep 2005 21:55:33 +0000 (14:55 -0700)]
[PATCH] Avoid building object ref lists when not needed

The object parsing code builds a generic "this object references that
object" because doing a full connectivity check for fsck requires it.

However, nothing else really needs it, and it's quite expensive for
git-rev-list that can have tons of objects in flight.

So, exactly like the commit buffer save thing, add a global flag to
disable it, and use it in git-rev-list.

Before:

$ /usr/bin/time git-rev-list --objects v2.6.12..HEAD | wc -l
12.28user 0.29system 0:12.57elapsed 99%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+26718minor)pagefaults 0swaps
59124

After this change:

$ /usr/bin/time git-rev-list --objects v2.6.12..HEAD | wc -l
10.33user 0.18system 0:10.54elapsed 99%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+18509minor)pagefaults 0swaps
59124

and note how the number of pages touched by git-rev-list for this
particular object list has shrunk from 26,718 (104 MB) to 18,509 (72 MB).

Calculating the total object difference between two git revisions is still
clearly the most expensive git operation (both in memory and CPU time),
but it's now less than 40% of what it used to be.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Improve git-rev-list memory usage further
Linus Torvalds [Fri, 16 Sep 2005 21:32:48 +0000 (14:32 -0700)]
[PATCH] Improve git-rev-list memory usage further

This avoids keeping tree entries around, and free's them as it traverses
the list. This avoids building up a huge memory footprint just for these
small but very common allocations.

Before:

$ /usr/bin/time git-rev-list --objects v2.6.12..HEAD | wc -l
11.65user 0.38system 0:12.65elapsed 95%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+42934minor)pagefaults 0swaps
59124

After:

$ /usr/bin/time git-rev-list --objects v2.6.12..HEAD | wc -l
12.28user 0.29system 0:12.57elapsed 99%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+26718minor)pagefaults 0swaps
59124

Note how the minor fault numbers - which ends up being how many pages we
needed to map - go down from 42934 (167 MB) to 26718 (104 MB).  That is:

Before:
42934 minor pagefaults

After:

26718 minor pagefaults

This is all in _addition_ to the previous fixes.  It used to be
~48,000 pagefaults.

That's still a honking big memory footprint, but it's about half of what
it was just a day or two ago (and this is the object list for a pretty big
update - almost 60,000 objects. Smaller updates need less memory).

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] fetch.c: cleanups
Junio C Hamano [Fri, 16 Sep 2005 21:30:29 +0000 (14:30 -0700)]
[PATCH] fetch.c: cleanups

Clean-ups suggested by Sergey Vlasov and acked by Daniel Barkalow.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Debian: build-depend on "bc"
Matthias Urlichs [Fri, 16 Sep 2005 11:54:10 +0000 (13:54 +0200)]
[PATCH] Debian: build-depend on "bc"

Build systems should run tests. This patch adds the necessary
debian/control and debian/rules bits ("bc" was missing,
t/t4002-diff-basic.sh wants it).

Signed-off-by: Matthias Urlichs <smurf@smurf.noris.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Make git-checkout failure message more friendly.
Junio C Hamano [Fri, 16 Sep 2005 19:30:46 +0000 (12:30 -0700)]
[PATCH] Make git-checkout failure message more friendly.

... or less so, perhaps ;-).  Suggested by Jeff Garzik.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Update git-core.spec.in
Chris Wright [Fri, 16 Sep 2005 20:38:49 +0000 (13:38 -0700)]
[PATCH] Update git-core.spec.in

Update git-core spec file based on feedback from Fedora Extras review.

- update BuildRoot to be more specific
- eliminate Requires that must be satisfied for base system install
- drop Vendor
- use dist tag to differentiate between branches
- own %{_datadir}/git-core/
- use RPM_OPT_FLAGS in spec file

Signed-off-by: Chris Wright <chrisw@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] PATCH Documentation/git-rev-list.txt typo fix
Peter Hagervall [Fri, 16 Sep 2005 14:24:12 +0000 (16:24 +0200)]
[PATCH] PATCH Documentation/git-rev-list.txt typo fix

An earlier commit causes a mismatch in <emphasis> and <superscript>
tags, one way of fixing it is having no more than one caret symbol per
line, which is the only solution I found in the asciidoc
documentation. Ugly, but it works.

[jc: ugly indeed but that is not Peter's fault.]

Signed-off-by: Peter Hagervall <hager@cs.umu.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoRecommend 'less' for Debian.
Junio C Hamano [Fri, 16 Sep 2005 06:33:03 +0000 (23:33 -0700)]
Recommend 'less' for Debian.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Require less in RPM spec
Horst von Brand [Fri, 16 Sep 2005 04:08:24 +0000 (00:08 -0400)]
[PATCH] Require less in RPM spec

... and the next one will be the one to do Debian, naturally.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoRevert breakage introduced by c80522e30fdc190f8c8c7fc983bbe040a1b03e93.
Junio C Hamano [Fri, 16 Sep 2005 00:38:26 +0000 (17:38 -0700)]
Revert breakage introduced by c80522e30fdc190f8c8c7fc983bbe040a1b03e93.
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Documentation/git-rev-list.txt typo fix
jdl@freescale.com [Thu, 15 Sep 2005 22:40:13 +0000 (17:40 -0500)]
[PATCH] Documentation/git-rev-list.txt typo fix

Fix the "superscript" problem on the git-rev-list doc page.

Signed-off-by: Jon Loeliger <jdl@freescale.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Re-organize "git-rev-list --objects" logic
Linus Torvalds [Thu, 15 Sep 2005 22:14:29 +0000 (15:14 -0700)]
[PATCH] Re-organize "git-rev-list --objects" logic

The logic to calculate the full object list used to be very inter-twined
with the logic that looked up the commits.

For no good reason - it's actually a lot simpler to just do that logic
as a separate pass.

This improves performance a bit, and uses slightly less memory in my
tests, but more importantly it makes the code simpler to work with and
follow what it does.

The performance win is less than I had hoped for, but I get:

Before:

[torvalds@g5 linux]$ /usr/bin/time git-rev-list --objects v2.6.12..HEAD | wc -l
13.64user 0.42system 0:14.13elapsed 99%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+47947minor)pagefaults 0swaps
58945

After:

[torvalds@g5 linux]$ /usr/bin/time git-rev-list --objects v2.6.12..HEAD | wc -l
11.80user 0.36system 0:12.16elapsed 99%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+42684minor)pagefaults 0swaps
58945

ie it improved by 2 seconds, and took a 5000+ fewer pages (hey, that's
20MB out of 174MB to go). And got the same number of objects (in theory,
the more expensive one might find some more shared objects to avoid. In
practice it obviously doesn't).

I know how to make it use _lots_ less memory, which will probably speed it
up. But that's for another time, and I'd prefer to see this go in first.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoPlug diff leaks.
Junio C Hamano [Thu, 15 Sep 2005 23:13:43 +0000 (16:13 -0700)]
Plug diff leaks.

It is a bit embarrassing that it took this long for a fix since the
problem was first reported on Aug 13th.

    Message-ID: <87y876gl1r.wl@mail2.atmark-techno.com>
    From: Yasushi SHOJI <yashi@atmark-techno.com>
    Newsgroups: gmane.comp.version-control.git
    Subject: [patch] possible memory leak in diff.c::diff_free_filepair()
    Date: Sat, 13 Aug 2005 19:58:56 +0900

This time I used valgrind to make sure that it does not overeagerly
discard memory that is still being used.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoAvoid wasting memory while keeping track of what we have during fetch.
Junio C Hamano [Thu, 15 Sep 2005 22:06:39 +0000 (15:06 -0700)]
Avoid wasting memory while keeping track of what we have during fetch.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Avoid wasting memory in git-rev-list
Linus Torvalds [Thu, 15 Sep 2005 21:43:17 +0000 (14:43 -0700)]
[PATCH] Avoid wasting memory in git-rev-list

As pointed out on the list, git-rev-list can use a lot of memory.

One low-hanging fruit is to free the commit buffer for commits that we
parse. By default, parse_commit() will save away the buffer, since a lot
of cases do want it, and re-reading it continually would be unnecessary.
However, in many cases the buffer isn't actually necessary and saving it
just wastes memory.

We could just free the buffer ourselves, but especially in git-rev-list,
we actually end up using the helper functions that automatically add
parent commits to the commit lists, so we don't actually control the
commit parsing directly.

Instead, just make this behaviour of "parse_commit()" a global flag.
Maybe this is a bit tasteless, but it's very simple, and it makes a
noticable difference in memory usage.

Before the change:

[torvalds@g5 linux]$ /usr/bin/time git-rev-list v2.6.12..HEAD > /dev/null
0.26user 0.02system 0:00.28elapsed 99%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+3714minor)pagefaults 0swaps

after the change:

[torvalds@g5 linux]$ /usr/bin/time git-rev-list v2.6.12..HEAD > /dev/null
0.26user 0.00system 0:00.27elapsed 100%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+2433minor)pagefaults 0swaps

note how the minor faults have decreased from 3714 pages to 2433 pages.
That's all due to the fewer anonymous pages allocated to hold the comment
buffers and their metadata.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoBe more backward compatible with git-ssh-{push,pull}.
Junio C Hamano [Thu, 15 Sep 2005 21:56:37 +0000 (14:56 -0700)]
Be more backward compatible with git-ssh-{push,pull}.

HPA reminded me that these programs knows about the name of the
counterpart on the other end and simply symlinking the old name to
new name locally would not be enough.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] rsh.c env and quoting cleanup, take 2
H. Peter Anvin [Thu, 15 Sep 2005 19:33:14 +0000 (12:33 -0700)]
[PATCH] rsh.c env and quoting cleanup, take 2

This patch does proper quoting, and uses "env" to be compatible with
tcsh.  As a side benefit, I believe the code is a lot cleaner to read.

[jc: I am accepting this not because I necessarily agree with the
 quoting approach taken by it, but because (1) the code is only used
 by ssh-fetch/ssh-upload pair which I do not care much about (if you
 have ssh account on the remote end you should be using git-send-pack
 git-fetch-pack pair over ssh anyway), and (2) HPA is one of the more
 important customers belonging to the Linux kernel community and I
 want to help his workflow -- which includes not wasting his time by
 asking him to switch to git-send-pack/git-fetch-pack pair, nor to use
 a better shell ;-).  I might not have taken this patch if it mucked
 with git_connect in connect.c in its current form.]

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Fix fetch completeness assumptions
Daniel Barkalow [Thu, 15 Sep 2005 01:31:42 +0000 (21:31 -0400)]
[PATCH] Fix fetch completeness assumptions

Don't assume that any commit we have is complete; assume that any ref
we have is complete.

Signed-off-by: Daniel Barkalow <barkalow@iabervon.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Document git-fetch options
Sergey Vlasov [Wed, 14 Sep 2005 12:48:05 +0000 (16:48 +0400)]
[PATCH] Document git-fetch options

Add documentation for git-fetch options

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoUnoptimize info/refs creation.
Junio C Hamano [Wed, 14 Sep 2005 20:15:53 +0000 (13:15 -0700)]
Unoptimize info/refs creation.

The code did not catch the case where you removed an existing ref
without changing anything else.  We are not talking about hundreds of
refs anyway, so remove that optimization.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoRetire info/rev-cache
Junio C Hamano [Wed, 14 Sep 2005 20:08:55 +0000 (13:08 -0700)]
Retire info/rev-cache

It was one of those things that were well intentioned but did not turn
out to be useful in practice.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Use '-d' as the first flag to 'install'
Peter Eriksen [Wed, 14 Sep 2005 10:41:52 +0000 (12:41 +0200)]
[PATCH] Use '-d' as the first flag to 'install'

... in order to please Solaris 'install'.  GNU install is not harmed
with this.

[jc: Documentation/Makefile also fixed.]

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] git-http-fetch: Allow caching of retrieved objects by proxy servers
Sergey Vlasov [Tue, 13 Sep 2005 15:38:58 +0000 (19:38 +0400)]
[PATCH] git-http-fetch: Allow caching of retrieved objects by proxy servers

By default the curl library adds "Pragma: no-cache" header to all
requests, which disables caching by proxy servers.  However, most
files in a GIT repository are immutable, and caching them is safe and
could be useful.

This patch removes the "Pragma: no-cache" header from requests for all
files except the pack list (objects/info/packs) and references
(refs/*), which are really mutable and should not be cached.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
(cherry picked from 3b2a4c46fd5093ec79fb60e1b14b8d4a58c74612 commit)

19 years agogit-branch -d <branch>: delete unused branch.
Junio C Hamano [Wed, 14 Sep 2005 08:43:53 +0000 (01:43 -0700)]
git-branch -d <branch>: delete unused branch.

The new flag '-d' lets you delete a branch.  For safety, it does not
lets you delete the branch you are currently on, nor a branch that
has been fully merged into your current branch.

The credit for the safety check idea goes to Daniel Barkalow.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoRevert "[PATCH] plug memory leak in diff.c::diff_free_filepair()"
Junio C Hamano [Wed, 14 Sep 2005 21:06:50 +0000 (14:06 -0700)]
Revert "[PATCH] plug memory leak in diff.c::diff_free_filepair()"

This reverts 068eac91ce04b9aca163acb1927c3878c45d1a07 commit.

19 years ago[PATCH] Fix alloc_filespec() initialization
Linus Torvalds [Wed, 14 Sep 2005 20:41:24 +0000 (13:41 -0700)]
[PATCH] Fix alloc_filespec() initialization

This simplifies and fixes the initialization of a "diff_filespec" when
allocated.

The old code would not initialize "sha1_valid". Noticed by valgrind.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoMake merge comment git-pull makes for an octopus a bit prettier.
Junio C Hamano [Wed, 14 Sep 2005 06:49:55 +0000 (23:49 -0700)]
Make merge comment git-pull makes for an octopus a bit prettier.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoMerge branch 'master' of .
Junio C Hamano [Wed, 14 Sep 2005 05:30:13 +0000 (22:30 -0700)]
Merge branch 'master' of .

19 years agoread-tree: fix bogus debugging statement.
Junio C Hamano [Wed, 14 Sep 2005 05:27:42 +0000 (22:27 -0700)]
read-tree: fix bogus debugging statement.

We wanted to detect case #16 which should be rare, but botched the
case when some paths are missing, causing a segfault.  My fault.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agogit-merge-recursive: Trivial RE fixes.
Junio C Hamano [Wed, 14 Sep 2005 04:09:03 +0000 (21:09 -0700)]
git-merge-recursive: Trivial RE fixes.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Use the 'die' function where it is appropriate.
Fredrik Kuivinen [Tue, 13 Sep 2005 21:41:39 +0000 (23:41 +0200)]
[PATCH] Use the 'die' function where it is appropriate.

Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Use a temporary index file when we merge the common ancestors.
Fredrik Kuivinen [Tue, 13 Sep 2005 21:41:16 +0000 (23:41 +0200)]
[PATCH] Use a temporary index file when we merge the common ancestors.

With this change we can get rid of a call to 'git-update-index
--refresh'.

Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Adjust git-merge-recursive.py for the new tool names.
Fredrik Kuivinen [Tue, 13 Sep 2005 21:40:47 +0000 (23:40 +0200)]
[PATCH] Adjust git-merge-recursive.py for the new tool names.

Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Don't output 'Automatic merge failed, ...'
Fredrik Kuivinen [Tue, 13 Sep 2005 21:40:23 +0000 (23:40 +0200)]
[PATCH] Don't output 'Automatic merge failed, ...'

git-merge.sh does this for us.

Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Be more like the 'resolve' strategy.
Fredrik Kuivinen [Tue, 13 Sep 2005 21:39:34 +0000 (23:39 +0200)]
[PATCH] Be more like the 'resolve' strategy.

If there are non-mergeable changes leave the head contents in the
cache and update the working directory with the output from merge(1).

In the add/add and delete/modify conflict cases leave unmerged cache
entries in the index.

Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Define relative .git/objects/info/alternates semantics.
Junio C Hamano [Tue, 13 Sep 2005 07:05:22 +0000 (00:05 -0700)]
[PATCH] Define relative .git/objects/info/alternates semantics.

An entry in the alternates file can name a directory relative to
the object store it describes.  A typical linux-2.6 maintainer
repository would have "../../../torvalds/linux-2.6.git/objects" there,
because the subsystem maintainer object store would live in

    /pub/scm/linux/kernel/git/$u/$system.git/objects/

and the object store of Linus tree is in

    /pub/scm/linux/kernel/git/torvalds/linux-2.6.git/objects/

This unfortunately is different from GIT_ALTERNATE_OBJECT_DIRECTORIES
which is relative to the cwd of the running process, but there is no
way to make it consistent with the behaviour of the environment
variable.  The process typically is run in $system.git/ directory for
a naked repository, or one level up for a repository with a working
tree, so we just define it to be relative to the objects/ directory
to be different from either ;-).

Later, the dumb transport could be updated to read from info/alternates
and make requests for the repository the repository borrows from.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoDetect ls-remote failure properly.
Junio C Hamano [Tue, 13 Sep 2005 20:16:45 +0000 (13:16 -0700)]
Detect ls-remote failure properly.

The part that can fail is before the pipe, so we need to propagate the
error properly to the main process.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years ago[PATCH] Rename the 'fredrik' merge strategy to 'recursive'.
Fredrik Kuivinen [Tue, 13 Sep 2005 06:22:26 +0000 (08:22 +0200)]
[PATCH] Rename the 'fredrik' merge strategy to 'recursive'.

Otherwise we would regret when Fredrik comes up with another merge
algorithm with different pros-and-cons with the current one.

Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoFix off-by-one error in git-merge
Junio C Hamano [Tue, 13 Sep 2005 05:20:42 +0000 (22:20 -0700)]
Fix off-by-one error in git-merge

'git-merge -s' without a strategy name does not fail and does
not give usage as it should.

Signed-off-by: Junio C Hamano <junkio@cox.net>
19 years agoPropagate errors from fetch-pack correctly to git-fetch.
Junio C Hamano [Tue, 13 Sep 2005 05:20:02 +0000 (22:20 -0700)]
Propagate errors from fetch-pack correctly to git-fetch.

When git-fetch-pack fails, the command does not notice the failure
and instead pretended nothing was fetched and there was nothing wrong.

Signed-off-by: Junio C Hamano <junkio@cox.net>