1
0
mirror of https://github.com/git/git.git synced 2024-09-28 23:11:39 +02:00
Commit Graph

19626 Commits

Author SHA1 Message Date
Nicolas Sebrecht
e019961d7f mailinfo: add '--scissors' to usage message
Signed-off-by: Nicolas Sebrecht <nicolas.s.dev@gmx.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-11 00:11:44 -07:00
Brian Gernhardt
5beb577db8 INSTALL: Describe dependency knobs from Makefile
We said that some of our dependencies were optional, but didn't say
how to turn them off.  Add information for that and mention where to
save the options close to the top of the file.

Also, standardize on both using quotes for the names of the dependencies
and tabs for indentation of the list.

Signed-off-by: Brian Gernhardt <brian@gernhardtsoftware.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-10 21:34:43 -07:00
Brian Gernhardt
26d9443925 INSTALL: Reorder dependencies, split shell and Perl
The most important and non-optional dependencies should go first, so put
them there.  While we're moving them, the descriptions for shell and perl
were archaic, referring to "bare-bones Porcelainish scripts" that have
become powerful and essential.

Signed-off-by: Brian Gernhardt <brian@gernhardtsoftware.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-10 21:34:36 -07:00
Reilly Grant
1d7367dce7 git-p4: Avoid modules deprecated in Python 2.6.
The popen2, sha and sets modules are deprecated in Python 2.6 (sha in
Python 2.5).  Both popen2 and sha are not actually used in git-p4.
Replace usage of sets.Set with the builtin set object.

The built-in set object was added in Python 2.4 and is already used in
other parts of this script, so this dependency is nothing new.

Signed-off-by: Reilly Grant <reillyeon@qotw.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-10 11:22:22 -07:00
Brian Gernhardt
0460dba4b4 Makefile: Add NEEDS_CRYPTO_WITH_SSL
The Makefile comment for NEEDS_SSL_WITH_CRYPTO says to define it "if
you need -lcrypto with -lssl (Darwin)."  However, what it actually
does is add -lssl when you use -lcrypto and not the other way around.
However, libcrypto contains a majority of the ERR_* functions from
OpenSSL (at least on OS X) so we need it both ways.

So, add NEEDS_CRYPTO_WITH_SSL which adds -lcrypto to the OpenSSL link
flags and clarify the difference between it and NEEDS_SSL_WITH_CRYPTO.

Signed-off-by: Brian Gernhardt <brian@gernhardtsoftware.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-10 10:22:05 -07:00
Martin Nordholts
aaa68dd50f git.el: Use git-add-file for unmerged files, remove git-resolve-file
Use `git-add-file' to mark unmerged files as resolved in the
*git-status* buffer to be consistent with git's CLI instructions. Also
remove `git-resolve-file' to make it clear that that "R" is a now a
free keybinding.

Signed-off-by: Martin Nordholts <martinn@src.gnome.org>
Acked-by: Alexandre Julliard <julliard@winehq.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-09 12:11:44 -07:00
Brian Gernhardt
3de8ba0217 INSTALL: Update description of our SHA-1 code
We haven't had Mozilla's code or an ARM optimized algorithm since
30ae47b.  Reword the paragraph to give credit but not authorship to
Mozilla.

Signed-off-by: Brian Gernhardt <brian@gernhardtsoftware.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-08 23:32:43 -07:00
Junio C Hamano
5ad9dce7e6 GIT 1.6.5-rc0
Signed-off-by: Junio C Hamano <gitster@pobox.com>
v1.6.5-rc0
2009-09-07 17:20:02 -07:00
Junio C Hamano
df01e7c5ee Merge branch 'maint'
* maint:
  git-pull: do not mention --quiet and --verbose twice
  githooks.txt: put hooks into subsections
2009-09-07 15:45:48 -07:00
Emmanuel Trillaud
90e431152e git-pull: do not mention --quiet and --verbose twice
git-pull.txt includes fetch-options.txt and merge-options.txt, both of
which document the --quiet and --verbose.

