Commit graph

44194 commits

Author SHA1 Message Date
Junio C Hamano d012326d48 Merge branch 'hv/doc-commit-reference-style'
A small doc update.

* hv/doc-commit-reference-style:
  SubmittingPatches: use gitk's "Copy commit summary" format
2016-09-08 21:49:51 -07:00
Junio C Hamano 02c6c14d6c Merge branch 'sb/submodule-clone-rr'
"git clone --resurse-submodules --reference $path $URL" is a way to
reduce network transfer cost by borrowing objects in an existing
$path repository when cloning the superproject from $URL; it
learned to also peek into $path for presense of corresponding
repositories of submodules and borrow objects from there when able.

* sb/submodule-clone-rr:
  clone: recursive and reference option triggers submodule alternates
  clone: implement optional references
  clone: clarify option_reference as required
  clone: factor out checking for an alternate path
  submodule--helper update-clone: allow multiple references
  submodule--helper module-clone: allow multiple references
  t7408: merge short tests, factor out testing method
  t7408: modernize style
2016-09-08 21:49:50 -07:00
Junio C Hamano 00d27937bf Merge branch 'jh/status-v2-porcelain'
Enhance "git status --porcelain" output by collecting more data on
the state of the index and the working tree files, which may
further be used to teach git-prompt (in contrib/) to make fewer
calls to git.

* jh/status-v2-porcelain:
  status: unit tests for --porcelain=v2
  test-lib-functions.sh: add lf_to_nul helper
  git-status.txt: describe --porcelain=v2 format
  status: print branch info with --porcelain=v2 --branch
  status: print per-file porcelain v2 status data
  status: collect per-file data for --porcelain=v2
  status: support --porcelain[=<version>]
  status: cleanup API to wt_status_print
  status: rename long-format print routines
2016-09-08 21:49:50 -07:00
Junio C Hamano d0b61dc65f Merge branch 'po/range-doc'
Clarify various ways to specify the "revision ranges" in the
documentation.

* po/range-doc:
  doc: revisions: sort examples and fix alignment of the unchanged
  doc: revisions: show revision expansion in examples
  doc: revisions - clarify reachability examples
  doc: revisions - define `reachable`
  doc: gitrevisions - clarify 'latter case' is revision walk
  doc: gitrevisions - use 'reachable' in page description
  doc: revisions: single vs multi-parent notation comparison
  doc: revisions: extra clarification of <rev>^! notation effects
  doc: revisions: give headings for the two and three dot notations
  doc: show the actual left, right, and boundary marks
  doc: revisions - name the left and right sides
  doc: use 'symmetric difference' consistently
2016-09-08 21:49:49 -07:00
Junio C Hamano d7ed183a91 Merge branch 'rt/help-unknown'
"git nosuchcommand --help" said "No manual entry for gitnosuchcommand",
which was not intuitive, given that "git nosuchcommand" said "git:
'nosuchcommand' is not a git command".

* rt/help-unknown:
  help: make option --help open man pages only for Git commands
  help: introduce option --exclude-guides
2016-09-08 21:49:48 -07:00
Junio C Hamano da3b6f06e1 Merge branch 'cc/receive-pack-limit'
An incoming "git push" that attempts to push too many bytes can now
be rejected by setting a new configuration variable at the receiving
end.

* cc/receive-pack-limit:
  receive-pack: allow a maximum input size to be specified
  unpack-objects: add --max-input-size=<size> option
  index-pack: add --max-input-size=<size> option
2016-09-08 21:49:47 -07:00
Junio C Hamano 452a9073ba Merge branch 'jk/format-patch-number-singleton-patch-with-cover'
"git format-patch --cover-letter HEAD^" to format a single patch
with a separate cover letter now numbers the output as [PATCH 0/1]
and [PATCH 1/1] by default.

* jk/format-patch-number-singleton-patch-with-cover:
  format-patch: show 0/1 and 1/1 for singleton patch with cover letter
2016-09-08 21:49:47 -07:00
Junio C Hamano c4071eace9 Merge branch 'jk/delta-base-cache'
The delta-base-cache mechanism has been a key to the performance in
a repository with a tightly packed packfile, but it did not scale
well even with a larger value of core.deltaBaseCacheLimit.

