OSDN Git Service

git-core/git.git
8 years agolock_ref_sha1_basic: handle REF_NODEREF with invalid refs
Jeff King [Tue, 12 Jan 2016 21:45:09 +0000 (16:45 -0500)]
lock_ref_sha1_basic: handle REF_NODEREF with invalid refs

We sometimes call lock_ref_sha1_basic with REF_NODEREF
to operate directly on a symbolic ref. This is used, for
example, to move to a detached HEAD, or when updating
the contents of HEAD via checkout or symbolic-ref.

However, the first step of the function is to resolve the
refname to get the "old" sha1, and we do so without telling
resolve_ref_unsafe() that we are only interested in the
symref. As a result, we may detect a problem there not with
the symref itself, but with something it points to.

The real-world example I found (and what is used in the test
suite) is a HEAD pointing to a ref that cannot exist,
because it would cause a directory/file conflict with other
existing refs.  This situation is somewhat broken, of
course, as trying to _commit_ on that HEAD would fail. But
it's not explicitly forbidden, and we should be able to move
away from it. However, neither "git checkout" nor "git
symbolic-ref" can do so. We try to take the lock on HEAD,
which is pointing to a non-existent ref. We bail from
resolve_ref_unsafe() with errno set to EISDIR, and the lock
code thinks we are attempting to create a d/f conflict.

Of course we're not. The problem is that the lock code has
no idea what level we were at when we got EISDIR, so trying
to diagnose or remove empty directories for HEAD is not
useful.

To make things even more complicated, we only get EISDIR in
the loose-ref case. If the refs are packed, the resolution
may "succeed", giving us the pointed-to ref in "refname",
but a null oid. Later, we say "ah, the null oid means we are
creating; let's make sure there is room for it", but
mistakenly check against the _resolved_ refname, not the
original.

We can fix this by making two tweaks:

  1. Call resolve_ref_unsafe() with RESOLVE_REF_NO_RECURSE
     when REF_NODEREF is set. This means any errors
     we get will be from the orig_refname, and we can act
     accordingly.

     We already do this in the REF_DELETING case, but we
     should do it for update, too.

  2. If we do get a "refname" return from
     resolve_ref_unsafe(), even with RESOLVE_REF_NO_RECURSE
     it may be the name of the ref pointed-to by a symref.
     We already normalize this back to orig_refname before
     taking the lockfile, but we need to do so before the
     null_oid check.

While we're rearranging the REF_NODEREF handling, we can
also bump the initialization of lflags to the top of the
function, where we are setting up other flags. This saves us
from having yet another conditional block on REF_NODEREF
just to set it later.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agolock_ref_sha1_basic: always fill old_oid while holding lock
Jeff King [Tue, 12 Jan 2016 21:44:39 +0000 (16:44 -0500)]
lock_ref_sha1_basic: always fill old_oid while holding lock

Our basic strategy for taking a ref lock is:

  1. Create $ref.lock to take the lock

  2. Read the ref again while holding the lock (during which
     time we know that nobody else can be updating it).

  3. Compare the value we read to the expected "old_sha1"

The value we read in step (2) is returned to the caller via
the lock->old_oid field, who may use it for other purposes
(such as writing a reflog).

If we have no "old_sha1" (i.e., we are unconditionally
taking the lock), then we obviously must omit step 3. But we
_also_ omit step 2. This seems like a nice optimization, but
it means that the caller sees only whatever was left in
lock->old_oid from previous calls to resolve_ref_unsafe(),
which happened outside of the lock.

We can demonstrate this race pretty easily. Imagine you have
three commits, $one, $two, and $three. One script just flips
between $one and $two, without providing an old-sha1:

  while true; do
    git update-ref -m one refs/heads/foo $one
    git update-ref -m two refs/heads/foo $two
  done

Meanwhile, another script tries to set the value to $three,
also not using an old-sha1:

  while true; do
    git update-ref -m three refs/heads/foo $three
  done

If these run simultaneously, we'll see a lot of lock
contention, but each of the writes will succeed some of the
time. The reflog may record movements between any of the
three refs, but we would expect it to provide a consistent
log: the "from" field of each log entry should be the same
as the "to" field of the previous one.

But if we check this:

  perl -alne '
    print "mismatch on line $."
            if defined $last && $F[0] ne $last;
    $last = $F[1];
  ' .git/logs/refs/heads/foo

we'll see many mismatches. Why?

Because sometimes, in the time between lock_ref_sha1_basic
filling lock->old_oid via resolve_ref_unsafe() and it taking
the lock, there may be a complete write by another process.
And the "from" field in our reflog entry will be wrong, and
will refer to an older value.

This is probably quite rare in practice. It requires writers
which do not provide an old-sha1 value, and it is a very
quick race. However, it is easy to fix: we simply perform
step (2), the read-under-lock, whether we have an old-sha1
or not. Then the value we hand back to the caller is always
atomic.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agocheckout,clone: check return value of create_symref
Jeff King [Tue, 12 Jan 2016 09:57:34 +0000 (04:57 -0500)]
checkout,clone: check return value of create_symref

It's unlikely that we would fail to create or update a
symbolic ref (especially HEAD), but if we do, we should
notice and complain. Note that there's no need to give more
details in our error message; create_symref will already
have done so.

While we're here, let's also fix a minor memory leak in
clone.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agocreate_symref: write reflog while holding lock
Jeff King [Tue, 29 Dec 2015 05:57:25 +0000 (00:57 -0500)]
create_symref: write reflog while holding lock

We generally hold a lock on the matching ref while writing
to its reflog; this prevents two simultaneous writers from
clobbering each other's reflog lines (it does not even have
to be two symref updates; because we don't hold the lock, we
could race with somebody writing to the pointed-to ref via
HEAD, for example).

We can fix this by writing the reflog before we commit the
lockfile. This runs the risk of writing the reflog but
failing the final rename(), but at least we now err on the
same side as the rest of the ref code.

Noticed-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Jeff King <peff@peff.net>
Reviewed-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agocreate_symref: use existing ref-lock code
Jeff King [Tue, 29 Dec 2015 05:57:01 +0000 (00:57 -0500)]
create_symref: use existing ref-lock code