Supress the ones from fetch-options.txt.

Signed-off-by: Emmanuel Trillaud <etrillaud@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-07 15:45:13 -07:00
Bert Wesarg
6d71c1dca4 githooks.txt: put hooks into subsections
All hooks are currently in its own section. Which may confuse users,
because the section name serves as the hook file name and sections are
all caps for man pages. Putting them into a new HOOKS section and each
hook into a subsection keeps the case to lower case.

Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-07 15:45:13 -07:00
Junio C Hamano
b8711f520b Merge branch 'jc/mailinfo-scissors'
* jc/mailinfo-scissors:
  mailinfo.scissors: new configuration
  am/mailinfo: Disable scissors processing by default
  Documentation: describe the scissors mark support of "git am"
  Teach mailinfo to ignore everything before -- >8 -- mark
  builtin-mailinfo.c: fix confusing internal API to mailinfo()
2009-09-07 15:25:37 -07:00
Junio C Hamano
2da9f8e370 Merge branch 'jk/clone-b'
* jk/clone-b:
  clone: add --branch option to select a different HEAD
2009-09-07 15:24:53 -07:00
Junio C Hamano
e4d1afbcf2 Merge branch 'jc/upload-pack-hook'
* jc/upload-pack-hook:
  upload-pack: feed "kind [clone|fetch]" to post-upload-pack hook
  upload-pack: add a trigger for post-upload-pack hook
2009-09-07 15:24:47 -07:00
Junio C Hamano
54f0bdc811 Merge branch 'tr/reset-checkout-patch'
* tr/reset-checkout-patch:
  stash: simplify defaulting to "save" and reject unknown options
  Make test case number unique
  tests: disable interactive hunk selection tests if perl is not available
  DWIM 'git stash save -p' for 'git stash -p'
  Implement 'git stash save --patch'
  Implement 'git checkout --patch'
  Implement 'git reset --patch'
  builtin-add: refactor the meat of interactive_add()
  Add a small patch-mode testing library
  git-apply--interactive: Refactor patch mode code
  Make 'git stash -k' a short form for 'git stash save --keep-index'
2009-09-07 15:24:38 -07:00
Junio C Hamano
8e4384fd44 Merge branch 'np/maint-1.6.3-deepen'
* np/maint-1.6.3-deepen:
  pack-objects: free preferred base memory after usage
  make shallow repository deepening more network efficient
2009-09-07 15:23:50 -07:00
Junio C Hamano
6ea71fe7d3 Merge branch 'maint'
* maint:
  push: re-flow non-fast-forward message
  push: fix english in non-fast-forward message
2009-09-06 00:39:32 -07:00
Jeff King
14b772a0d7 push: re-flow non-fast-forward message
The extreme raggedness of the right edge make this jarring
to read. Let's re-flow the text to fill the lines in a more
even way.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-06 00:39:15 -07:00
Jeff King
e1f8f0cfbe push: fix english in non-fast-forward message
We must use an article when referring to the section
because it is a non-proper noun, and it must be the definite
article because we are referring to a specific section.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-06 00:39:14 -07:00
Pascal Obry
3fb9d58235 Do not scramble password read from .cvspass
Passwords stored in .cvspass are already scrambled, we do not
want to scramble them twice. Only passwords read from the
command line are scrambled.

This fixes a regression introduced by b2139db (git-cvsimport: add support
for cvs pserver password scrambling., 2009-08-14).

Signed-off-by: Pascal Obry <pascal@obry.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-05 22:34:27 -07:00
Nicolas Pitre
0ef95f72f8 pack-objects: free preferred base memory after usage
When adding objects for preferred delta base, the content from tree
objects leading to given paths is kept in a cache. This has the
potential to grow significantly, especially with large directories as
the whole tree object content is loaded in memory, even if in practice
the number of those objects is limited to the 256 cache entries plus the
$window root tree objects.  Still, that can't hurt freeing that up after
object enumeration is done, and before more memory is needed for delta
search.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-05 22:27:08 -07:00
Nicolas Pitre
6523078b96 make shallow repository deepening more network efficient
First of all, I can't find any reason why thin pack generation is
explicitly disabled when dealing with a shallow repository.  The
possible delta base objects are collected from the edge commits which
are always obtained through history walking with the same shallow refs
as the client, Therefore the client is always going to have those base
objects available. So let's remove that restriction.

