gitweb.git
Merge branch 'sl/clean-d-ignored-fix'Junio C Hamano Fri, 2 Jun 2017 06:06:04 +0000 (15:06 +0900)

Merge branch 'sl/clean-d-ignored-fix'

"git clean -d" used to clean directories that has ignored files,
even though the command should not lose ignored ones without "-x".
"git status --ignored" did not list ignored and untracked files
without "-uall". These have been corrected.

* sl/clean-d-ignored-fix:
clean: teach clean -d to preserve ignored paths
dir: expose cmp_name() and check_contains()
dir: hide untracked contents of untracked dirs
dir: recurse into untracked dirs for ignored files
t7061: status --ignored should search untracked dirs
t7300: clean -d should skip dirs with ignored files

Merge branch 'sb/t5531-update-desc'Junio C Hamano Fri, 2 Jun 2017 06:06:03 +0000 (15:06 +0900)

Merge branch 'sb/t5531-update-desc'

The description strings for a few tests have been updated.

* sb/t5531-update-desc:
t5531: fix test description

Merge branch 'ah/doc-pretty-format-fix'Junio C Hamano Fri, 2 Jun 2017 06:06:03 +0000 (15:06 +0900)

Merge branch 'ah/doc-pretty-format-fix'

Documentation fix.

* ah/doc-pretty-format-fix:
Documentation: fix formatting typo in pretty-formats.txt

Merge branch 'ah/doc-interpret-trailers-ifexists'Junio C Hamano Fri, 2 Jun 2017 06:06:02 +0000 (15:06 +0900)

Merge branch 'ah/doc-interpret-trailers-ifexists'

Documentation fix.

* ah/doc-interpret-trailers-ifexists:
Documentation: fix reference to ifExists for interpret-trailers

Merge branch 'rs/mingw-path-lookup-simplify'Junio C Hamano Fri, 2 Jun 2017 06:06:01 +0000 (15:06 +0900)

Merge branch 'rs/mingw-path-lookup-simplify'

Code simplification.

* rs/mingw-path-lookup-simplify:
mingw: simplify PATH handling

Merge branch 'ab/ref-filter-no-contains'Junio C Hamano Fri, 2 Jun 2017 06:06:00 +0000 (15:06 +0900)

Merge branch 'ab/ref-filter-no-contains'

Doc update to a recent topic.

* ab/ref-filter-no-contains:
tag: duplicate mention of --contains should mention --no-contains

Merge branch 'jt/send-email-validate-hook'Junio C Hamano Fri, 2 Jun 2017 06:05:59 +0000 (15:05 +0900)

Merge branch 'jt/send-email-validate-hook'

A hotfix for a topic already in 'master'.

* jt/send-email-validate-hook:
send-email: check for repo before invoking hook

Merge branch 'dk/send-email-avoid-net-smtp-ssl-when... Junio C Hamano Fri, 2 Jun 2017 06:05:59 +0000 (15:05 +0900)

Merge branch 'dk/send-email-avoid-net-smtp-ssl-when-able'

A hotfix to a topic in 'master'.

* dk/send-email-avoid-net-smtp-ssl-when-able:
send-email: Net::SMTP::starttls was introduced in v2.34

Merge branch 'js/bs-is-a-dir-sep-on-windows'Junio C Hamano Fri, 2 Jun 2017 06:05:58 +0000 (15:05 +0900)

Merge branch 'js/bs-is-a-dir-sep-on-windows'

"foo\bar\baz" in "git fetch foo\bar\baz", even though there is no
slashes in it, cannot be a nickname for a remote on Windows, as
that is likely to be a pathname on a local filesystem.

* js/bs-is-a-dir-sep-on-windows:
Windows: do not treat a path with backslashes as a remote's nick name
mingw.h: permit arguments with side effects for is_dir_sep

send-email: check for repo before invoking hookJonathan Tan Thu, 1 Jun 2017 23:50:55 +0000 (16:50 -0700)

send-email: check for repo before invoking hook

Unless --no-validate is passed, send-email will invoke
$repo->repo_path() in its search for a validate hook regardless of
whether a Git repo is actually present. Teach send-email to first check
for repo existence.

Signed-off-by: Jonathan Tan <jonathantanmy@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

send-email: Net::SMTP::starttls was introduced in v2.34Jonathan Nieder Thu, 1 Jun 2017 00:17:43 +0000 (17:17 -0700)

send-email: Net::SMTP::starttls was introduced in v2.34

