gitweb.git
worktree: stop supporting moving worktrees manuallyNguyễn Thái Ngọc Duy Fri, 22 Jan 2016 08:35:49 +0000 (15:35 +0700)

worktree: stop supporting moving worktrees manually

The current update_linked_gitdir() has a bug that can create "gitdir"
file in non-multi-worktree setup. Worse, sometimes it can write relative
path to "gitdir" file, which will not work (e.g. "git worktree list"
will display the worktree's location incorrectly)

Instead of fixing this, we step back a bit. The original design was
probably not well thought out. For now, if the user manually moves a
worktree, they have to fix up "gitdir" file manually or the worktree
will get pruned.

Helped-by: Eric Sunshine <sunshine@sunshineco.com>
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

worktree.c: fix indentationNguyễn Thái Ngọc Duy Mon, 18 Jan 2016 11:21:29 +0000 (18:21 +0700)

worktree.c: fix indentation

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'mr/worktree-list'Junio C Hamano Mon, 26 Oct 2015 22:55:16 +0000 (15:55 -0700)

Merge branch 'mr/worktree-list'

Add the "list" subcommand to "git worktree".

* mr/worktree-list:
worktree: add 'list' command
worktree: add details to the worktree struct
worktree: add a function to get worktree details
worktree: refactor find_linked_symref function
worktree: add top-level worktree.c

Merge branch 'jc/am-3-fallback-regression-fix'Junio C Hamano Mon, 26 Oct 2015 22:55:15 +0000 (15:55 -0700)

Merge branch 'jc/am-3-fallback-regression-fix'

"git am -3" had a small regression where it is aborted in its error
handling codepath when underlying merge-recursive failed in certain
ways, as it assumed that the internal call to merge-recursive will
never die, which is not the case (yet).

* jc/am-3-fallback-regression-fix:
am -3: do not let failed merge from completing the error codepath

Sync with maintJunio C Hamano Tue, 20 Oct 2015 22:29:57 +0000 (15:29 -0700)

Sync with maint

* maint:

Sixth batch for 2.7Junio C Hamano Tue, 20 Oct 2015 22:29:50 +0000 (15:29 -0700)

Sixth batch for 2.7

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'tb/t0027-crlf'Junio C Hamano Tue, 20 Oct 2015 22:26:18 +0000 (15:26 -0700)

Merge branch 'tb/t0027-crlf'

The test for various line-ending conversions has been enhanced.

* tb/t0027-crlf:
t0027: improve test for not-normalized files

Merge branch 'ls/p4-test-updates'Junio C Hamano Tue, 20 Oct 2015 22:26:09 +0000 (15:26 -0700)

Merge branch 'ls/p4-test-updates'

A few test scripts around "git p4" have been improved for
portability.

* ls/p4-test-updates:
git-p4: skip t9819 test case on case insensitive file systems
git-p4: avoid "stat" command in t9815 git-p4-submit-fail

Merge branch 'jk/war-on-sprintf'Junio C Hamano Tue, 20 Oct 2015 22:24:00 +0000 (15:24 -0700)

Merge branch 'jk/war-on-sprintf'

Many allocations that is manually counted (correctly) that are
followed by strcpy/sprintf have been replaced with a less error
prone constructs such as xstrfmt.

Macintosh-specific breakage was noticed and corrected in this
reroll.

* jk/war-on-sprintf: (70 commits)
name-rev: use strip_suffix to avoid magic numbers
use strbuf_complete to conditionally append slash
fsck: use for_each_loose_file_in_objdir
Makefile: drop D_INO_IN_DIRENT build knob
fsck: drop inode-sorting code
convert strncpy to memcpy
notes: document length of fanout path with a constant
color: add color_set helper for copying raw colors
prefer memcpy to strcpy
help: clean up kfmclient munging
receive-pack: simplify keep_arg computation
avoid sprintf and strcpy with flex arrays
use alloc_ref rather than hand-allocating "struct ref"
color: add overflow checks for parsing colors
drop strcpy in favor of raw sha1_to_hex
use sha1_to_hex_r() instead of strcpy
daemon: use cld->env_array when re-spawning
stat_tracking_info: convert to argv_array
http-push: use an argv_array for setup_revisions
fetch-pack: use argv_array for index-pack / unpack-objects
...

Merge branch 'js/gc-with-stale-symref' into maintJunio C Hamano Tue, 20 Oct 2015 22:22:41 +0000 (15:22 -0700)

Merge branch 'js/gc-with-stale-symref' into maint

"git gc" used to barf when a symbolic ref has gone dangling
(e.g. the branch that used to be your upstream's default when you
cloned from it is now gone, and you did "fetch --prune").

* js/gc-with-stale-symref:
pack-objects: do not get distracted by broken symrefs
gc: demonstrate failure with stale remote HEAD

Merge branch 'rd/test-path-utils' into maintJunio C Hamano Tue, 20 Oct 2015 22:22:40 +0000 (15:22 -0700)

Merge branch 'rd/test-path-utils' into maint

The normalize_ceiling_entry() function does not muck with the end
of the path it accepts, and the real world callers do rely on that,
but a test insisted that the function drops a trailing slash.

* rd/test-path-utils:
test-path-utils.c: remove incorrect assumption

Merge branch 'jc/doc-gc-prune-now' into maintJunio C Hamano Tue, 20 Oct 2015 22:22:40 +0000 (15:22 -0700)

Merge branch 'jc/doc-gc-prune-now' into maint

"git gc" is safe to run anytime only because it has the built-in
grace period to protect young objects. In order to run with no
grace period, the user must make sure that the repository is
quiescent.

* jc/doc-gc-prune-now:
Documentation/gc: warn against --prune=<now>

Merge branch 'jk/filter-branch-use-of-sed-on-incomplete... Junio C Hamano Tue, 20 Oct 2015 22:22:39 +0000 (15:22 -0700)

Merge branch 'jk/filter-branch-use-of-sed-on-incomplete-line' into maint

A recent "filter-branch --msg-filter" broke skipping of the commit
object header, which is fixed.

* jk/filter-branch-use-of-sed-on-incomplete-line:
filter-branch: remove multi-line headers in msg filter

Sync with maint for Russian translationJunio C Hamano Mon, 19 Oct 2015 06:39:20 +0000 (23:39 -0700)

Sync with maint for Russian translation

* maint:
l10n: ru.po: update Russian translation

Merge branch 'maint' of git://github.com/git-l10n/git... Junio C Hamano Mon, 19 Oct 2015 06:37:35 +0000 (23:37 -0700)

Merge branch 'maint' of git://github.com/git-l10n/git-po into maint

* 'maint' of git://github.com/git-l10n/git-po:
l10n: ru.po: update Russian translation

Sync with 2.6.2Junio C Hamano Fri, 16 Oct 2015 21:45:46 +0000 (14:45 -0700)

Sync with 2.6.2

Fifth batch for 2.7Junio C Hamano Fri, 16 Oct 2015 21:43:59 +0000 (14:43 -0700)

Fifth batch for 2.7

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'jc/doc-gc-prune-now'Junio C Hamano Fri, 16 Oct 2015 21:42:50 +0000 (14:42 -0700)

Merge branch 'jc/doc-gc-prune-now'

"git gc" is safe to run anytime only because it has the built-in
grace period to protect young objects. In order to run with no
grace period, the user must make sure that the repository is
quiescent.

* jc/doc-gc-prune-now:
Documentation/gc: warn against --prune=<now>

Merge branch 'sb/submodule-config-parse'Junio C Hamano Fri, 16 Oct 2015 21:42:49 +0000 (14:42 -0700)

Merge branch 'sb/submodule-config-parse'

Code simplification.

* sb/submodule-config-parse:
submodule-config: "goto" removal in parse_config()

Merge branch 'jk/filter-branch-use-of-sed-on-incomplete... Junio C Hamano Fri, 16 Oct 2015 21:42:47 +0000 (14:42 -0700)

Merge branch 'jk/filter-branch-use-of-sed-on-incomplete-line'

A recent "filter-branch --msg-filter" broke skipping of the commit
object header, which is fixed.

* jk/filter-branch-use-of-sed-on-incomplete-line:
filter-branch: remove multi-line headers in msg filter

Merge branch 'rd/test-path-utils'Junio C Hamano Fri, 16 Oct 2015 21:42:44 +0000 (14:42 -0700)

Merge branch 'rd/test-path-utils'

The normalize_ceiling_entry() function does not muck with the end
of the path it accepts, and the real world callers do rely on that,
but a test insisted that the function drops a trailing slash.

* rd/test-path-utils:
test-path-utils.c: remove incorrect assumption

Git 2.6.2 v2.6.2Junio C Hamano Fri, 16 Oct 2015 21:40:04 +0000 (14:40 -0700)

Git 2.6.2

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'cc/quote-comments' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:58 +0000 (14:32 -0700)

Merge branch 'cc/quote-comments' into maint

A no-op code-health maintenance.

* cc/quote-comments:
quote: move comment before sq_quote_buf()
quote: fix broken sq_quote_buf() related comment

Merge branch 'es/worktree-add-cleanup' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:57 +0000 (14:32 -0700)

Merge branch 'es/worktree-add-cleanup' into maint

A no-op code-health maintenance.

* es/worktree-add-cleanup:
t2026: rename worktree prune test

Merge branch 'tk/doc-interpret-trailers-grammo' into... Junio C Hamano Fri, 16 Oct 2015 21:32:56 +0000 (14:32 -0700)

Merge branch 'tk/doc-interpret-trailers-grammo' into maint

* tk/doc-interpret-trailers-grammo:
Documentation/interpret-trailers: Grammar fix

Merge branch 'tk/typofix-connect-unknown-proto-error... Junio C Hamano Fri, 16 Oct 2015 21:32:55 +0000 (14:32 -0700)

Merge branch 'tk/typofix-connect-unknown-proto-error' into maint

* tk/typofix-connect-unknown-proto-error:
connect: fix typo in result string of prot_name()

Merge branch 'jk/asciidoctor-section-heading-markup... Junio C Hamano Fri, 16 Oct 2015 21:32:53 +0000 (14:32 -0700)

Merge branch 'jk/asciidoctor-section-heading-markup-fix' into maint

* jk/asciidoctor-section-heading-markup-fix:
Documentation: fix section header mark-up

Merge branch 'nd/ls-remote-does-not-have-u-option'... Junio C Hamano Fri, 16 Oct 2015 21:32:52 +0000 (14:32 -0700)

Merge branch 'nd/ls-remote-does-not-have-u-option' into maint

* nd/ls-remote-does-not-have-u-option:
ls-remote.txt: delete unsupported option

Merge branch 'jc/fsck-dropped-errors' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:50 +0000 (14:32 -0700)

Merge branch 'jc/fsck-dropped-errors' into maint

There were some classes of errors that "git fsck" diagnosed to its
standard error that did not cause it to exit with non-zero status.

* jc/fsck-dropped-errors:
fsck: exit with non-zero when problems are found

Merge branch 'sb/http-flaky-test-fix' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:49 +0000 (14:32 -0700)

Merge branch 'sb/http-flaky-test-fix' into maint

A test script for the HTTP service had a timing dependent bug,
which was fixed.

* sb/http-flaky-test-fix:
t5561: get rid of racy appending to logfile

Merge branch 'sb/perf-without-installed-git' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:47 +0000 (14:32 -0700)

Merge branch 'sb/perf-without-installed-git' into maint

Performance-measurement tests did not work without an installed Git.

* sb/perf-without-installed-git:
t/perf: make runner work even if Git is not installed

Merge branch 'js/icase-wt-detection' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:46 +0000 (14:32 -0700)

Merge branch 'js/icase-wt-detection' into maint

On a case insensitive filesystems, setting GIT_WORK_TREE variable
using a random cases that does not agree with what the filesystem
thinks confused Git that it wasn't inside the working tree.

* js/icase-wt-detection:
setup: fix "inside work tree" detection on case-insensitive filesystems

Merge branch 'pt/am-builtin' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:45 +0000 (14:32 -0700)

Merge branch 'pt/am-builtin' into maint

When "git am" was rewritten as a built-in, it stopped paying
attention to user.signingkey, which was fixed.

* pt/am-builtin:
am: configure gpg at startup

Merge branch 'mm/detach-at-HEAD-reflog' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:44 +0000 (14:32 -0700)

Merge branch 'mm/detach-at-HEAD-reflog' into maint

After "git checkout --detach", "git status" reported a fairly
useless "HEAD detached at HEAD", instead of saying at which exact
commit.

* mm/detach-at-HEAD-reflog:
status: don't say 'HEAD detached at HEAD'
t3203: test 'detached at' after checkout --detach

Merge branch 'gr/rebase-i-drop-warn' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:43 +0000 (14:32 -0700)

Merge branch 'gr/rebase-i-drop-warn' into maint

"git rebase -i" had a minor regression recently, which stopped
considering a line that begins with an indented '#' in its insn
sheet not a comment, which is now fixed.

* gr/rebase-i-drop-warn:
rebase-i: loosen over-eager check_bad_cmd check
rebase-i: explicitly accept tab as separator in commands

Merge branch 'dt/log-follow-config' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:42 +0000 (14:32 -0700)

Merge branch 'dt/log-follow-config' into maint

Description of the "log.follow" configuration variable in "git log"
documentation is now also copied to "git config" documentation.

* dt/log-follow-config:
log: Update log.follow doc and add to config.txt

Merge branch 'ti/glibc-stdio-mutex-from-signal-handler... Junio C Hamano Fri, 16 Oct 2015 21:32:41 +0000 (14:32 -0700)

Merge branch 'ti/glibc-stdio-mutex-from-signal-handler' into maint

Allocation related functions and stdio are unsafe things to call
inside a signal handler, and indeed killing the pager can cause
glibc to deadlock waiting on allocation mutex as our signal handler
tries to free() some data structures in wait_for_pager(). Reduce
these unsafe calls.

* ti/glibc-stdio-mutex-from-signal-handler:
pager: don't use unsafe functions in signal handlers

Merge branch 'jk/notes-dwim-doc' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:40 +0000 (14:32 -0700)

Merge branch 'jk/notes-dwim-doc' into maint

The way how --ref/--notes to specify the notes tree reference are
DWIMmed was not clearly documented.

* jk/notes-dwim-doc:
notes: correct documentation of DWIMery for notes references

Merge branch 'jk/make-findstring-makeflags-fix' into... Junio C Hamano Fri, 16 Oct 2015 21:32:38 +0000 (14:32 -0700)

Merge branch 'jk/make-findstring-makeflags-fix' into maint

Customization to change the behaviour with "make -w" and "make -s"
in our Makefile was broken when they were used together.

* jk/make-findstring-makeflags-fix:
Makefile: fix MAKEFLAGS tests with multiple flags

Merge branch 'jw/make-arflags-customizable' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:36 +0000 (14:32 -0700)

Merge branch 'jw/make-arflags-customizable' into maint

The Makefile always runs the library archiver with hardcoded "crs"
options, which was inconvenient for exotic platforms on which
people want to use programs with totally different set of command
line options.

* jw/make-arflags-customizable:
Makefile: allow $(ARFLAGS) specified from the command line

Merge branch 'jk/connect-clear-env' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:35 +0000 (14:32 -0700)

Merge branch 'jk/connect-clear-env' into maint

The ssh transport, just like any other transport over the network,
did not clear GIT_* environment variables, but it is possible to
use SendEnv and AcceptEnv to leak them to the remote invocation of
Git, which is not a good idea at all. Explicitly clear them just
like we do for the local transport.

* jk/connect-clear-env:
git_connect: clarify conn->use_shell flag
git_connect: clear GIT_* environment for ssh

Merge branch 'jk/blame-first-parent' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:34 +0000 (14:32 -0700)

Merge branch 'jk/blame-first-parent' into maint

"git blame --first-parent v1.0..v2.0" was not rejected but did not
limit the blame to commits on the first parent chain.

* jk/blame-first-parent:
blame: handle --first-parent

Merge branch 'mm/keyid-docs' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:33 +0000 (14:32 -0700)

Merge branch 'mm/keyid-docs' into maint

Very small number of options take a parameter that is optional
(which is not a great UI element as they can only appear at the end
of the command line). Add notice to documentation of each and
every one of them.

* mm/keyid-docs:
Documentation: explain optional arguments better
Documentation/grep: fix documentation of -O
Documentation: use 'keyid' consistently, not 'key-id'

Merge branch 'pt/pull-builtin' into maintJunio C Hamano Fri, 16 Oct 2015 21:32:32 +0000 (14:32 -0700)

Merge branch 'pt/pull-builtin' into maint

* pt/pull-builtin:
pull: enclose <options> in brackets in the usage string
merge: grammofix in please-commit-before-merge message

pull: enclose <options> in brackets in the usage stringAlex Henrie Fri, 16 Oct 2015 02:22:13 +0000 (20:22 -0600)

pull: enclose <options> in brackets in the usage string

All the other placeholders are already shown that way.

Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Fourth batch for 2.7Junio C Hamano Thu, 15 Oct 2015 22:48:56 +0000 (15:48 -0700)

Fourth batch for 2.7

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'ls/p4-lfs'Junio C Hamano Thu, 15 Oct 2015 22:43:52 +0000 (15:43 -0700)

Merge branch 'ls/p4-lfs'

Teach "git p4" to send large blobs outside the repository by
talking to Git LFS.

* ls/p4-lfs:
git-p4: add Git LFS backend for large file system
git-p4: add support for large file systems
git-p4: check free space during streaming
git-p4: add file streaming progress in verbose mode
git-p4: return an empty list if a list config has no values
git-p4: add gitConfigInt reader
git-p4: add optional type specifier to gitConfig reader

Merge branch 'js/gc-with-stale-symref'Junio C Hamano Thu, 15 Oct 2015 22:43:51 +0000 (15:43 -0700)

Merge branch 'js/gc-with-stale-symref'

"git gc" used to barf when a symbolic ref has gone dangling
(e.g. the branch that used to be your upstream's default when you
cloned from it is now gone, and you did "fetch --prune").

* js/gc-with-stale-symref:
pack-objects: do not get distracted by broken symrefs
gc: demonstrate failure with stale remote HEAD

Merge branch 'js/clone-dissociate'Junio C Hamano Thu, 15 Oct 2015 22:43:49 +0000 (15:43 -0700)

Merge branch 'js/clone-dissociate'

"git clone --dissociate" runs a big "git repack" process at the
end, and it helps to close file descriptors that are open on the
packs and their idx files before doing so on filesystems that
cannot remove a file that is still open.

* js/clone-dissociate:
clone --dissociate: avoid locking pack files
sha1_file.c: add a function to release all packs
sha1_file: consolidate code to close a pack's file descriptor
t5700: demonstrate a Windows file locking issue with `git clone --dissociate`

Merge branch 'tk/doc-interpret-trailers-grammo'Junio C Hamano Thu, 15 Oct 2015 22:43:48 +0000 (15:43 -0700)

Merge branch 'tk/doc-interpret-trailers-grammo'

* tk/doc-interpret-trailers-grammo:
Documentation/interpret-trailers: Grammar fix

Merge branch 'es/worktree-add-cleanup'Junio C Hamano Thu, 15 Oct 2015 22:43:47 +0000 (15:43 -0700)

Merge branch 'es/worktree-add-cleanup'

A no-op code-health maintenance.

* es/worktree-add-cleanup:
t2026: rename worktree prune test

Merge branch 'dt/log-follow-config'Junio C Hamano Thu, 15 Oct 2015 22:43:46 +0000 (15:43 -0700)

Merge branch 'dt/log-follow-config'

Description of the "log.follow" configuration variable in "git log"
documentation is now also copied to "git config" documentation.

* dt/log-follow-config:
log: Update log.follow doc and add to config.txt

Merge branch 'cc/quote-comments'Junio C Hamano Thu, 15 Oct 2015 22:43:44 +0000 (15:43 -0700)

Merge branch 'cc/quote-comments'

A no-op code-health maintenance.

* cc/quote-comments:
quote: move comment before sq_quote_buf()
quote: fix broken sq_quote_buf() related comment

Merge branch 'gr/rebase-i-drop-warn'Junio C Hamano Thu, 15 Oct 2015 22:43:44 +0000 (15:43 -0700)

Merge branch 'gr/rebase-i-drop-warn'

"git rebase -i" had a minor regression recently, which stopped
considering a line that begins with an indented '#' in its insn
sheet not a comment, which is now fixed.

* gr/rebase-i-drop-warn:
rebase-i: loosen over-eager check_bad_cmd check
rebase-i: explicitly accept tab as separator in commands

Merge branch 'mm/detach-at-HEAD-reflog'Junio C Hamano Thu, 15 Oct 2015 22:43:42 +0000 (15:43 -0700)

Merge branch 'mm/detach-at-HEAD-reflog'

After "git checkout --detach", "git status" reported a fairly
useless "HEAD detached at HEAD", instead of saying at which exact
commit.

* mm/detach-at-HEAD-reflog:
status: don't say 'HEAD detached at HEAD'
t3203: test 'detached at' after checkout --detach

Merge branch 'sa/send-email-smtp-batch-data-limit'Junio C Hamano Thu, 15 Oct 2015 22:43:41 +0000 (15:43 -0700)

Merge branch 'sa/send-email-smtp-batch-data-limit'

When "git send-email" wanted to talk over Net::SMTP::SSL,
Net::Cmd::datasend() did not like to be fed too many bytes at the
same time and failed to send messages. Send the payload one line
at a time to work around the problem.

* sa/send-email-smtp-batch-data-limit:
git-send-email.perl: Fixed sending of many/huge changes/patches

Merge branch 'pt/am-builtin'Junio C Hamano Thu, 15 Oct 2015 22:43:40 +0000 (15:43 -0700)

Merge branch 'pt/am-builtin'

When "git am" was rewritten as a built-in, it stopped paying
attention to user.signingkey, which was fixed.

* pt/am-builtin:
am: configure gpg at startup

Merge branch 'nd/clone-linked-checkout'Junio C Hamano Thu, 15 Oct 2015 22:43:39 +0000 (15:43 -0700)

Merge branch 'nd/clone-linked-checkout'

It was not possible to use a repository-lookalike created by "git
worktree add" as a local source of "git clone".

* nd/clone-linked-checkout:
clone: better error when --reference is a linked checkout
clone: allow --local from a linked checkout
enter_repo: allow .git files in strict mode
enter_repo: avoid duplicating logic, use is_git_directory() instead
t0002: add test for enter_repo(), non-strict mode
path.c: delete an extra space

Merge branch 'js/icase-wt-detection'Junio C Hamano Thu, 15 Oct 2015 22:43:39 +0000 (15:43 -0700)

Merge branch 'js/icase-wt-detection'

On a case insensitive filesystems, setting GIT_WORK_TREE variable
using a random cases that does not agree with what the filesystem
thinks confused Git that it wasn't inside the working tree.

* js/icase-wt-detection:
setup: fix "inside work tree" detection on case-insensitive filesystems

Merge branch 'kn/for-each-branch'Junio C Hamano Thu, 15 Oct 2015 22:43:38 +0000 (15:43 -0700)

Merge branch 'kn/for-each-branch'

Update "git branch" that list existing branches, using the
ref-filter API that is shared with "git tag" and "git
for-each-ref".

* kn/for-each-branch:
branch: add '--points-at' option
branch.c: use 'ref-filter' APIs
branch.c: use 'ref-filter' data structures
branch: drop non-commit error reporting
branch: move 'current' check down to the presentation layer
branch: roll show_detached HEAD into regular ref_list
branch: bump get_head_description() to the top
branch: refactor width computation

Merge branch 'sb/perf-without-installed-git'Junio C Hamano Thu, 15 Oct 2015 22:43:37 +0000 (15:43 -0700)

Merge branch 'sb/perf-without-installed-git'

Performance-measurement tests did not work without an installed Git.

* sb/perf-without-installed-git:
t/perf: make runner work even if Git is not installed

Merge branch 'sb/http-flaky-test-fix'Junio C Hamano Thu, 15 Oct 2015 22:43:35 +0000 (15:43 -0700)

Merge branch 'sb/http-flaky-test-fix'

A test script for the HTTP service had a timing dependent bug,
which was fixed.

* sb/http-flaky-test-fix:
t5561: get rid of racy appending to logfile

Merge branch 'jc/fsck-dropped-errors'Junio C Hamano Thu, 15 Oct 2015 22:43:35 +0000 (15:43 -0700)

Merge branch 'jc/fsck-dropped-errors'

There were some classes of errors that "git fsck" diagnosed to its
standard error that did not cause it to exit with non-zero status.

* jc/fsck-dropped-errors:
fsck: exit with non-zero when problems are found

Merge branch 'ls/p4-translation-failure'Junio C Hamano Thu, 15 Oct 2015 22:43:34 +0000 (15:43 -0700)

Merge branch 'ls/p4-translation-failure'

Work around "git p4" failing when the P4 depot records the contents
in UTF-16 without UTF-16 BOM.

* ls/p4-translation-failure:
git-p4: handle "Translation of file content failed"
git-p4: add test case for "Translation of file content failed" error

Merge branch 'nd/gc-auto-background-fix'Junio C Hamano Thu, 15 Oct 2015 22:43:32 +0000 (15:43 -0700)

Merge branch 'nd/gc-auto-background-fix'

When "git gc --auto" is backgrounded, its diagnosis message is
lost. Save it to a file in $GIT_DIR and show it next time the "gc
--auto" is run.

* nd/gc-auto-background-fix:
gc: save log from daemonized gc --auto and print it next time

Merge branch 'mk/submodule-gitdir-path'Junio C Hamano Thu, 15 Oct 2015 22:43:31 +0000 (15:43 -0700)

Merge branch 'mk/submodule-gitdir-path'

The submodule code has been taught to work better with separate
work trees created via "git worktree add".

* mk/submodule-gitdir-path:
path: implement common_dir handling in git_pathdup_submodule()
submodule refactor: use strbuf_git_path_submodule() in add_submodule_odb()

Third batch for 2.7Junio C Hamano Wed, 14 Oct 2015 21:31:23 +0000 (14:31 -0700)

Third batch for 2.7

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'pt/pull-builtin'Junio C Hamano Wed, 14 Oct 2015 21:30:20 +0000 (14:30 -0700)

Merge branch 'pt/pull-builtin'

* pt/pull-builtin:
merge: grammofix in please-commit-before-merge message

Merge branch 'nd/ls-remote-does-not-have-u-option'Junio C Hamano Wed, 14 Oct 2015 21:30:19 +0000 (14:30 -0700)

Merge branch 'nd/ls-remote-does-not-have-u-option'

* nd/ls-remote-does-not-have-u-option:
ls-remote.txt: delete unsupported option

Merge branch 'jk/asciidoctor-section-heading-markup... Junio C Hamano Wed, 14 Oct 2015 21:30:17 +0000 (14:30 -0700)

Merge branch 'jk/asciidoctor-section-heading-markup-fix'

* jk/asciidoctor-section-heading-markup-fix:
Documentation: fix section header mark-up

Merge branch 'tk/typofix-connect-unknown-proto-error'Junio C Hamano Wed, 14 Oct 2015 21:30:16 +0000 (14:30 -0700)

Merge branch 'tk/typofix-connect-unknown-proto-error'

* tk/typofix-connect-unknown-proto-error:
connect: fix typo in result string of prot_name()

Merge branch 'jk/notes-dwim-doc'Junio C Hamano Wed, 14 Oct 2015 21:30:15 +0000 (14:30 -0700)

Merge branch 'jk/notes-dwim-doc'

The way how --ref/--notes to specify the notes tree reference are
DWIMmed was not clearly documented.

* jk/notes-dwim-doc:
notes: correct documentation of DWIMery for notes references

Documentation/gc: warn against --prune=<now>Junio C Hamano Wed, 14 Oct 2015 20:48:39 +0000 (13:48 -0700)

Documentation/gc: warn against --prune=<now>

"git gc" is safe to run anytime only because it has the built-in
grace period to protect objects that are created by other processes
that are waiting for ref updates to anchor them to the history. In
order to run with no grace period, the user must make sure that the
repository is quiescent.

Reviewed-by: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t0027: improve test for not-normalized filesTorsten Bögershausen Sat, 10 Oct 2015 04:23:53 +0000 (06:23 +0200)

t0027: improve test for not-normalized files

When a text file with mixed line endings is commited into the repo,
it is called "not normalized" (or NNO) in t0027. The existing test
case using repoMIX did not fully test all combinations: (Especially
when core.autocrlf = true) Files with NL are not converted at
commit, but at checkout, so a warning NL->CRLF is given. Files with
CRLF are not converted at all (so no warning will be given), unless
they are marked as "text" or "auto".

Remove repoMIX introduced in commit 8eeab92f02, and replace it with
a combination of NNO tests.

Signed-off-by: Torsten Bögershausen <tboegi@web.de>

submodule-config: "goto" removal in parse_config()Stefan Beller Mon, 12 Oct 2015 17:58:58 +0000 (10:58 -0700)

submodule-config: "goto" removal in parse_config()

Many components in if/else if/... cascade jumped to a shared
clean-up with "goto release_return", but we can restructure the
function a bit and make them disappear, which reduces the line count
as well. Also reformat overlong lines and poorly indented ones
while at it.

The order of rules to verify the value for "ignore" used to be to
complain on multiple values first and then complain to boolean, but
swap the order to match how the values for "path" and "url" are
verified.

CC: Eric Sunshine <sunshine@sunshineco.com>
CC: Heiko Voigt <hvoigt@hvoigt.net>
Signed-off-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

filter-branch: remove multi-line headers in msg filterJames McCoy Fri, 9 Oct 2015 00:21:13 +0000 (20:21 -0400)

filter-branch: remove multi-line headers in msg filter

df062010 (filter-branch: avoid passing commit message through sed)
introduced a regression when filtering commits with multi-line headers,
if the header contains a blank line. An example of this is a gpg-signed
commit:

$ git cat-file commit signed-commit
tree 3d4038e029712da9fc59a72afbfcc90418451630
parent 110eac945dc1713b27bdf49e74e5805db66971f0
author A U Thor <author@example.com> 1112912413 -0700
committer C O Mitter <committer@example.com> 1112912413 -0700
gpgsig -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iEYEABECAAYFAlYXADwACgkQE7b1Hs3eQw23CACgldB/InRyDgQwyiFyMMm3zFpj
pUsAnA+f3aMUsd9mNroloSmlOgL6jIMO
=0Hgm
-----END PGP SIGNATURE-----

Adding gpg

As a consequence, "filter-branch --msg-filter cat" (which should leave the
commit message unchanged) spills the signature (after the internal blank
line) into the original commit message.

The reason is that although the signature is indented, making the line a
whitespace only line, the "read" call is splitting the line based on
the shell's IFS, which defaults to <space><tab><newline>. The leading
space is consumed and $header_line is empty, causing the "skip header
lines" loop to exit.

The rest of the commit object is then re-used as the rewritten commit
message, causing the new message to include the signature of the
original commit.

Set IFS to an empty string for the "read" call, thus disabling the word
splitting, which causes $header_line to be set to the non-empty value ' '.
This allows the loop to fully consume the header lines before
emitting the original, intact commit message.

[jc: this is literally based on MJG's suggestion]

Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net>
Signed-off-by: James McCoy <vega.james@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-multimail: update to release 1.2.0Matthieu Moy Sun, 11 Oct 2015 18:43:20 +0000 (20:43 +0200)

git-multimail: update to release 1.2.0

The changes are described in CHANGES.

Contributions-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Contributions-by: Elijah Newren <newren@palantir.com>
Contributions-by: Edward d'Auvergne <edward@nmr-relax.com>
Contributions-by: Vadim Zeitlin <vadim@zeitlins.org>
Contributions-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
Contributions-by: Michael Haggerty <mhagger@alum.mit.edu>
Contributions-by: Elijah Newren <newren@gmail.com>
Contributions-by: Richard Hansen <rhansen@rhansen.org>
Contributions-by: Job Snijders <job@instituut.net>
Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-p4: skip t9819 test case on case insensitive file... Lars Schneider Mon, 12 Oct 2015 17:03:04 +0000 (10:03 -0700)

git-p4: skip t9819 test case on case insensitive file systems

Windows and OS X file systems are case insensitive by default.
Consequently the "git-p4-case-folding" test case does not apply to
them.

Signed-off-by: Lars Schneider <larsxschneider@gmail.com>
Acked-by: Luke Diamand <luke@diamand.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-p4: avoid "stat" command in t9815 git-p4-submit... Lars Schneider Mon, 12 Oct 2015 17:03:03 +0000 (10:03 -0700)

git-p4: avoid "stat" command in t9815 git-p4-submit-fail

Replace the stat command with the ls command to check file mode
bits. The stats command is not available on Windows and has
different command line options on OS X.

Signed-off-by: Lars Schneider <larsxschneider@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

am -3: do not let failed merge from completing the... Junio C Hamano Fri, 9 Oct 2015 20:38:30 +0000 (13:38 -0700)

am -3: do not let failed merge from completing the error codepath

When "am" was rewritten in C, the codepath for falling back to
three-way merge was mistakenly made to make an internal call to
merge-recursive, disabling the error reporting code for certain
types of errors merge-recursive detects and reports by calling
die().

This is a quick-fix for correctness. The ideal endgame would be to
replace run_command() in run_fallback_merge_recursive() with a
direct call after making sure that internal call to merge-recursive
does not die().

Signed-off-by: Junio C Hamano <gitster@pobox.com>

test-path-utils.c: remove incorrect assumptionRay Donnelly Thu, 1 Oct 2015 19:04:17 +0000 (20:04 +0100)

test-path-utils.c: remove incorrect assumption

In normalize_ceiling_entry(), we test that normalized paths end with
slash, *unless* the path to be normalized was already the root
directory.

However, normalize_path_copy() does not even enforce this condition.

Even worse: on Windows, the root directory gets translated into a
Windows directory by the Bash before being passed to `git.exe` (or
`test-path-utils.exe`), which means that we cannot even know whether
the path that was passed to us was the root directory to begin with.

This issue has already caused endless hours of trying to "fix" the
MSYS2 runtime, only to break other things due to MSYS2 ensuring that
the converted path maintains the same state as the input path with
respect to any final '/'.

So let's just forget about this test. It is non-essential to Git's
operation, anyway.

Acked-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Ray Donnelly <mingw.android@gmail.com>

pack-objects: do not get distracted by broken symrefsJohannes Schindelin Mon, 28 Sep 2015 14:01:25 +0000 (16:01 +0200)

pack-objects: do not get distracted by broken symrefs

It is quite possible for, say, a remote HEAD to become broken, e.g.
when the default branch was renamed.

We should still be able to pack our objects when such a thing happens;
simply ignore broken symrefs (because they cannot matter for the packing
process anyway).

This fixes https://github.com/git-for-windows/git/issues/423

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

worktree: add 'list' commandMichael Rappazzo Thu, 8 Oct 2015 17:01:05 +0000 (13:01 -0400)

worktree: add 'list' command

'git worktree list' iterates through the worktree list, and outputs
details of the worktree including the path to the worktree, the currently
checked out revision and branch, and if the work tree is bare. There is
also porcelain format option available.

Signed-off-by: Michael Rappazzo <rappazzo@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

worktree: add details to the worktree structMichael Rappazzo Thu, 8 Oct 2015 17:01:04 +0000 (13:01 -0400)

worktree: add details to the worktree struct

In addition to the absolute path in the worktree struct, add the location
of the git dir, the head ref (if not detached), the head revision sha1,
whether or not head is detached, and whether or not the worktree is a
bare repo.

Signed-off-by: Michael Rappazzo <rappazzo@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

worktree: add a function to get worktree detailsMichael Rappazzo Thu, 8 Oct 2015 17:01:03 +0000 (13:01 -0400)

worktree: add a function to get worktree details

The worktree structure provided for an individual worktree includes the
absolute path of the worktree. The fuction to get the worktree details
is a refactor of the find main/linked symref functions.

Signed-off-by: Michael Rappazzo <rappazzo@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

worktree: refactor find_linked_symref functionMichael Rappazzo Thu, 8 Oct 2015 17:01:02 +0000 (13:01 -0400)

worktree: refactor find_linked_symref function

Refactoring will help transition this code to provide additional useful
worktree functions.

Signed-off-by: Michael Rappazzo <rappazzo@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

quote: move comment before sq_quote_buf()Christian Couder Wed, 7 Oct 2015 22:05:50 +0000 (00:05 +0200)

quote: move comment before sq_quote_buf()

A big comment at the beginning of quote.c is really
related to sq_quote_buf(), so let's move it in front
of this function.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

quote: fix broken sq_quote_buf() related commentChristian Couder Wed, 7 Oct 2015 22:05:49 +0000 (00:05 +0200)

quote: fix broken sq_quote_buf() related comment

Since 77d604c (Enhanced sq_quote(), 10 Oct 2005), the
comment at the beginning of quote.c is broken.
Let's fix it.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Second batch for 2.7Junio C Hamano Wed, 7 Oct 2015 20:38:43 +0000 (13:38 -0700)

Second batch for 2.7

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'ls/p4-path-encoding'Junio C Hamano Wed, 7 Oct 2015 20:38:19 +0000 (13:38 -0700)

Merge branch 'ls/p4-path-encoding'

"git p4" learned to reencode the pathname it uses to communicate
with the p4 depot with a new option.

* ls/p4-path-encoding:
git-p4: use replacement character for non UTF-8 characters in paths
git-p4: improve path encoding verbose output
git-p4: add config git-p4.pathEncoding

Merge branch 'gb/filter-branch-progress'Junio C Hamano Wed, 7 Oct 2015 20:38:18 +0000 (13:38 -0700)

Merge branch 'gb/filter-branch-progress'

Give progress meter to "git filter-branch".

* gb/filter-branch-progress:
filter-branch: make report-progress more readable
filter-branch: add passed/remaining seconds on progress

Merge branch 'nd/ignore-then-not-ignore'Junio C Hamano Wed, 7 Oct 2015 20:38:17 +0000 (13:38 -0700)

Merge branch 'nd/ignore-then-not-ignore'

Allow a later "!/abc/def" to override an earlier "/abc" that
appears in the same .gitignore file to make it easier to express
"everything in /abc directory is ignored, except for ...".

* nd/ignore-then-not-ignore:
dir.c: don't exclude whole dir prematurely if neg pattern may match
dir.c: make last_exclude_matching_from_list() run til the end

Merge branch 'ti/glibc-stdio-mutex-from-signal-handler'Junio C Hamano Wed, 7 Oct 2015 20:38:16 +0000 (13:38 -0700)

Merge branch 'ti/glibc-stdio-mutex-from-signal-handler'

Allocation related functions and stdio are unsafe things to call
inside a signal handler, and indeed killing the pager can cause
glibc to deadlock waiting on allocation mutex as our signal handler
tries to free() some data structures in wait_for_pager(). Reduce
these unsafe calls.

* ti/glibc-stdio-mutex-from-signal-handler:
pager: don't use unsafe functions in signal handlers

Documentation/interpret-trailers: Grammar fixTobias Klauser Wed, 7 Oct 2015 16:46:22 +0000 (18:46 +0200)

Documentation/interpret-trailers: Grammar fix

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

clone --dissociate: avoid locking pack filesJohannes Schindelin Tue, 6 Oct 2015 13:18:47 +0000 (15:18 +0200)

clone --dissociate: avoid locking pack files

When `git clone` is asked to dissociate the repository from the
reference repository whose objects were used, it is quite possible that
the pack files need to be repacked. In that case, the pack files need to
be deleted that were originally hard-links to the reference repository's
pack files.

On platforms where a file cannot be deleted if another process still
holds a handle on it, we therefore need to take pains to release all
pack files and indexes before dissociating.

This fixes https://github.com/git-for-windows/git/issues/446

The test case to demonstrate the breakage technically does not need to
be run on Linux or MacOSX. It won't hurt, either, though.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

sha1_file.c: add a function to release all packsJohannes Schindelin Tue, 6 Oct 2015 13:18:34 +0000 (15:18 +0200)

sha1_file.c: add a function to release all packs

On Windows, files that are in use cannot be removed or renamed. That
means that we have to release pack files when we are about to, say,
repack them. Let's introduce a convenient function to close all the
pack files and their idx files.

While at it, we consolidate the close windows/close fd/close index
stanza in `free_pack_by_name()` into the `close_pack()` function that
is used by the new `close_all_packs()` function to avoid repeated code.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t2026: rename worktree prune testMichael J Gruber Tue, 6 Oct 2015 10:12:21 +0000 (12:12 +0200)

t2026: rename worktree prune test

Linked checkouts are known under the name worktree, now. Rename the test
accordingly.

Specifically, this avoids the confusion that t2026 is actually not about
pruning in or with linked checkouts aka worktress but about pruning
worktrees, i.e. about "git worktree prune" rather than "git prune".

Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

log: Update log.follow doc and add to config.txtEric N. Vander Weele Wed, 7 Oct 2015 01:14:33 +0000 (21:14 -0400)

log: Update log.follow doc and add to config.txt

Documentation/config.txt does not include the documentation for
log.follow that is in Documentation/git-log.txt. This commit adds the
log.follow documentation to config.txt and also updates the wording to
be consistent with the format that is followed by other boolean
configuration variables.

Signed-off-by: Eric N. Vander Weele <ericvw@gmail.com>
Acked-by: David Turner <dturner@twopensource.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

rebase-i: loosen over-eager check_bad_cmd checkMatthieu Moy Thu, 1 Oct 2015 08:18:42 +0000 (10:18 +0200)

rebase-i: loosen over-eager check_bad_cmd check

804098bb (git rebase -i: add static check for commands and SHA-1,
2015-06-29) tried to check all insns before running any in the todo
list, but it did so by implementing its own parser that is a lot
stricter than necessary. We used to allow lines that are indented
(including comment lines), and we used to allow a whitespace between
the insn and the commit object name to be HT, among other things,
that are flagged as an invalid line by mistake.

Fix this by using the same tokenizer that is used to parse the todo
list file in the new check.

Whether it's a good thing to accept indented comments is
debatable (other commands like "git commit" do not accept them), but we
already accepted them in the past, and some people and scripts rely on
this behavior. Also, a line starting with space followed by a '#' cannot
have any meaning other than being a comment, hence it doesn't harm to
accept them as comments.

Largely based on patch by: Junio C Hamano <gitster@pobox.com>

[jc: updated test with quickfix from Torsten Bögershausen]

Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

gc: demonstrate failure with stale remote HEADJohannes Schindelin Mon, 28 Sep 2015 14:01:13 +0000 (16:01 +0200)

gc: demonstrate failure with stale remote HEAD

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>