Then we can make shallow repository deepening much more efficient by
using the remote's unshallowed commits as edge commits to get preferred
base objects for thin pack generation.  On git.git, this makes the data
transfer for the deepening of a shallow repository from depth 1 to depth 2
around 134 KB instead of 3.68 MB.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-05 22:25:26 -07:00
Junio C Hamano
79b4fde573 Merge branch 'maint'
* maint:
  git-clone: add missing comma in --reference documentation
2009-09-03 09:43:08 -07:00
Junio C Hamano
bc29df6022 Merge branch 'maint-1.6.3' into maint
* maint-1.6.3:
  git-clone: add missing comma in --reference documentation
  git-cvsserver: no longer use deprecated 'git-subcommand' commands
  clone: disconnect transport after fetching
2009-09-03 09:42:56 -07:00
Junio C Hamano
ba7e81430a Merge branch 'maint-1.6.2' into maint-1.6.3
* maint-1.6.2:
  git-clone: add missing comma in --reference documentation
  clone: disconnect transport after fetching
2009-09-03 09:42:38 -07:00
Miklos Vajna
405923761a git-clone: add missing comma in --reference documentation
Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-03 09:41:56 -07:00
Junio C Hamano
193a5d195b Merge branch 'maint'
* maint:
  git-cvsserver: no longer use deprecated 'git-subcommand' commands
  clone: disconnect transport after fetching
2009-09-02 19:52:18 -07:00
Junio C Hamano
daf85d97f8 Merge branch 'maint-1.6.3' into maint
* maint-1.6.3:
  git-cvsserver: no longer use deprecated 'git-subcommand' commands
  clone: disconnect transport after fetching
2009-09-02 19:51:55 -07:00
Jeff King
2e5ed5f21b push: teach --quiet to suppress "Everything up-to-date"
This should have been part of 481c7a6, whose goal was to
make "git push -q" silent unless there is an error.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-02 19:47:50 -07:00
Junio C Hamano
8cc15acfb8 Merge branch 'maint-1.6.2' into maint-1.6.3
* maint-1.6.2:
  clone: disconnect transport after fetching
2009-09-02 18:45:44 -07:00
Gerrit Pape
d2feb01aa5 git-cvsserver: no longer use deprecated 'git-subcommand' commands
git-cvsserver still references git commands like 'git-config', which
is depcrecated.  This commit changes git-cvsserver to use the
'git subcommand' form.

Sylvain Beucler reported the problem through
 http://bugs.debian.org/536067

Signed-off-by: Gerrit Pape <pape@smarden.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-02 18:41:42 -07:00
Jeff King
12d4996622 clone: disconnect transport after fetching
The current code just leaves the transport in whatever state
it was in after performing the fetch.  For a non-empty clone
over the git protocol, the transport code already
disconnects at the end of the fetch.

But for an empty clone, we leave the connection hanging, and
eventually close the socket when clone exits. This causes
the remote upload-pack to complain "the remote end hung up
unexpectedly". While this message is harmless to the clone
itself, it is unnecessarily scary for a user to see and may
pollute git-daemon logs.

This patch just explicitly calls disconnect after we are
done with the remote end, which sends a flush packet to
upload-pack and cleanly disconnects, avoiding the error
message.

Other transports are unaffected or slightly improved:

 - for a non-empty repo over the git protocol, the second
   disconnect is a no-op (since we are no longer connected)

 - for "walker" transports (like HTTP or FTP), we actually
   free some used memory (which previously just sat until
   the clone process exits)

 - for "rsync", disconnect is always a no-op anyway