* jk/delta-base-cache:
  t/perf: add basic perf tests for delta base cache
  delta_base_cache: use hashmap.h
  delta_base_cache: drop special treatment of blobs
  delta_base_cache: use list.h for LRU
  release_delta_base_cache: reuse existing detach function
  clear_delta_base_cache_entry: use a more descriptive name
  cache_or_unpack_entry: drop keep_cache parameter
2016-09-08 21:49:46 -07:00
Junio C Hamano 6ebdac1bab Git 2.10
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-09-02 09:05:47 -07:00
Junio C Hamano dd39dfcf8a l10n-2.10.0-rnd2.2
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXyYCAAAoJEMek6Rt1RHoouFkP/0n836xBjmhMQAd7ksJ6UrVO
 YoWMq1Qa7Ox4FLSgpmxS+Q80/vgWgI4ESN9kAoyfR4axbhaK8WzRTkR8F5LA1jmf
 0k2EXXNrJqf1LTTztx+fEleSMptMlVun0NJnHT7w0dQcXoeH9dHDbO/p7WZKCxXO
 qQ7KkmHMVW1EnO+QkUtujehfI1oUggc3Crc1pxSG1BvCyodtXYIjUD6wUN00yyeI
 PFzsPyLjk1uVUQESiiSMwr2kj5EqEKx/S8g0I+kLxiEnVCww8Or5a5TYPKG1IDiR
 jnlmCQF8Y3hoNdOyHHV2xaSPIA6OsoJcvYzmMOIDcp2IbGFnGc5ceaTQs5SlS3wP
 GTjwaA0ttYB1JOYjvojlsUIEOYNopaZvphws02iYv10kIL1gkbaBLlXj+roTJ0wP
 6huthQhjYpVu11iCBnRH8/dXwbIs2h86V5l9e5Yj/OVyK9R08LVnV0RaEWrPnwgd
 FdGC1JdOgczIE6tBMoJSRtIf1pbQiEsh0wgj+Vh0bPqB6nJJSCa605Lamhm61FyU
 eoH6pEG+14CmPMpbP8jkctj17FlIQcYaR6LyR/qBLgcYkt9EpxTH1n9RTv+C0bRx
 yR2w/uCwrhSBFmaTQW2cPKrHYdGpyBdvLXUiT1ewCEJgffFun5IT+r6Qhg7B1yXb
 AbAJfibXGeCVgZuRKIQC
 =e4TB
 -----END PGP SIGNATURE-----

Merge tag 'l10n-2.10.0-rnd2.2' of git://github.com/git-l10n/git-po

l10n-2.10.0-rnd2.2

* tag 'l10n-2.10.0-rnd2.2' of git://github.com/git-l10n/git-po:
  l10n: Updated Vietnamese translation for v2.10.0-rc2 (2757t)
2016-09-02 08:48:14 -07:00
Jiang Xin e8e349249c Merge branch 'master' of https://github.com/vnwildman/git
* 'master' of https://github.com/vnwildman/git:
  l10n: Updated Vietnamese translation for v2.10.0-rc2 (2757t)
2016-09-02 21:29:48 +08:00
Junio C Hamano 5b18e70009 A few more fixes before the final 2.10
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-31 10:21:05 -07:00
Junio C Hamano 934b1caa7a l10n-2.10.0-rnd2
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXxuOXAAoJEMek6Rt1RHooEa8QAKO9TwEgUu3RcjoEhoHuncWw
 450/uVcz4rhCZsupzBahcSUI3qcE+GuunezASWQ0IkEXGogLC1CwnBkYzEUYuOvU
 0BH/gao4FfIZmBddCBn/6tUZJG+wTgCsD2ept6oR0RgPo85bHdN3K12S4FTHVmGj
 AK894O60ZJJZuUelbErOzHh52Pgad5BEJ9V6Bt5hBPfWLV/wPvrWm8efk4T88odw
 ErOVUv49gSUqvwA+ot8sq7bcPVhH06CTvw15iWTPmD8hLYdQDTYKL1+PkGJa0uXR
 Qoe4vLhUV8Rz0RGi9aWnlOzAYgIQ9FzkLwDfqz4KCyV1qa5EqorfjwkK1vOug9VY
 Qv5p0fWLIKqCGEyJjy1y87xMi/GgydRI8mZYAaRhHgCc4qMI/E7n4I4+vc6/9i/0
 C7tRW8ylb7UUPENdvZvcOxWgP9y/VMiw/I8wyv3wuzifM5DRxCUCfwMJDQdIzBVI
 T+sPO8cjYjKPATieZ563LBFtmiVoms4U1DDDqH65SzZtsOa2GOruAW3eIFwFmQHE
 hYhyZOFpDhg20EgSKO9owzA5IjtiuplPYJgQmUyiVEeOfcr/Gw+a3CzgCEDNJ8EF
 orjSHIwO0N7BmHDMJeJlGyCuhgG6JLdZDI9d/AiaPFuGiNnnINH5odSz8M5tE1F4
 erUKZgZDpifOYHsSurcF
 =lwbs
 -----END PGP SIGNATURE-----