The create_symref() function predates the existence of
"struct lock_file", let alone the more recent "struct
ref_lock". Instead, it just does its own manual dot-locking.
Besides being more code, this has a few downsides:

 - if git is interrupted while holding the lock, we don't
   clean up the lockfile

 - we don't do the usual directory/filename conflict check.
   So you can sometimes create a symref "refs/heads/foo/bar",
   even if "refs/heads/foo" exists (namely, if the refs are
   packed and we do not hit the d/f conflict in the
   filesystem).

This patch refactors create_symref() to use the "struct
ref_lock" interface, which handles both of these things.
There are a few bonus cleanups that come along with it:

 - we leaked ref_path in some error cases

 - the symref contents were stored in a fixed-size buffer,
   putting an artificial (albeit large) limitation on the
   length of the refname. We now write through fprintf, and
   handle refnames of any size.

 - we called adjust_shared_perm only after the file was
   renamed into place, creating a potential race with
   readers in a shared repository. The lockfile code now
   handles this when creating the lockfile, making it
   atomic.

 - the legacy prefer_symlink_refs path did not do any
   locking at all. Admittedly, it is not atomic from a
   reader's perspective (as it unlinks and re-creates the
   symlink to overwrite), but at least it cannot conflict
   with other writers now.

 - the result of this patch is hopefully more readable. It
   eliminates three goto labels. Two were for error checking
   that is now simplified, and the third was to reach shared
   code that has been pulled into its own function.

Signed-off-by: Jeff King <peff@peff.net>
Reviewed-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agocreate_symref: modernize variable names
Jeff King [Tue, 29 Dec 2015 05:56:44 +0000 (00:56 -0500)]
create_symref: modernize variable names

Once upon a time, create_symref() was used only to point
HEAD at a branch name, and the variable names reflect that
(e.g., calling the path git_HEAD). However, it is much more
generic these days (and has been for some time). Let's
update the variable names to make it easier to follow:

  - `ref_target` is now just `refname`. This is closer to
    the `ref` that is already in `cache.h`, but with the
    extra twist that "name" makes it clear this is the name
    and not a ref struct. Dropping "target" hopefully makes
    it clear that we are talking about the symref itself,
    not what it points to.

  - `git_HEAD` is now `ref_path`; the on-disk path
    corresponding to `ref`.

  - `refs_heads_master` is now just `target`; i.e., what the
    symref points at. This term also matches what is in
    the symlink(2) manpage (at least on Linux).

  - the buffer to hold the symref file's contents was simply
    called `ref`. It's now `buf` (admittedly also generic,
    but at least not actively introducing confusion with the
    other variable holding the refname).

Signed-off-by: Jeff King <peff@peff.net>
Reviewed-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge branch 'jk/symbolic-ref-maint'
Junio C Hamano [Mon, 28 Dec 2015 21:57:24 +0000 (13:57 -0800)]
Merge branch 'jk/symbolic-ref-maint'

"git symbolic-ref" forgot to report a failure with its exit status.

* jk/symbolic-ref-maint:
  t1401: test reflog creation for git-symbolic-ref
  symbolic-ref: propagate error code from create_symref()

8 years agoMerge tag 'l10n-2.7.0-rnd2' of git://github.com/git-l10n/git-po
Junio C Hamano [Mon, 28 Dec 2015 21:53:47 +0000 (13:53 -0800)]
Merge tag 'l10n-2.7.0-rnd2' of git://github.com/git-l10n/git-po

l10n-2.7.0-rnd2

* tag 'l10n-2.7.0-rnd2' of git://github.com/git-l10n/git-po:
  l10n: ru.po: update Russian translation
  l10n: Updated Bulgarian translation of git (2477t,0f,0u)
  l10n: ca.po: update translation
  l10n: zh_CN: for git v2.7.0 l10n round 2
  l10n: sv.po: Update Swedish translation (2477t0f0u)
  l10n: sv: Fix bad translation
  l10n: fr.po v2.7.0 round 2 (2477t)
  l10n: git.pot: v2.7.0 round 2 (2 new, 2 removed)
  l10n: zh_CN: for git v2.7.0 l10n round 1
  l10n: ca.po: update translation
  l10n: fr v2.7.0 round 1 (2477t)
  l10n: Updated Bulgarian translation of git (2477t,0f,0u)
  l10n: sv.po: Update Swedish translation (2477t0f0u)
  l10n: vi.po: Updated translation (2477t)
  l10n: git.pot: v2.7.0 round 1 (66 new, 29 removed)
  l10n: fr.po: Fix typo
  l10n: fr.po: Fix typo

8 years agol10n: ru.po: update Russian translation
Dimitriy Ryazantcev [Fri, 25 Dec 2015 12:02:48 +0000 (14:02 +0200)]
l10n: ru.po: update Russian translation

Signed-off-by: Dimitriy Ryazantcev <dimitriy.ryazantcev@gmail.com>
8 years agoMerge branch 'master' of git://github.com/alshopov/git-po
Jiang Xin [Mon, 28 Dec 2015 15:13:15 +0000 (23:13 +0800)]
Merge branch 'master' of git://github.com/alshopov/git-po

* 'master' of git://github.com/alshopov/git-po:
  l10n: Updated Bulgarian translation of git (2477t,0f,0u)

8 years agol10n: Updated Bulgarian translation of git (2477t,0f,0u)
Alexander Shopov [Mon, 28 Dec 2015 09:33:41 +0000 (11:33 +0200)]
l10n: Updated Bulgarian translation of git (2477t,0f,0u)

Signed-off-by: Alexander Shopov <ash@kambanaria.org>
8 years agol10n: ca.po: update translation
Alex Henrie [Mon, 28 Dec 2015 04:42:59 +0000 (21:42 -0700)]
l10n: ca.po: update translation

Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
8 years agol10n: zh_CN: for git v2.7.0 l10n round 2
Jiang Xin [Tue, 22 Dec 2015 15:06:59 +0000 (23:06 +0800)]
l10n: zh_CN: for git v2.7.0 l10n round 2

Update 2 translations (2477t0f0u) for git v2.7.0-rc1.

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
8 years agoMerge branch 'master' of git://github.com/nafmo/git-l10n-sv
Jiang Xin [Sat, 26 Dec 2015 13:22:30 +0000 (21:22 +0800)]
Merge branch 'master' of git://github.com/nafmo/git-l10n-sv