We cannot rely on the starttls method being present in Net::SMTP until
c274b798e6881a941d941808c6d89966975cb8c8 (Merge branch 'ipv6_ssl' of
https://github.com/noxxi/perl-libnet into noxxi-ipv6_ssl, 2014-06-02),
which set the module version to 2.34.

This version was first shipped as part of perl in v5.21.5~169 (Update
libnet to CPAN version 3.01, 2014-10-10).

Noticed on an Ubuntu system with perl 5.18.2-2ubuntu1.1, which
provides Net::SMTP version 2.31. The error message is

Can't locate object method "starttls" via package "Net::SMTP" at /usr/lib/git-core/git-send-email line 1410.

Reported-by: Brandon Williams <bmwill@google.com>
Reported-and-tested-by: Eric Biggers <ebiggers3@gmail.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Fourth batch for 2.14Junio C Hamano Tue, 30 May 2017 02:20:10 +0000 (11:20 +0900)

Fourth batch for 2.14

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

Merge branch 'dt/unpack-save-untracked-cache-extension'Junio C Hamano Tue, 30 May 2017 02:16:45 +0000 (11:16 +0900)

Merge branch 'dt/unpack-save-untracked-cache-extension'

When "git checkout", "git merge", etc. manipulates the in-core
index, various pieces of information in the index extensions are
discarded from the original state, as it is usually not the case
that they are kept up-to-date and in-sync with the operation on the
main index. The untracked cache extension is copied across these
operations now, which would speed up "git status" (as long as the
cache is properly invalidated).

* dt/unpack-save-untracked-cache-extension:
unpack-trees: preserve index extensions

Merge branch 'js/larger-timestamps'Junio C Hamano Tue, 30 May 2017 02:16:45 +0000 (11:16 +0900)

Merge branch 'js/larger-timestamps'

A follow-up hotfix for a topic already in 'master'.

* js/larger-timestamps:
name-rev: change a "long" variable to timestamp_t

Merge branch 'dk/send-email-avoid-net-smtp-ssl-when... Junio C Hamano Tue, 30 May 2017 02:16:45 +0000 (11:16 +0900)

Merge branch 'dk/send-email-avoid-net-smtp-ssl-when-able'

"git send-email" now uses Net::SMTP::SSL, which is obsolete, only
when needed. Recent versions of Net::SMTP can do TLS natively.

* dk/send-email-avoid-net-smtp-ssl-when-able:
send-email: Net::SMTP::SSL is obsolete, use only when necessary

Merge branch 'jc/skip-test-in-the-middle'Junio C Hamano Tue, 30 May 2017 02:16:44 +0000 (11:16 +0900)

Merge branch 'jc/skip-test-in-the-middle'

A recent update to t5545-push-options.sh started skipping all the
tests in the script when a web server testing is disabled or
unavailable, not just the ones that require a web server. Non HTTP
tests have been salvaged to always run in this script.

* jc/skip-test-in-the-middle:
t5545: enhance test coverage when no http server is installed
test: allow skipping the remainder

Merge branch 'ab/conditional-config-with-symlinks'Junio C Hamano Tue, 30 May 2017 02:16:43 +0000 (11:16 +0900)

Merge branch 'ab/conditional-config-with-symlinks'

The recently introduced "[includeIf "gitdir:$dir"] path=..."
mechansim has further been taught to take symlinks into account.
The directory "$dir" specified in "gitdir:$dir" may be a symlink to
a real location, not something that $(getcwd) may return. In such
a case, a realpath of "$dir" is compared with the real path of the
current repository to determine if the contents from the named path
should be included.

* ab/conditional-config-with-symlinks:
config: match both symlink & realpath versions in IncludeIf.gitdir:*

Merge branch 'jt/fetch-allow-tip-sha1-implicitly'Junio C Hamano Tue, 30 May 2017 02:16:43 +0000 (11:16 +0900)

Merge branch 'jt/fetch-allow-tip-sha1-implicitly'

There is no good reason why "git fetch $there $sha1" should fail
when the $sha1 names an object at the tip of an advertised ref,
even when the other side hasn't enabled allowTipSHA1InWant.

* jt/fetch-allow-tip-sha1-implicitly:
fetch-pack: always allow fetching of literal SHA1s

Merge branch 'jt/send-email-validate-hook'Junio C Hamano Tue, 30 May 2017 02:16:43 +0000 (11:16 +0900)

Merge branch 'jt/send-email-validate-hook'

"git send-email" learned to run sendemail-validate hook to inspect
and reject a message before sending it out.

* jt/send-email-validate-hook:
send-email: support validate hook

Merge branch 'jh/memihash-opt'Junio C Hamano Tue, 30 May 2017 02:16:42 +0000 (11:16 +0900)

Merge branch 'jh/memihash-opt'

perf-test update.

* jh/memihash-opt:
p0004: don't error out if test repo is too small
p0004: don't abort if multi-threaded is too slow
p0004: use test_perf
p0004: avoid using pipes
p0004: simplify calls of test-lazy-init-name-hash

Merge branch 'bp/sub-process-convert-filter'Junio C Hamano Tue, 30 May 2017 02:16:42 +0000 (11:16 +0900)

Merge branch 'bp/sub-process-convert-filter'

Code from "conversion using external process" codepath has been
extracted to a separate sub-process.[ch] module.

* bp/sub-process-convert-filter:
convert: update subprocess_read_status() to not die on EOF
sub-process: move sub-process functions into separate files
convert: rename reusable sub-process functions
convert: update generic functions to only use generic data structures
convert: separate generic structures and variables from the filter specific ones
convert: split start_multi_file_filter() into two separate functions
pkt-line: annotate packet_writel with LAST_ARG_MUST_BE_NULL
convert: move packet_write_line() into pkt-line as packet_writel()
pkt-line: add packet_read_line_gently()
pkt-line: fix packet_read_line() to handle len < 0 errors
convert: remove erroneous tests for errno == EPIPE

Merge branch 'bw/forking-and-threading'Junio C Hamano Tue, 30 May 2017 02:16:41 +0000 (11:16 +0900)

Merge branch 'bw/forking-and-threading'

The "run-command" API implementation has been made more robust
against dead-locking in a threaded environment.

* bw/forking-and-threading:
usage.c: drop set_error_handle()
run-command: restrict PATH search to executable files
run-command: expose is_executable function
run-command: block signals between fork and execve
run-command: add note about forking and threading
run-command: handle dup2 and close errors in child
run-command: eliminate calls to error handling functions in child
run-command: don't die in child when duping /dev/null
run-command: prepare child environment before forking
string-list: add string_list_remove function
run-command: use the async-signal-safe execv instead of execvp
run-command: prepare command before forking
t0061: run_command executes scripts without a #! line
t5550: use write_script to generate post-update hook

Merge branch 'ab/perf-wildmatch'Junio C Hamano Tue, 30 May 2017 02:16:40 +0000 (11:16 +0900)

Merge branch 'ab/perf-wildmatch'

Add perf-test for wildmatch.

* ab/perf-wildmatch:
perf: add test showing exponential growth in path globbing
perf: add function to setup a fresh test repo

Merge branch 'bw/pathspec-sans-the-index'Junio C Hamano Tue, 30 May 2017 02:16:40 +0000 (11:16 +0900)

Merge branch 'bw/pathspec-sans-the-index'

Simplify parse_pathspec() codepath and stop it from looking at the
default in-core index.

* bw/pathspec-sans-the-index:
pathspec: convert find_pathspecs_matching_against_index to take an index
pathspec: remove PATHSPEC_STRIP_SUBMODULE_SLASH_CHEAP
ls-files: prevent prune_cache from overeagerly pruning submodules
pathspec: remove PATHSPEC_STRIP_SUBMODULE_SLASH_EXPENSIVE flag
submodule: add die_in_unpopulated_submodule function
pathspec: provide a more descriptive die message

Merge branch 'jc/name-rev-lw-tag'Junio C Hamano Tue, 30 May 2017 02:16:39 +0000 (11:16 +0900)

Merge branch 'jc/name-rev-lw-tag'

"git describe --contains" penalized light-weight tags so much that
they were almost never considered. Instead, give them about the
same chance to be considered as an annotated tag that is the same
age as the underlying commit would.

* jc/name-rev-lw-tag:
name-rev: favor describing with tags and use committer date to tiebreak
name-rev: refactor logic to see if a new candidate is a better name

Third batch for 2.14Junio C Hamano Mon, 29 May 2017 03:39:46 +0000 (12:39 +0900)

Third batch for 2.14

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

Merge branch 'jk/ignore-broken-tags-when-ignoring-missi... Junio C Hamano Mon, 29 May 2017 03:34:54 +0000 (12:34 +0900)

Merge branch 'jk/ignore-broken-tags-when-ignoring-missing-links'

Tag objects, which are not reachable from any ref, that point at
missing objects were mishandled by "git gc" and friends (they
should silently be ignored instead)

* jk/ignore-broken-tags-when-ignoring-missing-links:
revision.c: ignore broken tags with ignore_missing_links

Merge branch 'jk/alternate-ref-optim'Junio C Hamano Mon, 29 May 2017 03:34:53 +0000 (12:34 +0900)

Merge branch 'jk/alternate-ref-optim'

A test allowed both "git push" and "git receive-pack" on the other
end write their traces into the same file. This is OK on platforms
that allows atomically appending to a file opened with O_APPEND,
but on other platforms led to a mangled output, causing
intermittent test failures. This has been fixed by disabling
traces from "receive-pack" in the test.

* jk/alternate-ref-optim:
t5400: avoid concurrent writes into a trace file

Merge branch 'bm/interpret-trailers-cut-line-is-eom'Junio C Hamano Mon, 29 May 2017 03:34:52 +0000 (12:34 +0900)

Merge branch 'bm/interpret-trailers-cut-line-is-eom'

"git interpret-trailers", when used as GIT_EDITOR for "git commit
-v", looked for and appended to a trailer block at the very end,
i.e. at the end of the "diff" output. The command has been
corrected to pay attention to the cut-mark line "commit -v" adds to
the buffer---the real trailer block should appear just before it.

* bm/interpret-trailers-cut-line-is-eom:
interpret-trailers: honor the cut line

Merge branch 'tg/stash-push-fixup'Junio C Hamano Mon, 29 May 2017 03:34:52 +0000 (12:34 +0900)

Merge branch 'tg/stash-push-fixup'

The shell completion script (in contrib/) learned "git stash" has
a new "push" subcommand.

* tg/stash-push-fixup:
completion: add git stash push

Merge branch 'pw/rebase-i-regression-fix'Junio C Hamano Mon, 29 May 2017 03:34:51 +0000 (12:34 +0900)

Merge branch 'pw/rebase-i-regression-fix'

Regression fix to topic recently merged to 'master'.

* pw/rebase-i-regression-fix:
rebase -i: add missing newline to end of message
rebase -i: silence stash apply
rebase -i: fix reflog message

Merge branch 'kn/ref-filter-branch-list'Junio C Hamano Mon, 29 May 2017 03:34:50 +0000 (12:34 +0900)

Merge branch 'kn/ref-filter-branch-list'

"git for-each-ref --format=..." with %(HEAD) in the format used to
resolve the HEAD symref as many times as it had processed refs,
which was wasteful, and "git branch" shared the same problem.

* kn/ref-filter-branch-list:
ref-filter: resolve HEAD when parsing %(HEAD) atom

Merge branch 'km/log-showsignature-doc'Junio C Hamano Mon, 29 May 2017 03:34:49 +0000 (12:34 +0900)

Merge branch 'km/log-showsignature-doc'

* km/log-showsignature-doc:
config.txt: add an entry for log.showSignature

Merge branch 'jk/update-links-in-docs'Junio C Hamano Mon, 29 May 2017 03:34:48 +0000 (12:34 +0900)

Merge branch 'jk/update-links-in-docs'

A few http:// links that are redirected to https:// in the
documentation have been updated to https:// links.

* jk/update-links-in-docs:
doc: use https links to Wikipedia to avoid http redirects

Merge branch 'ja/do-not-ask-needless-questions'Junio C Hamano Mon, 29 May 2017 03:34:48 +0000 (12:34 +0900)

Merge branch 'ja/do-not-ask-needless-questions'

Git sometimes gives an advice in a rhetorical question that does
not require an answer, which can confuse new users and non native
speakers. Attempt to rephrase them.

* ja/do-not-ask-needless-questions:
git-filter-branch: be more direct in an error message
read-tree -m: make error message for merging 0 trees less smart aleck
usability: don't ask questions if no reply is required

Merge branch 'jk/doc-config-include'Junio C Hamano Mon, 29 May 2017 03:34:47 +0000 (12:34 +0900)

Merge branch 'jk/doc-config-include'

Clarify documentation for include.path and includeIf.<condition>.path
configuration variables.

* jk/doc-config-include:
docs/config: consistify include.path examples
docs/config: avoid the term "expand" for includes
docs/config: give a relative includeIf example
docs/config: clarify include/includeIf relationship

Merge branch 'sg/core-filemode-doc-typofix'Junio C Hamano Mon, 29 May 2017 03:34:46 +0000 (12:34 +0900)

Merge branch 'sg/core-filemode-doc-typofix'

* sg/core-filemode-doc-typofix:
docs/config.txt: fix indefinite article in core.fileMode description

Merge branch 'jk/bug-to-abort'Junio C Hamano Mon, 29 May 2017 03:34:45 +0000 (12:34 +0900)

Merge branch 'jk/bug-to-abort'

Introduce the BUG() macro to improve die("BUG: ...").

* jk/bug-to-abort:
usage: add NORETURN to BUG() function definitions
config: complain about --local outside of a git repo
setup_git_env: convert die("BUG") to BUG()
usage.c: add BUG() function

Merge branch 'js/eol-on-ourselves'Junio C Hamano Mon, 29 May 2017 03:34:45 +0000 (12:34 +0900)

Merge branch 'js/eol-on-ourselves'

Make sure our tests would pass when the sources are checked out
with "platform native" line ending convention by default on
Windows. Some "text" files out tests use and the test scripts
themselves that are meant to be run with /bin/sh, ought to be
checked out with eol=LF even on Windows.

* js/eol-on-ourselves:
t4051: mark supporting files as requiring LF-only line endings
Fix the remaining tests that failed with core.autocrlf=true
t3901: move supporting files into t/t3901/
completion: mark bash script as LF-only
git-new-workdir: mark script as LF-only
Fix build with core.autocrlf=true

Merge branch 'jc/read-tree-empty-with-m'Junio C Hamano Mon, 29 May 2017 03:34:45 +0000 (12:34 +0900)

Merge branch 'jc/read-tree-empty-with-m'

"git read-tree -m" (no tree-ish) gave a nonsense suggestion "use
--empty if you want to clear the index". With "-m", such a request
will still fail anyway, as you'd need to name at least one tree-ish
to be merged.

* jc/read-tree-empty-with-m:
read-tree: "read-tree -m --empty" does not make sense

Merge branch 'js/plug-leaks'Junio C Hamano Mon, 29 May 2017 03:34:44 +0000 (12:34 +0900)

Merge branch 'js/plug-leaks'

Fix memory leaks pointed out by Coverity (and people).

* js/plug-leaks: (26 commits)
checkout: fix memory leak
submodule_uses_worktrees(): plug memory leak
show_worktree(): plug memory leak
name-rev: avoid leaking memory in the `deref` case
remote: plug memory leak in match_explicit()
add_reflog_for_walk: avoid memory leak
shallow: avoid memory leak
line-log: avoid memory leak
receive-pack: plug memory leak in update()
fast-export: avoid leaking memory in handle_tag()
mktree: plug memory leaks reported by Coverity
pack-redundant: plug memory leak
setup_discovered_git_dir(): plug memory leak
setup_bare_git_dir(): help static analysis
split_commit_in_progress(): simplify & fix memory leak
checkout: fix memory leak
cat-file: fix memory leak
mailinfo & mailsplit: check for EOF while parsing
status: close file descriptor after reading git-rebase-todo
difftool: address a couple of resource/memory leaks
...

Merge branch 'jk/disable-pack-reuse-when-broken'Junio C Hamano Mon, 29 May 2017 03:34:44 +0000 (12:34 +0900)

Merge branch 'jk/disable-pack-reuse-when-broken'

"pack-objects" can stream a slice of an existing packfile out when
the pack bitmap can tell that the reachable objects are all needed
in the output, without inspecting individual objects. This
strategy however would not work well when "--local" and other
options are in use, and need to be disabled.

* jk/disable-pack-reuse-when-broken:
t5310: fix "; do" style
pack-objects: disable pack reuse for object-selection options

Merge branch 'bc/object-id'Junio C Hamano Mon, 29 May 2017 03:34:43 +0000 (12:34 +0900)

Merge branch 'bc/object-id'

Conversion from uchar[20] to struct object_id continues.

* bc/object-id: (53 commits)
object: convert parse_object* to take struct object_id
tree: convert parse_tree_indirect to struct object_id
sequencer: convert do_recursive_merge to struct object_id
diff-lib: convert do_diff_cache to struct object_id
builtin/ls-tree: convert to struct object_id
merge: convert checkout_fast_forward to struct object_id
sequencer: convert fast_forward_to to struct object_id
builtin/ls-files: convert overlay_tree_on_cache to object_id
builtin/read-tree: convert to struct object_id
sha1_name: convert internals of peel_onion to object_id
upload-pack: convert remaining parse_object callers to object_id
revision: convert remaining parse_object callers to object_id
revision: rename add_pending_sha1 to add_pending_oid
http-push: convert process_ls_object and descendants to object_id
refs/files-backend: convert many internals to struct object_id
refs: convert struct ref_update to use struct object_id
ref-filter: convert some static functions to struct object_id
Convert struct ref_array_item to struct object_id
Convert the verify_pack callback to struct object_id
Convert lookup_tag to struct object_id
...

Merge branch 'nd/split-index-unshare'Junio C Hamano Mon, 29 May 2017 03:34:43 +0000 (12:34 +0900)

Merge branch 'nd/split-index-unshare'

Plug some leaks and updates internal API used to implement the
split index feature to make it easier to avoid such a leak in the
future.

* nd/split-index-unshare:
p3400: add perf tests for rebasing many changes
split-index: add and use unshare_split_index()

Merge branch 'jk/diff-submodule-diff-inline'Junio C Hamano Mon, 29 May 2017 03:34:42 +0000 (12:34 +0900)

Merge branch 'jk/diff-submodule-diff-inline'

"git diff --submodule=diff" now recurses into nested submodules.

* jk/diff-submodule-diff-inline:
diff: recurse into nested submodules for inline diff

Merge branch 'bw/dir-c-stops-relying-on-the-index'Junio C Hamano Mon, 29 May 2017 03:34:41 +0000 (12:34 +0900)

Merge branch 'bw/dir-c-stops-relying-on-the-index'

API update.

* bw/dir-c-stops-relying-on-the-index:
dir: convert fill_directory to take an index
dir: convert read_directory to take an index
dir: convert read_directory_recursive to take an index
dir: convert open_cached_dir to take an index
dir: convert is_excluded to take an index
dir: convert prep_exclude to take an index
dir: convert add_excludes to take an index
dir: convert is_excluded_from_list to take an index
dir: convert last_exclude_matching_from_list to take an index
dir: convert dir_add* to take an index
dir: convert get_dtype to take index
dir: convert directory_exists_in_index to take index
dir: convert read_skip_worktree_file_from_index to take an index
dir: stop using the index compatibility macros

Merge branch 'sb/checkout-recurse-submodules'Junio C Hamano Mon, 29 May 2017 03:34:41 +0000 (12:34 +0900)

Merge branch 'sb/checkout-recurse-submodules'

"git checkout --recurse-submodules" did not quite work with a
submodule that itself has submodules.

* sb/checkout-recurse-submodules:
submodule: properly recurse for read-tree and checkout
submodule: avoid auto-discovery in new working tree manipulator code
submodule_move_head: reuse child_process structure for futher commands

Merge branch 'jc/repack-threads'Junio C Hamano Mon, 29 May 2017 03:34:41 +0000 (12:34 +0900)

Merge branch 'jc/repack-threads'

"git repack" learned to accept the --threads=<n> option and pass it
to pack-objects.

* jc/repack-threads:
repack: accept --threads=<n> and pass it down to pack-objects

Merge branch 'sb/reset-recurse-submodules'Junio C Hamano Mon, 29 May 2017 03:34:40 +0000 (12:34 +0900)

Merge branch 'sb/reset-recurse-submodules'

"git reset" learned "--recurse-submodules" option.

* sb/reset-recurse-submodules:
builtin/reset: add --recurse-submodules switch
submodule.c: submodule_move_head works with broken submodules
submodule.c: uninitialized submodules are ignored in recursive commands
entry.c: submodule recursing: respect force flag correctly

docs/config.txt: fix indefinite article in core.fileMod... SZEDER Gábor Thu, 25 May 2017 23:20:46 +0000 (01:20 +0200)

docs/config.txt: fix indefinite article in core.fileMode description

Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Windows: do not treat a path with backslashes as a... Johannes Sixt Thu, 25 May 2017 12:00:13 +0000 (14:00 +0200)

Windows: do not treat a path with backslashes as a remote's nick name

On Windows, the remote repository name in, e.g., `git fetch foo\bar`
is clearly not a nickname for a configured remote repository. However,
the function valid_remote_nick() does not account for backslashes.
Use is_dir_sep() to check for both slashes and backslashes on Windows.

This was discovered while playing with Duy's patches that warn after
fopen() failures. The functions that read the branches and remotes
files are protected by a valid_remote_nick() check. Without this
change, a Windows style absolute path is incorrectly regarded as
nickname and is concatenated to a prefix and used with fopen(). This
triggers warnings because a colon in a path name is not allowed:

C:\Temp\gittest>git fetch C:\Temp\gittest
warning: unable to access '.git/remotes/C:\Temp\gittest': Invalid argument
warning: unable to access '.git/branches/C:\Temp\gittest': Invalid argument
From C:\Temp\gittest
* branch HEAD -> FETCH_HEAD

Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

clean: teach clean -d to preserve ignored pathsSamuel Lijin Tue, 23 May 2017 10:09:37 +0000 (06:09 -0400)

clean: teach clean -d to preserve ignored paths

There is an implicit assumption that a directory containing only
untracked and ignored paths should itself be considered untracked. This
makes sense in use cases where we're asking if a directory should be
added to the git database, but not when we're asking if a directory can
be safely removed from the working tree; as a result, clean -d would
assume that an "untracked" directory containing ignored paths could be
deleted, even though doing so would also remove the ignored paths.

To get around this, we teach clean -d to collect ignored paths and skip
an untracked directory if it contained an ignored path, instead just
removing the untracked contents thereof. To achieve this, cmd_clean()
has to collect all untracked contents of untracked directories, in
addition to all ignored paths, to determine which untracked dirs must be
skipped (because they contain ignored paths) and which ones should *not*
be skipped.

For this purpose, correct_untracked_entries() is introduced to prune a
given dir_struct of untracked entries containing ignored paths and those
untracked entries encompassed by the untracked entries which are not
pruned away.

A memory leak is also fixed in cmd_clean().

This also fixes the known breakage in t7300, since clean -d now skips
untracked directories containing ignored paths.

Signed-off-by: Samuel Lijin <sxlijin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

tag: duplicate mention of --contains should mention... Ævar Arnfjörð Bjarmason Mon, 15 May 2017 12:23:31 +0000 (12:23 +0000)

tag: duplicate mention of --contains should mention --no-contains

Fix a duplicate mention of --contains in the SYNOPSIS to mention
--no-contains.

This fixes an error introduced in my commit ac3f5a3468 ("ref-filter:
add --no-contains option to tag/branch/for-each-ref", 2017-03-24).

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

mingw: simplify PATH handlingRené Scharfe Sat, 20 May 2017 19:35:37 +0000 (21:35 +0200)

mingw: simplify PATH handling

On Windows the environment variable PATH contains a semicolon-separated
list of directories to search for, in order, when looking for the
location of a binary to run. get_path_split() parses it and returns an
array of string copies, which is iterated by path_lookup(), which in
turn passes each entry to lookup_prog().

Change lookup_prog() to take the directory name as a length-limited
string instead of as a NUL-terminated one and parse PATH directly in
path_lookup(). This avoids memory allocations, simplifying the code.

Helped-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Rene Scharfe <l.s.r@web.de>
Acked-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

mingw.h: permit arguments with side effects for is_dir_sepJohannes Sixt Mon, 22 May 2017 18:58:32 +0000 (20:58 +0200)

mingw.h: permit arguments with side effects for is_dir_sep

Taking git-compat-util.h's cue (which uses an inline function to back
is_dir_sep()), let's use an inline function to back also the Windows
version of is_dir_sep(). This avoids problems when calling the function
with arguments that do more than just provide a single character, e.g.
incrementing a pointer. Example:

is_dir_sep(*p++)

Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Documentation: fix formatting typo in pretty-formats.txtAndreas Heiduk Mon, 22 May 2017 20:59:58 +0000 (22:59 +0200)

Documentation: fix formatting typo in pretty-formats.txt

A missing space messed up formatting of the `%(trailers)` format.

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

Documentation: fix reference to ifExists for interpret... Andreas Heiduk Mon, 22 May 2017 19:45:33 +0000 (21:45 +0200)

Documentation: fix reference to ifExists for interpret-trailers

The manual for "git interpret-trailers" mentioned a non-existing
literal `overwrite` for its config option `trailer.ifexists`. The
correct name for that choice is `replace`.

Signed-off-by: Andreas Heiduk <asheiduk@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t5531: fix test descriptionStefan Beller Mon, 22 May 2017 19:01:14 +0000 (12:01 -0700)

t5531: fix test description

The description of the test was not enclosed in single quotes, which
broke the coloring scheme that I am used to. Upon closer inspection
the test is good, but the description is a bit vague. So extend the
description of the first test.

While at it align the description of the file to match what we actually
test in the file.

Signed-off-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Second batch for 2.14Junio C Hamano Tue, 23 May 2017 04:51:32 +0000 (13:51 +0900)

Second batch for 2.14

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

Merge branch 'ab/fix-poison-tests'Junio C Hamano Tue, 23 May 2017 04:46:08 +0000 (13:46 +0900)

Merge branch 'ab/fix-poison-tests'

Update tests to pass under GETTEXT_POISON (a mechanism to ensure
that output strings that should not be translated are not
translated by mistake), and tell TravisCI to run them.

* ab/fix-poison-tests:
travis-ci: add job to run tests with GETTEXT_POISON
travis-ci: setup "prove cache" in "script" step
tests: fix tests broken under GETTEXT_POISON=YesPlease

Merge branch 'tb/dedup-crlf-tests'Junio C Hamano Tue, 23 May 2017 04:46:07 +0000 (13:46 +0900)

Merge branch 'tb/dedup-crlf-tests'

* tb/dedup-crlf-tests:
t0027: tests are not expensive; remove t0025

Merge branch 'jt/push-options-doc'Junio C Hamano Tue, 23 May 2017 04:46:07 +0000 (13:46 +0900)

Merge branch 'jt/push-options-doc'

The receive-pack program now makes sure that the push certificate
records the same set of push options used for pushing.

* jt/push-options-doc:
receive-pack: verify push options in cert
docs: correct receive.advertisePushOptions default

Merge branch 'ab/doc-replace-gmane-links'Junio C Hamano Tue, 23 May 2017 04:46:05 +0000 (13:46 +0900)

Merge branch 'ab/doc-replace-gmane-links'

The Web interface to gmane news archive is long gone, even though
the articles are still accessible via NTTP. Replace the links with
ones to public-inbox.org. Because their message identification is
based on the actual message-id, it is likely that it will be easier
to migrate away from it if/when necessary.

* ab/doc-replace-gmane-links:
doc: replace more gmane links
doc: replace a couple of broken gmane links

Merge branch 'rs/checkout-am-fix-unborn'Junio C Hamano Tue, 23 May 2017 04:46:05 +0000 (13:46 +0900)

Merge branch 'rs/checkout-am-fix-unborn'

A few codepaths in "checkout" and "am" working on an unborn branch
tried to access an uninitialized piece of memory.

* rs/checkout-am-fix-unborn:
am: check return value of resolve_refdup before using hash
checkout: check return value of resolve_refdup before using hash

Merge branch 'ls/travis-relays-for-windows-ci'Junio C Hamano Tue, 23 May 2017 04:46:03 +0000 (13:46 +0900)

Merge branch 'ls/travis-relays-for-windows-ci'

* ls/travis-relays-for-windows-ci:
travis-ci: retry if Git for Windows CI returns HTTP error 502 or 503
travis-ci: handle Git for Windows CI status "failed" explicitly

Merge branch 'ah/log-decorate-default-to-auto'Junio C Hamano Tue, 23 May 2017 04:46:02 +0000 (13:46 +0900)

Merge branch 'ah/log-decorate-default-to-auto'

Setting "log.decorate=false" in the configuration file did not take
effect in v2.13, which has been corrected.

* ah/log-decorate-default-to-auto:
builtin/log: honor log.decorate

Merge branch 'bw/submodule-with-bs-path'Junio C Hamano Tue, 23 May 2017 04:46:01 +0000 (13:46 +0900)

Merge branch 'bw/submodule-with-bs-path'

A hotfix to a topic that is already in v2.13.

* bw/submodule-with-bs-path:
t7400: add !CYGWIN prerequisite to 'add with \\ in path'

dir: expose cmp_name() and check_contains()Samuel Lijin Thu, 18 May 2017 08:21:53 +0000 (04:21 -0400)

dir: expose cmp_name() and check_contains()

We want to use cmp_name() and check_contains() (which both compare
`struct dir_entry`s, the former in terms of the sort order, the latter
in terms of whether one lexically contains another) outside of dir.c,
so we have to (1) change their linkage and (2) rename them as
appropriate for the global namespace. The second is achieved by
renaming cmp_name() to cmp_dir_entry() and check_contains() to
check_dir_entry_contains().

Signed-off-by: Samuel Lijin <sxlijin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

dir: hide untracked contents of untracked dirsSamuel Lijin Thu, 18 May 2017 08:21:52 +0000 (04:21 -0400)

dir: hide untracked contents of untracked dirs

When we taught read_directory_recursive() to recurse into untracked
directories in search of ignored files given DIR_SHOW_IGNORED_TOO, that
had the side effect of teaching it to collect the untracked contents of
untracked directories. It doesn't always make sense to return these,
though (we do need them for `clean -d`), so we introduce a flag
(DIR_KEEP_UNTRACKED_CONTENTS) to control whether or not read_directory()
strips dir->entries of the untracked contents of untracked dirs.

We also introduce check_contains() to check if one dir_entry corresponds
to a path which contains the path corresponding to another dir_entry.

This also fixes known breakages in t7061, since status --ignored now
searches untracked directories for ignored files.

Signed-off-by: Samuel Lijin <sxlijin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

dir: recurse into untracked dirs for ignored filesSamuel Lijin Thu, 18 May 2017 08:21:51 +0000 (04:21 -0400)

dir: recurse into untracked dirs for ignored files

We consider directories containing only untracked and ignored files to
be themselves untracked, which in the usual case means we don't have to
search these directories. This is problematic when we want to collect
ignored files with DIR_SHOW_IGNORED_TOO, though, so we teach
read_directory_recursive() to recurse into untracked directories to find
the ignored files they contain when DIR_SHOW_IGNORED_TOO is set. This
has the side effect of also collecting all untracked files in untracked
directories as well.

Signed-off-by: Samuel Lijin <sxlijin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t7061: status --ignored should search untracked dirsSamuel Lijin Thu, 18 May 2017 08:21:50 +0000 (04:21 -0400)

t7061: status --ignored should search untracked dirs

Per eb8c5b87, `status --ignored` by design does not list ignored files
if they are in a directory which contains only ignored and untracked
files (which is itself considered to be untracked) without `-uall`. This
does not make sense for `--ignored`, which claims to "Show ignored files
as well."

Thus we revisit eb8c5b87 and decide that for such directories, `status
--ignored` will list the directory as untracked *and* list all ignored
files within said directory even without `-uall`.

Signed-off-by: Samuel Lijin <sxlijin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t7300: clean -d should skip dirs with ignored filesSamuel Lijin Thu, 18 May 2017 08:21:49 +0000 (04:21 -0400)

t7300: clean -d should skip dirs with ignored files

If git sees a directory which contains only untracked and ignored
files, clean -d should not remove that directory. It was recently
discovered that this is *not* true of git clean -d, and it's possible
that this has never worked correctly; this test and its accompanying
patch series aims to fix that.

Signed-off-by: Samuel Lijin <sxlijin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

usage: add NORETURN to BUG() function definitionsRamsay Jones Sun, 21 May 2017 22:25:39 +0000 (23:25 +0100)

usage: add NORETURN to BUG() function definitions

Commit d8193743e0 ("usage.c: add BUG() function", 12-05-2017) added the
BUG() functions and macros as a replacement for calls to die("BUG: ..").
The use of NORETURN on the declarations (in git-compat-util.h) and the
lack of NORETURN on the function definitions, however, leads sparse to
complain thus:

SP usage.c
usage.c:220:6: error: symbol 'BUG_fl' redeclared with different type
(originally declared at git-compat-util.h:1074) - different modifiers

In order to suppress the sparse error, add the NORETURN to the function
definitions.

Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

send-email: Net::SMTP::SSL is obsolete, use only when... Dennis Kaarsemaker Fri, 24 Mar 2017 21:37:32 +0000 (22:37 +0100)

send-email: Net::SMTP::SSL is obsolete, use only when necessary

Net::SMTP itself can do the necessary SSL and STARTTLS bits just fine
since version 1.28, and Net::SMTP::SSL is now deprecated. Since 1.28
isn't that old yet, keep the old code in place and use it when
necessary.

While we're in the area, mark some messages for translation that were
not yet marked as such.

Signed-off-by: Dennis Kaarsemaker <dennis@kaarsemaker.net>
Reviewed-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

revision.c: ignore broken tags with ignore_missing_linksJeff King Sat, 20 May 2017 08:30:25 +0000 (04:30 -0400)

revision.c: ignore broken tags with ignore_missing_links

When peeling a tag for prepare_revision_walk(), we do not
respect the ignore_missing_links flag. This can lead to a
bogus error when pack-objects walks the possibly-broken
unreachable-but-recent part of the object graph.

The other link-following all happens via traverse_commit_list(),
which explains why this case was missed. And our tests
covered only broken links from commits. Let's be more
comprehensive and cover broken tree entries (which do work)
and tags (which shows off this bug).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

config.txt: add an entry for log.showSignatureKyle Meyer Fri, 19 May 2017 02:44:51 +0000 (22:44 -0400)

config.txt: add an entry for log.showSignature

The configuration variable log.showSignature is mentioned in git-log's
manpage. Document it in git-config's manpage as well.

Signed-off-by: Kyle Meyer <kyle@kyleam.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

unpack-trees: preserve index extensionsDavid Turner Mon, 8 May 2017 09:41:42 +0000 (11:41 +0200)

unpack-trees: preserve index extensions

Make git checkout (and other unpack_tree operations) preserve the
untracked cache. This is valuable for two reasons:

1. Often, an unpack_tree operation will not touch large parts of the
working tree, and thus most of the untracked cache will continue to be
valid.

2. Even if the untracked cache were entirely invalidated by such an
operation, the user has signaled their intention to have such a cache,
and we don't want to throw it away.

[jes: backed out the watchman-specific parts]

Signed-off-by: David Turner <dturner@twopensource.com>
Signed-off-by: Ben Peart <benpeart@microsoft.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

rebase -i: add missing newline to end of messagePhillip Wood Fri, 19 May 2017 14:32:48 +0000 (15:32 +0100)

rebase -i: add missing newline to end of message

The message that's printed when auto-stashed changes are successfully
restored was missing '\n' at the end.

Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk>
Acked-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

rebase -i: silence stash applyPhillip Wood Thu, 18 May 2017 10:02:33 +0000 (11:02 +0100)

rebase -i: silence stash apply

The shell version of rebase -i silences the status output from 'git
stash apply' when restoring the autostashed changes. The C version
does not.

Having the output from git stash apply on the screen is
distracting as it makes it difficult to find the message from git
rebase saying that the rebase succeeded. Also the status information
that git stash prints talks about looking in .git/rebase-merge/done to
see which commits have been applied. As .git/rebase-merge is removed
shortly after the message is printed before rebase -i exits this is
confusing.

Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk>
Acked-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

rebase -i: fix reflog messagePhillip Wood Thu, 18 May 2017 10:02:32 +0000 (11:02 +0100)

rebase -i: fix reflog message

When rebase -i was converted to C a bug was introduced into the code
that creates the reflog message. Instead of saying
rebase -i (finish): <head-name> onto <onto>
it says
rebase -i (finish): <head-name> onto <orig-head><onto>
as the strbuf is not reset between reading the value of <orig-head>
and <onto>.

Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk>
Acked-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

ref-filter: resolve HEAD when parsing %(HEAD) atomJeff King Fri, 19 May 2017 06:12:12 +0000 (02:12 -0400)

ref-filter: resolve HEAD when parsing %(HEAD) atom

If the user asks to display (or sort by) the %(HEAD) atom,
ref-filter has to compare each refname to the value of HEAD.
We do so by resolving HEAD fresh when calling populate_value()
on each ref. If there are a large number of refs, this can
have a measurable impact on runtime.

Instead, let's resolve HEAD once when we realize we need the
%(HEAD) atom, allowing us to do a simple string comparison
for each ref. On a repository with 3000 branches (high, but
an actual example found in the wild) this drops the
best-of-five time to run "git branch >/dev/null" from 59ms
to 48ms (~20% savings).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

name-rev: change a "long" variable to timestamp_tJunio C Hamano Sat, 20 May 2017 05:39:43 +0000 (14:39 +0900)

name-rev: change a "long" variable to timestamp_t

Earlier dddbad72 ("timestamp_t: a new data type for timestamps",
2017-04-26) updated all in-core variables, fields and function
return values that are used to store "seconds since epoch" to a new
type timestamp_t. Unfortunately one variable "cutoff", which is
used to keep track of the oldest timestamp of commit we saw on the
command line, was "long" and left behind.

Update it to timestamp_t as well.

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

interpret-trailers: honor the cut lineBrian Malehorn Tue, 16 May 2017 06:06:49 +0000 (23:06 -0700)

interpret-trailers: honor the cut line

If a commit message is edited with the "verbose" option, the buffer
will have a cut line and diff after the log message, like so:

my subject

# ------------------------ >8 ------------------------
# Do not touch the line above.
# Everything below will be removed.
diff --git a/foo.txt b/foo.txt
index 5716ca5..7601807 100644
--- a/foo.txt
+++ b/foo.txt
@@ -1 +1 @@
-bar
+baz

"git interpret-trailers" is unaware of the cut line, and assumes the
trailer block would be at the end of the whole thing. This can easily
be seen with:

$ GIT_EDITOR='git interpret-trailers --in-place --trailer Acked-by:me' \
git commit --amend -v

Teach "git interpret-trailers" to notice the cut-line and ignore the
remainder of the input when looking for a place to add new trailer
block. This makes it consistent with how "git commit -v -s" inserts a
new Signed-off-by: line.

This can be done by the same logic as the existing helper function,
wt_status_truncate_message_at_cut_line(), uses, but it wants the caller
to pass a strbuf to it. Because the function ignore_non_trailer() used
by the command takes a <pointer, length> pair, not a strbuf, steal the
logic from wt_status_truncate_message_at_cut_line() to create a new
wt_status_locate_end() helper function that takes <pointer, length>
pair, and make ignore_non_trailer() call it to help "interpret-trailers".

Since there is only one caller of wt_status_truncate_message_at_cut_line()
in cmd_commit(), rewrite it to call wt_status_locate_end() helper instead
and remove the old helper that no longer has any caller.

Signed-off-by: Brian Malehorn <bmalehorn@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t5400: avoid concurrent writes into a trace fileJeff King Thu, 18 May 2017 05:02:09 +0000 (01:02 -0400)

t5400: avoid concurrent writes into a trace file

One test in t5400 examines the packet exchange between git-push and
git-receive-pack. The latter inherits the GIT_TRACE_PACKET environment
variable, so that both processes dump trace data into the same file
concurrently. This should not be a problem because the trace file is
opened with O_APPEND.

On Windows, however, O_APPEND is not atomic as it should be: it is
emulated as lseek(SEEK_END) followed by write(). For this reason, the
test is unreliable: it can happen that one process overwrites a line
that was just written by the other process. As a consequence, the test
sometimes does not find one or another line that is expected (and it is
also successful occasionally).

The test case is actually only interested in the output of git-push.
To ensure that only git-push writes to the trace file, override the
receive-pack command such that it does not even open the trace file.

Reported-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t5545: enhance test coverage when no http server is... Stefan Beller Wed, 17 May 2017 03:11:03 +0000 (20:11 -0700)

t5545: enhance test coverage when no http server is installed

In commit 438fc68462 ("push options: pass push options to the transport
helper", 08-02-2017), the test coverage was reduced to run no tests at all
if you lack a http server. Move the http initialization to the end,
such that only http tests are skipped when a http server is missing.

The test in between that tests submodule propagation is safe to run before
the http tests as it makes its own test directories `parent` and
`parent_upstream`.

Noticed-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

test: allow skipping the remainderJunio C Hamano Thu, 18 May 2017 02:52:20 +0000 (11:52 +0900)

test: allow skipping the remainder

Because TAP output does not like to see the remainder of the test
getting skipped after running one or more tests, bf4b7219
("test-lib.sh: Add check for invalid use of 'skip_all' facility",
2012-09-01) made sure that test_done errors out when this happens.

Instead, loosen the check so that we only pretend that the rest of
the test script did not exist in such a case. We'd lose a bit of
information (i.e. TAP does not notice that we are skipping some
tests), but not very much (i.e. TAP wasn't told how many tests are
skipped anyway).

This will allow inclusion of lib-httpd.sh in the middle of a test,
which will skip the remainder of the test scripts when tests that
involve web server are declined with GIT_TEST_HTTPD=false, for
example.

Acked-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

completion: add git stash pushThomas Gummerer Tue, 16 May 2017 19:59:45 +0000 (20:59 +0100)

completion: add git stash push

When introducing git stash push in f5727e26e4 ("stash: introduce push
verb", 2017-02-19), I forgot to add it to the completion code. Add it
now.

Signed-off-by: Thomas Gummerer <t.gummerer@gmail.com>
Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

config: match both symlink & realpath versions in Inclu... Ævar Arnfjörð Bjarmason Tue, 16 May 2017 08:28:46 +0000 (08:28 +0000)

config: match both symlink & realpath versions in IncludeIf.gitdir:*

Change the conditional inclusion mechanism to support
e.g. gitdir:~/git_tree/repo where ~/git_tree is a symlink to
/mnt/stuff/repo.

This worked in the initial version of this facility[1], but regressed
later in the series while solving a related bug[2].

Now gitdir: will match against the symlinked
path (e.g. gitdir:~/git_tree/repo) in addition to the current
/mnt/stuff/repo path.

Since this is already in a release version note in the documentation
that this behavior changed, so users who expect their configuration to
work on both v2.13.0 and some future version of git with this fix
aren't utterly confused.

1. commit 3efd0bedc6 ("config: add conditional include", 2017-03-01)
2. commit 86f9515708 ("config: resolve symlinks in conditional
include's patterns", 2017-04-05)

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Start post 2.13 cycleJunio C Hamano Tue, 16 May 2017 02:52:09 +0000 (11:52 +0900)

Start post 2.13 cycle

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

Merge branch 'js/larger-timestamps'Junio C Hamano Tue, 16 May 2017 02:51:59 +0000 (11:51 +0900)

Merge branch 'js/larger-timestamps'

Some platforms have ulong that is smaller than time_t, and our
historical use of ulong for timestamp would mean they cannot
represent some timestamp that the platform allows. Invent a
separate and dedicated timestamp_t (so that we can distingiuish
timestamps and a vanilla ulongs, which along is already a good
move), and then declare uintmax_t is the type to be used as the
timestamp_t.

* js/larger-timestamps:
archive-tar: fix a sparse 'constant too large' warning
use uintmax_t for timestamps
date.c: abort if the system time cannot handle one of our timestamps
timestamp_t: a new data type for timestamps
PRItime: introduce a new "printf format" for timestamps
parse_timestamp(): specify explicitly where we parse timestamps
t0006 & t5000: skip "far in the future" test when time_t is too limited
t0006 & t5000: prepare for 64-bit timestamps
ref-filter: avoid using `unsigned long` for catch-all data type

Merge branch 'jc/apply-fix-mismerge'Junio C Hamano Tue, 16 May 2017 02:51:59 +0000 (11:51 +0900)

Merge branch 'jc/apply-fix-mismerge'

* jc/apply-fix-mismerge:
apply.c: fix whitespace-only mismerge

Merge branch 'ab/aix-needs-compat-regex'Junio C Hamano Tue, 16 May 2017 02:51:58 +0000 (11:51 +0900)

Merge branch 'ab/aix-needs-compat-regex'

Build fix.

* ab/aix-needs-compat-regex:
config.mak.uname: set NO_REGEX=NeedsStartEnd on AIX

Merge branch 'jn/credential-doc-on-clear'Junio C Hamano Tue, 16 May 2017 02:51:57 +0000 (11:51 +0900)

Merge branch 'jn/credential-doc-on-clear'

Doc update.

* jn/credential-doc-on-clear:
credential doc: make multiple-helper behavior more prominent

Merge branch 'jn/clone-add-empty-config-from-command... Junio C Hamano Tue, 16 May 2017 02:51:56 +0000 (11:51 +0900)

Merge branch 'jn/clone-add-empty-config-from-command-line'

"git clone --config var=val" is a way to populate the
per-repository configuration file of the new repository, but it did
not work well when val is an empty string. This has been fixed.

* jn/clone-add-empty-config-from-command-line:
clone: handle empty config values in -c

Merge branch 'bw/submodule-has-commits-update'Junio C Hamano Tue, 16 May 2017 02:51:56 +0000 (11:51 +0900)

Merge branch 'bw/submodule-has-commits-update'

Code clean-up and duplicate removal.

* bw/submodule-has-commits-update:
submodule: refactor logic to determine changed submodules
submodule: improve submodule_has_commits()
submodule: change string_list changed_submodule_paths
submodule: remove add_oid_to_argv()
submodule: rename free_submodules_sha1s()
submodule: rename add_sha1_to_array()

Merge branch 'ls/travis-doc-asciidoctor'Junio C Hamano Tue, 16 May 2017 02:51:55 +0000 (11:51 +0900)

Merge branch 'ls/travis-doc-asciidoctor'

Travis CI gained a task to format the documentation with both
AsciiDoc and AsciiDoctor.

* ls/travis-doc-asciidoctor:
travis-ci: check AsciiDoc/AsciiDoctor stderr output
travis-ci: unset compiler for jobs that do not need one
travis-ci: parallelize documentation build
travis-ci: build documentation with AsciiDoc and Asciidoctor

Merge branch 'rs/large-zip'Junio C Hamano Tue, 16 May 2017 02:51:54 +0000 (11:51 +0900)

Merge branch 'rs/large-zip'

"git archive --format=zip" learned to use zip64 extension when
necessary to go beyond the 4GB limit.

* rs/large-zip:
t5004: require 64-bit support for big ZIP tests
archive-zip: set version field for big files correctly
archive-zip: support files bigger than 4GB
archive-zip: support archives bigger than 4GB
archive-zip: write ZIP dir entry directly to strbuf
archive-zip: use strbuf for ZIP directory
archive-zip: add tests for big ZIP archives

Merge branch 'ab/clone-no-tags'Junio C Hamano Tue, 16 May 2017 02:51:54 +0000 (11:51 +0900)

Merge branch 'ab/clone-no-tags'

"git clone" learned the "--no-tags" option not to fetch all tags
initially, and also set up the tagopt not to follow any tags in
subsequent fetches.

* ab/clone-no-tags:
tests: rename a test having to do with shallow submodules
clone: add a --no-tags option to clone without tags
tests: change "cd ... && git fetch" to "cd &&\n\tgit fetch"

Merge branch 'sk/status-short-branch-color-config'Junio C Hamano Tue, 16 May 2017 02:51:53 +0000 (11:51 +0900)

Merge branch 'sk/status-short-branch-color-config'

The colors in which "git status --short --branch" showed the names
of the current branch and its remote-tracking branch are now
configurable.

* sk/status-short-branch-color-config:
status: add color config slots for branch info in "--short --branch"
status: fix missing newline when comment chars are disabled

Merge branch 'jk/am-leakfix'Junio C Hamano Tue, 16 May 2017 02:51:53 +0000 (11:51 +0900)

Merge branch 'jk/am-leakfix'

The codepath in "git am" that is used when running "git rebase"
leaked memory held for the log message of the commits being rebased.

* jk/am-leakfix:
am: shorten ident_split variable name in get_commit_info()
am: simplify allocations in get_commit_info()
am: fix commit buffer leak in get_commit_info()