Merge tag 'l10n-2.10.0-rnd2' of git://github.com/git-l10n/git-po

l10n-2.10.0-rnd2

* tag 'l10n-2.10.0-rnd2' of git://github.com/git-l10n/git-po:
  l10n: zh_CN: for git v2.10.0 l10n round 2
  l10n: ca.po: update translation
  l10n: fr.po v2.10.0-rc2
  l10n: sv.po: Update Swedish translation (2757t0f0u)
  l10n: git.pot: v2.10.0 round 2 (12 new, 44 removed)
  l10n: Updated Vietnamese translation for v2.10.0 (2789t)
  l10n: pt_PT: update Portuguese translation
  l10n: pt_PT: merge git.pot
  l10n: ko.po: Update Korean translation
  l10n: git.pot: v2.10.0 round 1 (248 new, 56 removed)
2016-08-31 10:04:14 -07:00
Junio C Hamano 58e72a2179 Merge branch 'ls/packet-line-protocol-doc-fix'
Correct an age-old calco (is that a typo-like word for calc)
in the documentation.

* ls/packet-line-protocol-doc-fix:
  pack-protocol: fix maximum pkt-line size
2016-08-31 10:03:51 -07:00
Junio C Hamano 4762bf36d9 Merge branch 'mh/blame-worktree'
* mh/blame-worktree:
  blame: fix segfault on untracked files
2016-08-31 10:03:50 -07:00
Junio C Hamano 9010077be2 Merge branch 'kw/patch-ids-optim'
* kw/patch-ids-optim:
  p3400: make test script executable
2016-08-31 10:03:49 -07:00
Ralf Thielow 2c6b6d9f7d help: make option --help open man pages only for Git commands
If option --help is passed to a Git command, we try to open
the man page of that command.  However, we do it for both commands
and concepts.  Make sure it is an actual command.

This makes "git <concept> --help" not working anymore, while
"git help <concept>" still works.

Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-30 16:09:41 -07:00
Ralf Thielow af74128f4a help: introduce option --exclude-guides
Introduce option --exclude-guides to the help command.  With this option
being passed, "git help" will open man pages only for actual commands.

Since we know it is a command, we can use function help_unknown_command
to give the user advice on typos.

Helped-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-30 16:09:41 -07:00
Lars Schneider 7841c4801c pack-protocol: fix maximum pkt-line size
According to LARGE_PACKET_MAX in pkt-line.h the maximal length of a
pkt-line packet is 65520 bytes. The pkt-line header takes 4 bytes and
therefore the pkt-line data component must not exceed 65516 bytes.

Signed-off-by: Lars Schneider <larsxschneider@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-30 11:00:29 -07:00
Jiang Xin 5c57d7622e l10n: zh_CN: for git v2.10.0 l10n round 2
Update 215 translations (2757t0f0u) for git v2.10.0-rc2.

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
2016-08-31 00:11:13 +08:00
René Scharfe ba67504fa8 p3400: make test script executable
Signed-off-by: Rene Scharfe <l.s.r@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-29 12:57:16 -07:00
Thomas Gummerer bc6b13a7d2 blame: fix segfault on untracked files
Since 3b75ee9 ("blame: allow to blame paths freshly added to the index",
2016-07-16) git blame also looks at the index to determine if there is a
file that was freshly added to the index.

cache_name_pos returns -pos - 1 in case there is no match is found, or
if the name matches, but the entry has a stage other than 0.  As git
blame should work for unmerged files, it uses strcmp to determine
whether the name of the returned position matches, in which case the
file exists, but is merely unmerged, or if the file actually doesn't
exist in the index.