* 'master' of git://github.com/nafmo/git-l10n-sv:
  l10n: sv.po: Update Swedish translation (2477t0f0u)
  l10n: sv: Fix bad translation

8 years agol10n: sv.po: Update Swedish translation (2477t0f0u)
Peter Krefting [Sat, 26 Dec 2015 11:27:15 +0000 (12:27 +0100)]
l10n: sv.po: Update Swedish translation (2477t0f0u)

Signed-off-by: Peter Krefting <peter@softwolves.pp.se>
8 years agol10n: sv: Fix bad translation
Peter Krefting [Sat, 7 Nov 2015 14:48:20 +0000 (15:48 +0100)]
l10n: sv: Fix bad translation

Found-by: Sebastian Rasmussen <sebras@gmail.com>
Signed-off-by: Peter Krefting <peter@softwolves.pp.se>
8 years agol10n: fr.po v2.7.0 round 2 (2477t)
Jean-Noel Avila [Thu, 24 Dec 2015 06:38:22 +0000 (07:38 +0100)]
l10n: fr.po v2.7.0 round 2 (2477t)

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
8 years agoGit 2.7-rc2 v2.7.0-rc2
Junio C Hamano [Tue, 22 Dec 2015 22:46:01 +0000 (14:46 -0800)]
Git 2.7-rc2

Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge branch 'js/emu-write-epipe-on-windows'
Junio C Hamano [Tue, 22 Dec 2015 22:45:16 +0000 (14:45 -0800)]
Merge branch 'js/emu-write-epipe-on-windows'

The write(2) emulation for Windows learned to set errno to EPIPE
when necessary.

* js/emu-write-epipe-on-windows:
  mingw: emulate write(2) that fails with a EPIPE

8 years agopush: don't mark options of recurse-submodules for translation
Ralf Thielow [Tue, 22 Dec 2015 17:53:00 +0000 (18:53 +0100)]
push: don't mark options of recurse-submodules for translation

Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agol10n: git.pot: v2.7.0 round 2 (2 new, 2 removed)
Jiang Xin [Tue, 22 Dec 2015 14:51:43 +0000 (22:51 +0800)]
l10n: git.pot: v2.7.0 round 2 (2 new, 2 removed)

Generate po/git.pot from v2.7.0-rc1-44-g1d88dab for git v2.7.0 l10n round 2.

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
8 years agoMerge branch 'master' of git://github.com/git-l10n/git-po
Jiang Xin [Tue, 22 Dec 2015 14:50:24 +0000 (22:50 +0800)]
Merge branch 'master' of git://github.com/git-l10n/git-po

* 'master' of git://github.com/git-l10n/git-po:
  l10n: zh_CN: for git v2.7.0 l10n round 1
  l10n: ca.po: update translation
  l10n: fr v2.7.0 round 1 (2477t)
  l10n: Updated Bulgarian translation of git (2477t,0f,0u)
  l10n: sv.po: Update Swedish translation (2477t0f0u)
  l10n: vi.po: Updated translation (2477t)
  l10n: git.pot: v2.7.0 round 1 (66 new, 29 removed)
  l10n: fr.po: Fix typo
  l10n: fr.po: Fix typo

8 years agot1401: test reflog creation for git-symbolic-ref
Jeff King [Sun, 20 Dec 2015 07:27:23 +0000 (02:27 -0500)]
t1401: test reflog creation for git-symbolic-ref

The current code writes a reflog entry whenever we update a
symbolic ref, but we never test that this is so. Let's add a
test to make sure upcoming refactoring doesn't cause a
regression.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agosymbolic-ref: propagate error code from create_symref()
Jeff King [Sun, 20 Dec 2015 07:27:18 +0000 (02:27 -0500)]
symbolic-ref: propagate error code from create_symref()

If create_symref() fails, git-symbolic-ref will still exit
with code 0, and our caller has no idea that the command did
nothing.

This appears to have been broken since the beginning of time
(e.g., it is not a regression where create_symref() stopped
calling die() or something similar).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoUpdate release notes to 2.7
Junio C Hamano [Mon, 21 Dec 2015 19:08:20 +0000 (11:08 -0800)]
Update release notes to 2.7

Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge branch 'bc/format-patch-null-from-line'
Junio C Hamano [Mon, 21 Dec 2015 18:59:07 +0000 (10:59 -0800)]
Merge branch 'bc/format-patch-null-from-line'

"format-patch" has learned a new option to zero-out the commit
object name on the mbox "From " line.

* bc/format-patch-null-from-line:
  format-patch: check that header line has expected format
  format-patch: add an option to suppress commit hash
  sha1_file.c: introduce a null_oid constant

8 years agoMerge branch 'jk/ident-loosen-getpwuid'
Junio C Hamano [Mon, 21 Dec 2015 18:59:07 +0000 (10:59 -0800)]
Merge branch 'jk/ident-loosen-getpwuid'

When getpwuid() on the system returned NULL (e.g. the user is not
in the /etc/passwd file or other uid-to-name mappings), the
codepath to find who the user is to record it in the reflog barfed
and died.  Loosen the check in this codepath, which already accepts
questionable ident string (e.g. host part of the e-mail address is
obviously bogus), and in general when we operate fmt_ident() function
in non-strict mode.

* jk/ident-loosen-getpwuid:
  ident: loosen getpwuid error in non-strict mode
  ident: keep a flag for bogus default_email
  ident: make xgetpwuid_self() a static local helper

8 years agoMerge branch 'jk/send-email-ssl-errors'
Junio C Hamano [Mon, 21 Dec 2015 18:59:06 +0000 (10:59 -0800)]
Merge branch 'jk/send-email-ssl-errors'

Improve error reporting when SMTP TLS fails.

* jk/send-email-ssl-errors:
  send-email: enable SSL level 1 debug output

8 years agoMerge branch 'sg/completion-no-column'
Junio C Hamano [Mon, 21 Dec 2015 18:59:06 +0000 (10:59 -0800)]
Merge branch 'sg/completion-no-column'

The completion script (in contrib/) used to list "git column"
(which is not an end-user facing command) as one of the choices