Signed-off-by: Jeff King <peff@peff.net>
Acked-by: Daniel Barkalow <barkalow@iabervon.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-02 18:39:02 -07:00
Johannes Sixt
228e7b5d4d status: list unmerged files much later
When resolving a conflicted merge, two lists in the status output need
more attention from the user than other parts.

 - the list of updated paths is useful to review the amount of changes the
   merge brings in (the user cannot do much about them other than
   reviewing, though); and

 - the list of unmerged paths needs the most attention from the user; the
   user needs to resolve them in order to proceed.

Since the output of git status does not by default go through the pager,
the early parts of the output can scroll away at the top. It is better to
put the more important information near the bottom.  During a merge, local
changes that are not in the index are minimum, and you should keep the
untracked list small in any case, so moving the unmerged list from the top
of the output to immediately after the list of updated paths would give us
the optimum layout.

Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Acked-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-01 22:29:51 -07:00
Matthieu Moy
3c2eb80fe3 stash: simplify defaulting to "save" and reject unknown options
With the earlier DWIM patches, certain combination of options defaulted
to the "save" command correctly while certain equally valid combination
did not.  For example, "git stash -k" were Ok but "git stash -q -k" did
not work.

This makes the logic of defaulting to "save" much simpler. If there are no
non-flag arguments, it is clear that there is no command word, and we
default to "save" subcommand.  This rule prevents "git stash -q apply"
from quietly creating a stash with "apply" as the message.

This also teaches "git stash save" to reject an unknown option.  This is
to keep a mistyped "git stash save --quite" from creating a stash with a
message "--quite", and this safety is more important with the new logic
to default to "save" with any option-looking argument without an explicit
comand word.

[jc: this is based on Matthieu's 3-patch series, and a follow-up
discussion, and he and Peff take all the credit; if I have introduced bugs
while reworking, they are mine.]

Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-01 22:03:11 -07:00
Junio C Hamano
0b1fac320c builtin-apply.c: get rid of an unnecessary use of temporary array
Instead of allocating a temporary array imglen[], copying contents to it
from another array img->line[], and then using imglen[], use the value
from img->line[], whose value does not change during the whole process.

This incidentally removes a use of C99 variable length array, which some
older compilers apparently are not happy with.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-01 08:02:51 -07:00
Junio C Hamano
dcda3614d4 builtin-pack-objects.c: avoid vla
This is one of only two places that we use C99 variable length array on
the stack, which some older compilers apparently are not happy with.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-09-01 07:55:56 -07:00
Brian Gianforcaro
eeefa7c90e Style fixes, add a space after if/for/while.
The majority of code in core git appears to use a single
space after if/for/while. This is an attempt to bring more
code to this standard. These are entirely cosmetic changes.

Signed-off-by: Brian Gianforcaro <b.gianfo@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-31 23:26:28 -07:00
Junio C Hamano
554555ac7d Merge branch 'lt/approxidate'
* lt/approxidate:
  fix approxidate parsing of relative months and years
  tests: add date printing and parsing tests
  refactor test-date interface
  Add date formatting and parsing functions relative to a given time
  Further 'approxidate' improvements
  Improve on 'approxidate'

Conflicts:
	date.c
2009-08-31 22:11:36 -07:00
Junio C Hamano
909beb860b Merge branch 'mr/gitweb-snapshot'
* mr/gitweb-snapshot:
  gitweb: add t9501 tests for checking HTTP status codes
  gitweb: split test suite into library and tests
  gitweb: improve snapshot error handling
2009-08-31 22:09:53 -07:00
Junio C Hamano
d34eca0392 Merge branch 'tf/diff-whitespace-incomplete-line'
* tf/diff-whitespace-incomplete-line:
  xutils: Fix xdl_recmatch() on incomplete lines
  xutils: Fix hashing an incomplete line with whitespaces at the end