If the repository is empty, or if the file would lexicographically be
sorted as the last file in the repository, -cache_name_pos - 1 is
outside of the length of the active_cache array, causing git blame to
segfault.  Guard against that, and die() normally to restore the old
behaviour.

Reported-by: Simon Ruderich <simon@ruderich.org>
Signed-off-by: Thomas Gummerer <t.gummerer@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-29 11:57:33 -07:00
Alex Henrie 63b8265402 l10n: ca.po: update translation
Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
2016-08-28 10:32:56 -06:00
Jean-Noel Avila b67e63067d l10n: fr.po v2.10.0-rc2
Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
2016-08-28 11:36:14 +02:00
Tran Ngoc Quan 800d88e2b3 l10n: Updated Vietnamese translation for v2.10.0-rc2 (2757t)
Signed-off-by: Tran Ngoc Quan <vnwildman@gmail.com>
2016-08-28 07:23:30 +07:00
Peter Krefting 8ed2d3fb15 l10n: sv.po: Update Swedish translation (2757t0f0u)
Signed-off-by: Peter Krefting <peter@softwolves.pp.se>
2016-08-27 20:42:50 +01:00
Jiang Xin b30eec1a69 Merge branch 'master' of https://github.com/vnwildman/git
* 'master' of https://github.com/vnwildman/git:
  l10n: Updated Vietnamese translation for v2.10.0 (2789t)
2016-08-27 23:36:16 +08:00
Jiang Xin 5bd166d8af l10n: git.pot: v2.10.0 round 2 (12 new, 44 removed)
Generate po/git.pot from v2.10.0-rc2 for git v2.10.0 l10n round 2.

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
2016-08-27 23:23:26 +08:00
Jiang Xin fe1280decc Merge branch 'master' of git://github.com/git-l10n/git-po
* 'master' of git://github.com/git-l10n/git-po:
  l10n: pt_PT: update Portuguese translation
  l10n: pt_PT: merge git.pot
  l10n: ko.po: Update Korean translation
  l10n: git.pot: v2.10.0 round 1 (248 new, 56 removed)