* sg/completion-no-column:
  completion: remove 'git column' from porcelain commands

8 years agoMerge branch 'mc/push-recurse-submodules-config'
Junio C Hamano [Mon, 21 Dec 2015 18:59:05 +0000 (10:59 -0800)]
Merge branch 'mc/push-recurse-submodules-config'

Add new config to avoid typing "--recurse-submodules" on each push.

* mc/push-recurse-submodules-config:
  push: follow the "last one wins" convention for --recurse-submodules
  push: test that --recurse-submodules on command line overrides config
  push: add recurseSubmodules config option

8 years agomingw: emulate write(2) that fails with a EPIPE
Johannes Schindelin [Thu, 17 Dec 2015 17:08:15 +0000 (18:08 +0100)]
mingw: emulate write(2) that fails with a EPIPE

On Windows, when writing to a pipe fails, errno is always
EINVAL. However, Git expects it to be EPIPE.

According to the documentation, there are two cases in which write()
triggers EINVAL: the buffer is NULL, or the length is odd but the mode
is 16-bit Unicode (the broken pipe is not mentioned as possible cause).
Git never sets the file mode to anything but binary, therefore we know
that errno should actually be EPIPE if it is EINVAL and the buffer is
not NULL.

See https://msdn.microsoft.com/en-us/library/1570wh78.aspx for more
details.

This works around t5571.11 failing with v2.6.4 on Windows.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Acked-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge git://ozlabs.org/~paulus/gitk
Junio C Hamano [Mon, 21 Dec 2015 16:56:16 +0000 (08:56 -0800)]
Merge git://ozlabs.org/~paulus/gitk

* git://ozlabs.org/~paulus/gitk:
  gitk: sv.po: Update Swedish translation (311t)
  gitk: Let .bleft.mid widgets 'breathe'
  gitk: Match ttk fonts to gitk fonts
  gitk: Update revision date in Japanese PO file
  gitk: Update "Language:" header
  gitk: Improve translation message
  gitk: Remove unused line
  gitk: Update year
  gitk: Change last translator line
  gitk: Update fuzzy messages
  gitk: Update Japanese translation
  gitk: Fix translation around copyright sign
  gitk: Update Japanese translation
  gitk: Fix wrong translation
  gitk: Translate Japanese catalog
  gitk: Translate more to Japanese catalog
  gitk: Update Japanese message catalog
  gitk: Re-sync line number in Japanese message catalogue
  gitk: Color name update

8 years agol10n: zh_CN: for git v2.7.0 l10n round 1
Jiang Xin [Sun, 15 Nov 2015 23:02:11 +0000 (07:02 +0800)]
l10n: zh_CN: for git v2.7.0 l10n round 1

Update 66 translations (2477t0f0u) for git v2.7.0-rc0.

Reviewed-by: Ray Chen <oldsharp@gmail.com>
Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
8 years agoMerge branch 'master' of git://github.com/alexhenrie/git-po
Jiang Xin [Sun, 20 Dec 2015 11:32:26 +0000 (19:32 +0800)]
Merge branch 'master' of git://github.com/alexhenrie/git-po

* 'master' of git://github.com/alexhenrie/git-po:
  l10n: ca.po: update translation

8 years agoMerge branch 'fr_v2.7.0' of git://github.com/jnavila/git
Jiang Xin [Sun, 20 Dec 2015 11:31:47 +0000 (19:31 +0800)]
Merge branch 'fr_v2.7.0' of git://github.com/jnavila/git

* 'fr_v2.7.0' of git://github.com/jnavila/git:
  l10n: fr v2.7.0 round 1 (2477t)

8 years agoMerge branch 'master' of git://github.com/alshopov/git-po
Jiang Xin [Sun, 20 Dec 2015 11:30:52 +0000 (19:30 +0800)]
Merge branch 'master' of git://github.com/alshopov/git-po

* 'master' of git://github.com/alshopov/git-po:
  l10n: Updated Bulgarian translation of git (2477t,0f,0u)

8 years agol10n: ca.po: update translation
Alex Henrie [Sat, 19 Dec 2015 06:38:23 +0000 (23:38 -0700)]
l10n: ca.po: update translation

Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
8 years agoMerge branch 'ja.po' of https://github.com/qykth-git/gitk
Paul Mackerras [Sat, 19 Dec 2015 02:33:16 +0000 (13:33 +1100)]
Merge branch 'ja.po' of https://github.com/qykth-git/gitk

8 years agoMerge branch 'color-fix' of https://github.com/qykth-git/gitk
Paul Mackerras [Sat, 19 Dec 2015 02:29:35 +0000 (13:29 +1100)]
Merge branch 'color-fix' of https://github.com/qykth-git/gitk

8 years agol10n: fr v2.7.0 round 1 (2477t)
Jean-Noel Avila [Fri, 18 Dec 2015 21:00:37 +0000 (22:00 +0100)]
l10n: fr v2.7.0 round 1 (2477t)

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
8 years agol10n: Updated Bulgarian translation of git (2477t,0f,0u)
Alexander Shopov [Sun, 13 Dec 2015 16:55:45 +0000 (18:55 +0200)]
l10n: Updated Bulgarian translation of git (2477t,0f,0u)

Signed-off-by: Alexander Shopov <ash@kambanaria.org>
8 years agol10n: sv.po: Update Swedish translation (2477t0f0u)
Peter Krefting [Fri, 18 Dec 2015 08:09:41 +0000 (09:09 +0100)]
l10n: sv.po: Update Swedish translation (2477t0f0u)

Signed-off-by: Peter Krefting <peter@softwolves.pp.se>
8 years agoMerge branch 'fr/rebase-i-continue-preserve-options'
Junio C Hamano [Wed, 16 Dec 2015 22:42:52 +0000 (14:42 -0800)]
Merge branch 'fr/rebase-i-continue-preserve-options'

"git rebase -i" started with merge strategy options did not
propagate them upon "git rebase --continue".

* fr/rebase-i-continue-preserve-options:
  rebase -i: remember merge options beyond continue actions

8 years agoMerge branch 'maint'
Junio C Hamano [Wed, 16 Dec 2015 22:40:30 +0000 (14:40 -0800)]
Merge branch 'maint'