2009-08-31 22:08:57 -07:00
Jeff King
931e8e27d9 fix approxidate parsing of relative months and years
These were broken by b5373e9. The problem is that the code
marks the month and year with "-1" for "we don't know it
yet", but the month and year code paths were not adjusted to
fill in the current time before doing their calculations
(whereas other units follow a different code path and are
fine).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-30 22:04:56 -07:00
Jeff King
34dc6e73b0 tests: add date printing and parsing tests
Until now, there was no coverage of relative date printing
or approxidate parsing routines (mainly because we had no
way of faking the "now" time for relative date calculations,
which made consistent testing impossible).

This new script tries to exercise the basic features of
show_date and approxidate. Most of the tests are just "this
obvious thing works" to prevent future regressions, with a
few exceptions:

  - We confirm the fix in 607a9e8 that relative year/month
    dates in the latter half of a year round correctly.

  - We confirm that the improvements in b5373e9 and 1bddb25
    work.

  - A few tests are marked to expect failure, which are
    regressions recently introduced by the two commits
    above.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-30 22:04:56 -07:00
Jeff King
4f6552ea4c refactor test-date interface
The test-date program goes back to the early days of git,
where it was presumably used to do manual sanity checks on
changes to the date code. However, it is not actually used
by the test suite to do any sort of automatic of systematic
tests.

This patch refactors the interface to the program to try to
make it more suitable for use by the test suite. There
should be no fallouts to changing the interface since it is
not actually installed and is not internally called by any
other programs.

The changes are:

  - add a "mode" parameter so the caller can specify which
    operation to test

  - add a mode to test relative date output from show_date

  - allow faking a fixed time via the TEST_DATE_NOW
    environment variable, which allows consistent automated
    testing

  - drop the use of ctime for showing dates in favor of our
    internal iso8601 printing routines. The ctime output is
    somewhat redundant (because of the day-of-week) which
    makes writing test cases more annoying.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-30 22:04:46 -07:00
Alex Riesen
33012fc429 Add date formatting and parsing functions relative to a given time
The main purpose is to allow predictable testing of the code.

Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-30 19:59:11 -07:00
Junio C Hamano
f324cb50be Sync with 1.6.4.2 2009-08-29 14:52:03 -07:00
Junio C Hamano
82c3e21000 GIT 1.6.4.2
Signed-off-by: Junio C Hamano <gitster@pobox.com>
v1.6.4.2
2009-08-29 14:31:01 -07:00
René Scharfe
f7aec129fa UI consistency: allow --force for where -f means force
git branch, checkout, clean, mv and tag all have an option -f to override
certain checks.  This patch makes them accept the long option --force as
a synonym.

While we're at it, document that checkout support --quiet as synonym for
its short option -q.

Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-29 14:08:03 -07:00
René Scharfe
53a1116c61 update-server-info: make builtin, use parseopt
Convert git update-server-info to a built-in command and use parseopt.

Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-29 14:07:25 -07:00
Nanako Shiraishi
e71c008dce Remove unused t/t8005/iso8859-5.txt
This file is no longer used since 54bc13c (t8005: Nobody writes Russian in
shift_jis, 2009-06-18).

Signed-off-by: Nanako Shiraishi <nanako3@lavabit.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-29 00:50:31 -07:00
Junio C Hamano
11cae066b2 upload-pack: feed "kind [clone|fetch]" to post-upload-pack hook
A request to clone the repository does not give any "have" but asks for
all the refs we offer with "want".  When a request does not ask to clone
the repository fully, but asks to fetch some refs into an empty
repository, it will not give any "have" but its "want" won't ask for all
the refs we offer.

If we suppose (and I would say this is a rather big if) that it makes
sense to distinguish these two cases, a hook cannot reliably do this
alone.  The hook can detect lack of "have" and bunch of "want", but there
is no direct way to tell if the other end asked for all refs we offered,
or merely most of them.

Between the time we talked with the other end and the time the hook got
called, we may have acquired more refs or lost some refs in the repository
by concurrent operations.  Given that we plan to introduce selective
advertisement of refs with a protocol extension, it would become even more
difficult for hooks to guess between these two cases.

This adds "kind [clone|fetch]" to hook's input, as a stable interface to
allow the hooks to tell these cases apart.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-28 22:39:24 -07:00