2016-08-27 23:14:27 +08:00
Tran Ngoc Quan b9252573c4 l10n: Updated Vietnamese translation for v2.10.0 (2789t)
Signed-off-by: Tran Ngoc Quan <vnwildman@gmail.com>
2016-08-27 09:15:28 +07:00
Beat Bolli 4369523b4b SubmittingPatches: use gitk's "Copy commit summary" format
Update the suggestion in 175d38ca ("SubmittingPatches: document how
to reference previous commits", 2016-07-28) on the format to refer
to a commit to match what gitk has been giving since last year with
its "Copy commit summary" command; also mention this as one of the
ways to obtain a commit reference in this format.

Signed-off-by: Beat Bolli <dev+git@drbeat.li>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-26 15:58:10 -07:00
Junio C Hamano d5cb9cbd64 Git 2.10-rc2
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-26 13:59:20 -07:00
Torsten Bögershausen e28eae3184 gitattributes: Document the unified "auto" handling
Update the documentation about text=auto:
text=auto now follows the core.autocrlf handling when files are not
normalized in the repository.

For a cross platform project recommend the usage of attributes for
line-ending conversions.

Signed-off-by: Torsten Bögershausen <tboegi@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-26 13:54:16 -07:00
Junio C Hamano 3b1c6a9b6e Merge branch 'js/no-html-bypass-on-windows' into rt/help-unknown
* js/no-html-bypass-on-windows:
  Revert "display HTML in default browser using Windows' shell API"
2016-08-26 11:29:07 -07:00
Junio C Hamano 5cb0d5ad05 Prepare for 2.10.0-rc2
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-25 13:56:51 -07:00
Junio C Hamano 0fd6c99bdf Merge branch 'ja/i18n'
The recent i18n patch we added during this cycle did a bit too much
refactoring of the messages to avoid word-legos; the repetition has
been reduced to help translators.

* ja/i18n:
  i18n: simplify numeric error reporting
  i18n: fix git rebase interactive commit messages
  i18n: fix typos for translation
2016-08-25 13:55:07 -07:00
Junio C Hamano 3dc01702df Merge branch 'bw/mingw-avoid-inheriting-fd-to-lockfile'
The tempfile (hence its user lockfile) API lets the caller to open
a file descriptor to a temporary file, write into it and then
finalize it by first closing the filehandle and then either
removing or renaming the temporary file.  When the process spawns a
subprocess after obtaining the file descriptor, and if the
subprocess has not exited when the attempt to remove or rename is
made, the last step fails on Windows, because the subprocess has
the file descriptor still open.  Open tempfile with O_CLOEXEC flag
to avoid this (on Windows, this is mapped to O_NOINHERIT).

* bw/mingw-avoid-inheriting-fd-to-lockfile:
  mingw: ensure temporary file handles are not inherited by child processes
  t6026-merge-attr: child processes must not inherit index.lock handles
2016-08-25 13:55:07 -07:00
Junio C Hamano a8998453be Merge branch 'dg/document-git-c-in-git-config-doc'
The "git -c var[=val] cmd" facility to append a configuration
variable definition at the end of the search order was described in
git(1) manual page, but not in git-config(1), which was more likely
place for people to look for when they ask "can I make a one-shot
override, and if so how?"

* dg/document-git-c-in-git-config-doc:
  doc: mention `git -c` in git-config(1)
2016-08-25 13:55:07 -07:00
Junio C Hamano 13e11ff707 Merge branch 'js/no-html-bypass-on-windows'
On Windows, help.browser configuration variable used to be ignored,
which has been corrected.

* js/no-html-bypass-on-windows:
  Revert "display HTML in default browser using Windows' shell API"
2016-08-25 13:55:06 -07:00
Junio C Hamano a1f0b4e286 Merge branch 'hv/doc-commit-reference-style'
A small doc update.

* hv/doc-commit-reference-style:
  SubmittingPatches: document how to reference previous commits
2016-08-25 13:55:06 -07:00
Torsten Bögershausen 41a616dada git ls-files: text=auto eol=lf is supported in Git 2.10
The man page for `git ls-files --eol` mentions the combination
of text attributes "text=auto eol=lf" or "text=auto eol=crlf" as not
supported yet, but may be in the future.

Now they are supported.

Signed-off-by: Torsten Bögershausen <tboegi@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-25 13:38:18 -07:00
Vasco Almeida 9d83143621 l10n: pt_PT: update Portuguese translation
Signed-off-by: Vasco Almeida <vascomalmeida@sapo.pt>
2016-08-25 13:33:17 +00:00
Vasco Almeida 587dae416d l10n: pt_PT: merge git.pot
Signed-off-by: Vasco Almeida <vascomalmeida@sapo.pt>
2016-08-25 13:33:17 +00:00
Jeff King c08db5a2d0 receive-pack: allow a maximum input size to be specified
Receive-pack feeds its input to either index-pack or
unpack-objects, which will happily accept as many bytes as
a sender is willing to provide. Let's allow an arbitrary
cutoff point where we will stop writing bytes to disk.

Cleaning up what has already been written to disk is a
related problem that is not addressed by this patch.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-24 12:31:05 -07:00
Christian Couder 5ad2186733 unpack-objects: add --max-input-size=<size> option
When receiving a pack-file, it can be useful to abort the
`git unpack-objects`, if the pack-file is too big.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-24 12:31:05 -07:00
Jeff King 411481be6f index-pack: add --max-input-size=<size> option
When receiving a pack-file, it can be useful to abort the
`git index-pack`, if the pack-file is too big.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-24 12:31:05 -07:00
Jean-Noel Avila 078fe30523 i18n: simplify numeric error reporting
Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-24 08:47:20 -07:00
Jean-Noel Avila 8aa6dc1d9e i18n: fix git rebase interactive commit messages
For proper i18n, the logic cannot embed english specific processing.

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-24 08:43:27 -07:00
Jean-Noel Avila cd3e4677cf i18n: fix typos for translation
Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-24 08:41:22 -07:00
Jacob Keller 957ed3a56c format-patch: show 0/1 and 1/1 for singleton patch with cover letter
Change the default behavior of git-format-patch to generate numbered
sequence of 0/1 and 1/1 when generating both a cover-letter and a single
patch. This standardizes the cover letter to have 0/N which helps
distinguish the cover letter from the patch itself. Since the behavior
is easily changed via configuration as well as the use of -n and -N this
should be acceptable default behavior.

Add tests for the new default behavior.

Signed-off-by: Jacob Keller <jacob.keller@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-08-23 15:59:11 -07:00