* maint:
  credential-store: don't pass strerror to die_errno()

8 years agoMerge branch 'sg/lock-file-commit-error' into maint
Junio C Hamano [Wed, 16 Dec 2015 18:27:22 +0000 (10:27 -0800)]
Merge branch 'sg/lock-file-commit-error' into maint

* sg/lock-file-commit-error:
  credential-store: don't pass strerror to die_errno()

8 years agocredential-store: don't pass strerror to die_errno()
SZEDER Gábor [Wed, 16 Dec 2015 11:22:55 +0000 (12:22 +0100)]
credential-store: don't pass strerror to die_errno()

Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoformat-patch: check that header line has expected format
brian m. carlson [Tue, 15 Dec 2015 01:52:05 +0000 (01:52 +0000)]
format-patch: check that header line has expected format

The format of the "From " header line is very specific to allow
utilities to detect Git-style patches.  Add a test that the patches
created are in the expected format.

Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoformat-patch: add an option to suppress commit hash
brian m. carlson [Tue, 15 Dec 2015 01:52:04 +0000 (01:52 +0000)]
format-patch: add an option to suppress commit hash

Oftentimes, patches created by git format-patch will be stored in
version control or compared with diff.  In these cases, two otherwise
identical patches can have different commit hashes, leading to diff
noise.  Teach git format-patch a --zero-commit option that instead
produces an all-zero hash to avoid this diff noise.

Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoGit 2.7-rc1 v2.7.0-rc1
Junio C Hamano [Tue, 15 Dec 2015 17:47:11 +0000 (09:47 -0800)]
Git 2.7-rc1

Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoSync with maint
Junio C Hamano [Tue, 15 Dec 2015 17:45:06 +0000 (09:45 -0800)]
Sync with maint

8 years agoUpdate draft release notes to 2.6.5
Junio C Hamano [Tue, 15 Dec 2015 17:43:01 +0000 (09:43 -0800)]
Update draft release notes to 2.6.5

Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge branch 'dt/fsck-verify-pack-error' into maint
Junio C Hamano [Tue, 15 Dec 2015 17:42:16 +0000 (09:42 -0800)]
Merge branch 'dt/fsck-verify-pack-error' into maint

The exit code of git-fsck didnot reflect some types of errors found
in packed objects, which has been corrected.

* dt/fsck-verify-pack-error:
  verify_pack: do not ignore return value of verification function

8 years agoMerge branch 'ep/ident-with-getaddrinfo' into maint
Junio C Hamano [Tue, 15 Dec 2015 17:42:01 +0000 (09:42 -0800)]
Merge branch 'ep/ident-with-getaddrinfo' into maint

A fix-up for recent topic.

* ep/ident-with-getaddrinfo:
  ident: fix undefined variable when NO_IPV6 is set
  ident.c: add support for IPv6

8 years agoMerge branch 'ls/p4-keep-empty-commits' into maint
Junio C Hamano [Tue, 15 Dec 2015 17:34:18 +0000 (09:34 -0800)]
Merge branch 'ls/p4-keep-empty-commits' into maint

"git p4" used to import Perforce CLs that touch only paths outside
the client spec as empty commits.  It has been corrected to ignore
them instead, with a new configuration git-p4.keepEmptyCommits as a
backward compatibility knob.

* ls/p4-keep-empty-commits:
  git-p4: add option to keep empty commits

8 years agoMerge branch 'jk/send-email-complete-aliases'
Junio C Hamano [Tue, 15 Dec 2015 17:33:19 +0000 (09:33 -0800)]
Merge branch 'jk/send-email-complete-aliases'

A fix-up for recent topic.

* jk/send-email-complete-aliases:
  completion: fix completing unstuck email alias arguments

8 years agoMerge branch 'ep/ident-with-getaddrinfo'
Junio C Hamano [Tue, 15 Dec 2015 17:33:19 +0000 (09:33 -0800)]
Merge branch 'ep/ident-with-getaddrinfo'

A fix-up for recent topic.

* ep/ident-with-getaddrinfo:
  ident: fix undefined variable when NO_IPV6 is set

8 years agoMerge branch 'jk/prune-mtime' into maint
Junio C Hamano [Tue, 15 Dec 2015 17:27:11 +0000 (09:27 -0800)]
Merge branch 'jk/prune-mtime' into maint

The helper used to iterate over loose object directories to prune
stale objects did not closedir() immediately when it is done with a
directory--a callback such as the one used for "git prune" may want
to do rmdir(), but it would fail on open directory on platforms
such as WinXP.

* jk/prune-mtime:
  prune: close directory earlier during loose-object directory traversal

8 years agoMerge branch 'ls/p4-keep-empty-commits'
Junio C Hamano [Tue, 15 Dec 2015 16:02:18 +0000 (08:02 -0800)]
Merge branch 'ls/p4-keep-empty-commits'

"git p4" used to import Perforce CLs that touch only paths outside
the client spec as empty commits.  It has been corrected to ignore
them instead, with a new configuration git-p4.keepEmptyCommits as a
backward compatibility knob.

* ls/p4-keep-empty-commits:
  git-p4: add option to keep empty commits

8 years agoMerge branch 'jk/prune-mtime'
Junio C Hamano [Tue, 15 Dec 2015 16:02:13 +0000 (08:02 -0800)]
Merge branch 'jk/prune-mtime'

The helper used to iterate over loose object directories to prune
stale objects did not closedir() immediately when it is done with a
directory--a callback such as the one used for "git prune" may want
to do rmdir(), but it would fail on open directory on platforms
such as WinXP.

* jk/prune-mtime:
  prune: close directory earlier during loose-object directory traversal

8 years agocompletion: fix completing unstuck email alias arguments
SZEDER Gábor [Sat, 12 Dec 2015 00:18:18 +0000 (01:18 +0100)]
completion: fix completing unstuck email alias arguments

Completing unstuck form of email aliases doesn't quite work:

  $ git send-email --to <TAB>
  alice   bob     cecil
  $ git send-email --to a<TAB>
  alice   bob     cecil

While listing email aliases works as expected, the second case should
just complete to 'alice', but it keeps offering all email aliases
instead.

The cause for this behavior is that in this case we mistakenly tell
__gitcomp() explicitly that the current word to be completed is empty,
while in reality it is not.  As a result __gitcomp() doesn't filter
out non-matching aliases, so all aliases end up being offered over and
over again.

Fix this by not passing the current word to be completed to
__gitcomp() and letting it go the default route and grab it from the
'$cur' variable.  Don't pass empty prefix either, because it's assumed
to be empty when unspecified, so it's not necessary.

Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agosha1_file.c: introduce a null_oid constant
brian m. carlson [Sun, 6 Dec 2015 22:16:35 +0000 (22:16 +0000)]
sha1_file.c: introduce a null_oid constant

null_oid is the struct object_id equivalent to null_sha1.

Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoident: fix undefined variable when NO_IPV6 is set
Jeff King [Mon, 14 Dec 2015 20:52:41 +0000 (15:52 -0500)]
ident: fix undefined variable when NO_IPV6 is set

Commit 00bce77 (ident.c: add support for IPv6, 2015-11-27)
moved the "gethostbyname" call out of "add_domainname" and
into the helper function "canonical_name". But when moving
the code, it forgot that the "buf" variable is passed as
"host" in the helper.

Reported-by: johan defries <johandefries@gmail.com>
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoident: loosen getpwuid error in non-strict mode
Jeff King [Thu, 10 Dec 2015 21:41:29 +0000 (16:41 -0500)]
ident: loosen getpwuid error in non-strict mode

If the user has not specified an identity and we have to
turn to getpwuid() to find the username or gecos field, we
die immediately when getpwuid fails (e.g., because the user
does not exist). This is OK for making a commit, where we
have set IDENT_STRICT and would want to bail on bogus input.

But for something like a reflog, where the ident is "best
effort", it can be pain. For instance, even running "git
clone" with a UID that is not in /etc/passwd will result in
git barfing, just because we can't find an ident to put in
the reflog.

Instead of dying in xgetpwuid_self, we can instead return a
fallback value, and set a "bogus" flag. For the username in
an email, we already have a "default_email_is_bogus" flag.
For the name field, we introduce (and check) a matching
"default_name_is_bogus" flag. As a bonus, this means you now
get the usual "tell me who you are" advice instead of just a
"no such user" error.

No tests, as this is dependent on configuration outside of
git's control. However, I did confirm that it behaves
sensibly when I delete myself from the local /etc/passwd
(reflogs get written, and commits complain).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agol10n: vi.po: Updated translation (2477t)
Tran Ngoc Quan [Sat, 12 Dec 2015 07:34:08 +0000 (14:34 +0700)]
l10n: vi.po: Updated translation (2477t)

Signed-off-by: Tran Ngoc Quan <vnwildman@gmail.com>
8 years agogitk: sv.po: Update Swedish translation (311t)
Peter Krefting [Fri, 11 Dec 2015 08:49:21 +0000 (09:49 +0100)]
gitk: sv.po: Update Swedish translation (311t)

Signed-off-by: Peter Krefting <peter@softwolves.pp.se>
Signed-off-by: Paul Mackerras <paulus@samba.org>
8 years agogitk: Let .bleft.mid widgets 'breathe'
Giuseppe Bilotta [Tue, 8 Dec 2015 07:05:51 +0000 (08:05 +0100)]
gitk: Let .bleft.mid widgets 'breathe'

The widgets on top of the diff window are very tightly packed. Make
them breathe a little by adding an 'i'-spaced padding between them.

Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
8 years agogitk: Match ttk fonts to gitk fonts
Giuseppe Bilotta [Tue, 8 Dec 2015 07:05:50 +0000 (08:05 +0100)]
gitk: Match ttk fonts to gitk fonts

The fonts set in setoptions aren't consistently picked up by ttk, which
uses its own predefined fonts. This is noticeable when switching
between using and not using ttk with custom fonts or in HiDPI settings
(where the default TTK fonts do _not_ respect tk sclaing).

Fix by mapping the ttk fontset to the one used by gitk internally.

Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
8 years agorebase -i: remember merge options beyond continue actions
Fabian Ruch [Fri, 11 Dec 2015 20:30:36 +0000 (21:30 +0100)]
rebase -i: remember merge options beyond continue actions

If the user explicitly specified a merge strategy or strategy
options, continue to use that strategy/option after
"rebase --continue".  Add a test of the corrected behavior.

If --merge is specified or implied by -s or -X, then "strategy and
"strategy_opts" are set to values from which "strategy_args" can be
derived; otherwise they are set to empty strings.  Either way,
their values are propagated from one step of an interactive rebase
to the next via state files.

"do_merge", on the other hand, is *not* propagated to later steps of
an interactive rebase.  Therefore, making the initialization of
"strategy_args" conditional on "do_merge" being set prevents later
steps of an interactive rebase from setting it correctly.

Luckily, we don't need the "do_merge" guard at all.  If the rebase
was started without --merge, then "strategy" and "strategy_opts"
are both the empty string, which results in "strategy_args" also
being set to the empty string, which is just what we want in that
situation.  So remove the "do_merge" guard and derive
"strategy_args" from "strategy" and "strategy_opts" every time.

Reported-by: Diogo de Campos <campos@esss.com.br>
Signed-off-by: Fabian Ruch <bafain@gmail.com>
Helped-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agocompletion: remove 'git column' from porcelain commands
SZEDER Gábor [Fri, 11 Dec 2015 12:05:00 +0000 (13:05 +0100)]
completion: remove 'git column' from porcelain commands

'git column' is an internal helper, so it should not be offered on
'git <TAB>' along with porcelain commands.

Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoUpdate release notes to 2.7
Junio C Hamano [Fri, 11 Dec 2015 18:45:44 +0000 (10:45 -0800)]
Update release notes to 2.7

Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge branch 'maint'
Junio C Hamano [Fri, 11 Dec 2015 19:19:43 +0000 (11:19 -0800)]
Merge branch 'maint'

* maint:
  Prepare for 2.6.5

8 years agoPrepare for 2.6.5
Junio C Hamano [Fri, 11 Dec 2015 19:17:47 +0000 (11:17 -0800)]
Prepare for 2.6.5

This back-merges hopefully the last batch of trivially correct fixes
to the 2.6.x maintenance track from the master branch.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge branch 'sn/null-pointer-arith-in-mark-tree-uninteresting' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:38 +0000 (11:14 -0800)]
Merge branch 'sn/null-pointer-arith-in-mark-tree-uninteresting' into maint

mark_tree_uninteresting() has code to handle the case where it gets
passed a NULL pointer in its 'tree' parameter, but the function had
'object = &tree->object' assignment before checking if tree is
NULL.  This gives a compiler an excuse to declare that tree will
never be NULL and apply a wrong optimization.  Avoid it.

* sn/null-pointer-arith-in-mark-tree-uninteresting:
  revision.c: fix possible null pointer arithmetic

8 years agoMerge branch 'sg/lock-file-commit-error' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:18 +0000 (11:14 -0800)]
Merge branch 'sg/lock-file-commit-error' into maint

Cosmetic improvement to lock-file error messages.

* sg/lock-file-commit-error:
  Make error message after failing commit_lock_file() less confusing

8 years agoMerge branch 'cb/t3404-shellquote' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:18 +0000 (11:14 -0800)]
Merge branch 'cb/t3404-shellquote' into maint

* cb/t3404-shellquote:
  t3404: fix quoting of redirect for some versions of bash

8 years agoMerge branch 'sb/doc-submodule-sync-recursive' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:17 +0000 (11:14 -0800)]
Merge branch 'sb/doc-submodule-sync-recursive' into maint

* sb/doc-submodule-sync-recursive:
  document submodule sync --recursive

8 years agoMerge branch 'nd/doc-check-ref-format-typo' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:15 +0000 (11:14 -0800)]
Merge branch 'nd/doc-check-ref-format-typo' into maint

* nd/doc-check-ref-format-typo:
  git-check-ref-format.txt: typo, s/avoids/avoid/

8 years agoMerge branch 'rs/show-branch-argv-array' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:13 +0000 (11:14 -0800)]
Merge branch 'rs/show-branch-argv-array' into maint

Code simplification.

* rs/show-branch-argv-array:
  show-branch: use argv_array for default arguments

8 years agoMerge branch 'rs/pop-commit' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:12 +0000 (11:14 -0800)]
Merge branch 'rs/pop-commit' into maint

Code simplification.

* rs/pop-commit:
  use pop_commit() for consuming the first entry of a struct commit_list

8 years agoMerge branch 'as/subtree-with-spaces' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:11 +0000 (11:14 -0800)]
Merge branch 'as/subtree-with-spaces' into maint

Update "git subtree" (in contrib/) so that it can take whitespaces
in the pathnames, not only in the in-tree pathname but the name of
the directory that the repository is in.

* as/subtree-with-spaces:
  contrib/subtree: respect spaces in a repository path
  t7900-subtree: test the "space in a subdirectory name" case

8 years agoMerge branch 'jk/test-lint-forbid-when-finished-in-subshell' into maint
Junio C Hamano [Fri, 11 Dec 2015 19:14:09 +0000 (11:14 -0800)]
Merge branch 'jk/test-lint-forbid-when-finished-in-subshell' into maint

Because "test_when_finished" in our test framework queues the
clean-up tasks to be done in a shell variable, it should not be
used inside a subshell.  Add a mechanism to allow 'bash' to catch
such uses, and fix the ones that were found.

* jk/test-lint-forbid-when-finished-in-subshell:
  test-lib-functions: detect test_when_finished in subshell
  t7800: don't use test_config in a subshell
  test-lib-functions: support "test_config -C <dir> ..."
  t5801: don't use test_when_finished in a subshell
  t7610: don't use test_config in a subshell

8 years agoMerge branch 'sn/null-pointer-arith-in-mark-tree-uninteresting'
Junio C Hamano [Fri, 11 Dec 2015 18:41:01 +0000 (10:41 -0800)]
Merge branch 'sn/null-pointer-arith-in-mark-tree-uninteresting'

mark_tree_uninteresting() has code to handle the case where it gets
passed a NULL pointer in its 'tree' parameter, but the function had
'object = &tree->object' assignment before checking if tree is
NULL.  This gives a compiler an excuse to declare that tree will
never be NULL and apply a wrong optimization.  Avoid it.

* sn/null-pointer-arith-in-mark-tree-uninteresting:
  revision.c: fix possible null pointer arithmetic

8 years agoMerge branch 'sb/doc-submodule-sync-recursive'
Junio C Hamano [Fri, 11 Dec 2015 18:40:59 +0000 (10:40 -0800)]
Merge branch 'sb/doc-submodule-sync-recursive'

* sb/doc-submodule-sync-recursive:
  document submodule sync --recursive

8 years agoMerge branch 'cb/t3404-shellquote'
Junio C Hamano [Fri, 11 Dec 2015 18:40:57 +0000 (10:40 -0800)]
Merge branch 'cb/t3404-shellquote'

* cb/t3404-shellquote:
  t3404: fix quoting of redirect for some versions of bash

8 years agoMerge branch 'sg/lock-file-commit-error'
Junio C Hamano [Fri, 11 Dec 2015 18:40:54 +0000 (10:40 -0800)]
Merge branch 'sg/lock-file-commit-error'

Cosmetic improvement to lock-file error messages.

* sg/lock-file-commit-error:
  Make error message after failing commit_lock_file() less confusing

8 years agosend-email: enable SSL level 1 debug output
John Keeping [Thu, 3 Dec 2015 21:47:18 +0000 (21:47 +0000)]
send-email: enable SSL level 1 debug output

If a server's certificate isn't accepted by send-email, the output is:

Unable to initialize SMTP properly. Check config and use --smtp-debug.

but adding --smtp-debug=1 just produces the same output since we don't
get as far as talking SMTP.

Turning on SSL debug at level 1 gives:

DEBUG: .../IO/Socket/SSL.pm:1796: SSL connect attempt failed error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed
DEBUG: .../IO/Socket/SSL.pm:673: fatal SSL error: SSL connect attempt failed error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed
DEBUG: .../IO/Socket/SSL.pm:1780: IO::Socket::IP configuration failed

IO::Socket::SSL defines level 1 debug as "print out errors from
IO::Socket::SSL and ciphers from Net::SSLeay".  In fact, it aliases
Net::SSLeay::trace which is defined to guarantee silence at level 0 and
only emit error messages at level 1, so let's enable it by default.

The modification of warnings is needed to avoid a warning about:

Name "IO::Socket::SSL::DEBUG" used only once: possible typo

Signed-off-by: John Keeping <john@keeping.me.uk>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agol10n: git.pot: v2.7.0 round 1 (66 new, 29 removed)
Jiang Xin [Fri, 11 Dec 2015 15:37:11 +0000 (23:37 +0800)]
l10n: git.pot: v2.7.0 round 1 (66 new, 29 removed)

Generate po/git.pot from v2.7.0-rc0 for git v2.7.0 l10n round 1.

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
8 years agoMerge branch 'master' of git://github.com/git-l10n/git-po
Jiang Xin [Fri, 11 Dec 2015 15:33:45 +0000 (23:33 +0800)]
Merge branch 'master' of git://github.com/git-l10n/git-po

* 'master' of git://github.com/git-l10n/git-po:
  l10n: fr.po: Fix typo
  l10n: fr.po: Fix typo

8 years agoident: keep a flag for bogus default_email
Jeff King [Thu, 10 Dec 2015 21:35:36 +0000 (16:35 -0500)]
ident: keep a flag for bogus default_email

If we have to deduce the user's email address and can't come
up with something plausible for the hostname, we simply
write "(none)" or ".(none)" in the hostname.

Later, our strict-check is forced to use strstr to look for
this magic string. This is probably not a problem in
practice, but it's rather ugly. Let's keep an extra flag
that tells us the email is bogus, and check that instead.

We could get away with simply setting the global in
add_domainname(); it only gets called to write into
git_default_email. However, let's make the code a little
more obvious to future readers by actually passing a pointer
to our "bogus" flag down the call-chain.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoident: make xgetpwuid_self() a static local helper
Jeff King [Thu, 10 Dec 2015 21:33:05 +0000 (16:33 -0500)]
ident: make xgetpwuid_self() a static local helper

This function is defined in wrapper.c, but nobody besides
ident.c uses it. And nobody is likely to in the future,
either, as anything that cares about the user's name should
be going through the ident code.

Moving it here is a cleanup of the global namespace, but it
will also enable further cleanups inside ident.c.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoGit 2.7-rc0 v2.7.0-rc0
Junio C Hamano [Thu, 10 Dec 2015 20:59:37 +0000 (12:59 -0800)]
Git 2.7-rc0

Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoSync with maint
Junio C Hamano [Thu, 10 Dec 2015 20:45:17 +0000 (12:45 -0800)]
Sync with maint

* maint:
  Documentation/git-update-index: add missing opts to synopsis

8 years agoUpdate release notes to 2.7
Junio C Hamano [Thu, 10 Dec 2015 20:43:52 +0000 (12:43 -0800)]
Update release notes to 2.7

Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge branch 'nd/doc-check-ref-format-typo'
Junio C Hamano [Thu, 10 Dec 2015 20:36:15 +0000 (12:36 -0800)]
Merge branch 'nd/doc-check-ref-format-typo'

* nd/doc-check-ref-format-typo:
  git-check-ref-format.txt: typo, s/avoids/avoid/

8 years agoMerge branch 'bc/object-id'
Junio C Hamano [Thu, 10 Dec 2015 20:36:13 +0000 (12:36 -0800)]
Merge branch 'bc/object-id'

More transition from "unsigned char[40]" to "struct object_id".

This needed a few merge fixups, but is mostly disentangled from other
topics.

* bc/object-id:
  remote: convert functions to struct object_id
  Remove get_object_hash.
  Convert struct object to object_id
  Add several uses of get_object_hash.
  object: introduce get_object_hash macro.
  ref_newer: convert to use struct object_id
  push_refs_with_export: convert to struct object_id
  get_remote_heads: convert to struct object_id
  parse_fetch: convert to use struct object_id
  add_sought_entry_mem: convert to struct object_id
  Convert struct ref to use object_id.
  sha1_file: introduce has_object_file helper.

8 years agoMerge branch 'dt/fsck-verify-pack-error'
Junio C Hamano [Thu, 10 Dec 2015 20:36:12 +0000 (12:36 -0800)]
Merge branch 'dt/fsck-verify-pack-error'

The exit code of git-fsck didnot reflect some types of errors found
in packed objects, which has been corrected.

* dt/fsck-verify-pack-error:
  verify_pack: do not ignore return value of verification function

8 years agoMerge branch 'ls/travis-yaml'
Junio C Hamano [Thu, 10 Dec 2015 20:36:12 +0000 (12:36 -0800)]
Merge branch 'ls/travis-yaml'

The necessary infrastructure to build topics using the free Travis
CI has been added. Developers forking from this topic (and enabling
Travis) can do their own builds, and we can turn on auto-builds for
git/git (including build-status for pull requests that people
open).

* ls/travis-yaml:
  Add Travis CI support

8 years agoDocumentation/git-update-index: add missing opts to synopsis
Christian Couder [Wed, 25 Nov 2015 09:30:02 +0000 (10:30 +0100)]
Documentation/git-update-index: add missing opts to synopsis

Split index related options should appear in the 'SYNOPSIS'
section.

These options are already documented in the 'OPTIONS' section.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agogit-p4: add option to keep empty commits
Lars Schneider [Tue, 8 Dec 2015 09:36:22 +0000 (10:36 +0100)]
git-p4: add option to keep empty commits

A changelist that contains only excluded files due to a client spec was
imported as an empty commit. Fix that issue by ignoring these commits.
Add option "git-p4.keepEmptyCommits" to make the previous behavior
available.

Signed-off-by: Lars Schneider <larsxschneider@gmail.com>
Helped-by: Pete Harlan
Acked-by: Luke Diamand <luke@diamand.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 years agoMerge branch 'ep/ident-with-getaddrinfo'
Junio C Hamano [Tue, 8 Dec 2015 22:14:50 +0000 (14:14 -0800)]
Merge branch 'ep/ident-with-getaddrinfo'

A build without NO_IPv6 used to use gethostbyname() when guessing
user's hostname, instead of getaddrinfo() that is used in other
codepaths in such a build.

* ep/ident-with-getaddrinfo:
  ident.c: add support for IPv6