summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2019-09-18Third batchLibravatar Junio C Hamano1-0/+36
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-09-18Merge branch 'jt/avoid-ls-refs-with-http'Libravatar Junio C Hamano5-24/+62
The http transport lacked some optimization the native transports learned to avoid unnecessary ref advertisement, which has been corrected. * jt/avoid-ls-refs-with-http: transport: teach all vtables to allow fetch first transport-helper: skip ls-refs if unnecessary
2019-09-18Merge branch 'md/list-objects-filter-combo'Libravatar Junio C Hamano22-242/+889
The list-objects-filter API (used to create a sparse/lazy clone) learned to take a combined filter specification. * md/list-objects-filter-combo: list-objects-filter-options: make parser void list-objects-filter-options: clean up use of ALLOC_GROW list-objects-filter-options: allow mult. --filter strbuf: give URL-encoding API a char predicate fn list-objects-filter-options: make filter_spec a string_list list-objects-filter-options: move error check up list-objects-filter: implement composite filters list-objects-filter-options: always supply *errbuf list-objects-filter: put omits set in filter struct list-objects-filter: encapsulate filter components
2019-09-18Merge branch 'cc/multi-promisor'Libravatar Junio C Hamano27-172/+523
Teach the lazy clone machinery that there can be more than one promisor remote and consult them in order when downloading missing objects on demand. * cc/multi-promisor: Move core_partial_clone_filter_default to promisor-remote.c Move repository_format_partial_clone to promisor-remote.c Remove fetch-object.{c,h} in favor of promisor-remote.{c,h} remote: add promisor and partial clone config to the doc partial-clone: add multiple remotes in the doc t0410: test fetching from many promisor remotes builtin/fetch: remove unique promisor remote limitation promisor-remote: parse remote.*.partialclonefilter Use promisor_remote_get_direct() and has_promisor_remote() promisor-remote: use repository_format_partial_clone promisor-remote: add promisor_remote_reinit() promisor-remote: implement promisor_remote_get_direct() Add initial support for many promisor remotes fetch-object: make functions return an error code t0410: remove pipes after git commands
2019-09-18Merge branch 'sg/line-log-tree-diff-optim'Libravatar Junio C Hamano2-19/+134
Optimize unnecessary full-tree diff away from "git log -L" machinery. * sg/line-log-tree-diff-optim: line-log: avoid unnecessary full tree diffs line-log: extract pathspec parsing from line ranges into a helper function
2019-09-18Merge branch 'sg/complete-configuration-variables'Libravatar Junio C Hamano2-64/+243
Command line completion updates for "git -c var.name=val" * sg/complete-configuration-variables: completion: complete config variables and values for 'git clone --config=' completion: complete config variables names and values for 'git clone -c' completion: complete values of configuration variables after 'git -c var=' completion: complete configuration sections and variable names for 'git -c' completion: split _git_config() completion: simplify inner 'case' pattern in __gitcomp() completion: use 'sort -u' to deduplicate config variable names completion: deduplicate configuration sections completion: add tests for 'git config' completion completion: complete more values of more 'color.*' configuration variables completion: fix a typo in a comment
2019-09-18Merge branch 'js/pre-merge-commit-hook'Libravatar Junio C Hamano7-143/+336
A new "pre-merge-commit" hook has been introduced. * js/pre-merge-commit-hook: merge: --no-verify to bypass pre-merge-commit hook git-merge: honor pre-merge-commit hook merge: do no-verify like commit t7503: verify proper hook execution
2019-09-18Merge branch 'cb/curl-use-xmalloc'Libravatar Junio C Hamano1-0/+4
Tell cURL library to use the same malloc() implementation, with the xmalloc() wrapper, as the rest of the system, for consistency. * cb/curl-use-xmalloc: http: use xmalloc with cURL
2019-09-18Merge branch 'jk/drop-release-pack-memory'Libravatar Junio C Hamano6-90/+15
xmalloc() used to have a mechanism to ditch memory and address space resources as the last resort upon seeing an allocation failure from the underlying malloc(), which made the code complex and thread-unsafe with dubious benefit, as major memory resource users already do limit their uses with various other mechanisms. It has been simplified away. * jk/drop-release-pack-memory: packfile: drop release_pack_memory()
2019-09-18Merge branch 'js/rebase-r-strategy'Libravatar Junio C Hamano9-117/+139
"git rebase --rebase-merges" learned to drive different merge strategies and pass strategy specific options to them. * js/rebase-r-strategy: t3427: accelerate this test by using fast-export and fast-import rebase -r: do not (re-)generate root commits with `--root` *and* `--onto` t3418: test `rebase -r` with merge strategies t/lib-rebase: prepare for testing `git rebase --rebase-merges` rebase -r: support merge strategies other than `recursive` t3427: fix another incorrect assumption t3427: accommodate for the `rebase --merge` backend having been replaced t3427: fix erroneous assumption t3427: condense the unnecessarily repetitive test cases into three t3427: move the `filter-branch` invocation into the `setup` case t3427: simplify the `setup` test case significantly t3427: add a clarifying comment rebase: fold git-rebase--common into the -p backend sequencer: the `am` and `rebase--interactive` scripts are gone .gitignore: there is no longer a built-in `git-rebase--interactive` t3400: stop referring to the scripted rebase Drop unused git-rebase--am.sh
2019-09-18Merge branch 'master' of https://github.com/prati0100/git-guiLibravatar Junio C Hamano5-55/+199
* 'master' of https://github.com/prati0100/git-gui: git-gui: add hotkey to toggle "Amend Last Commit" git-gui: add horizontal scrollbar to commit buffer git-gui: convert new/amend commit radiobutton to checkbutton git-gui: add hotkeys to set widget focus git-gui: allow undoing last revert git-gui: return early when patch fails to apply git-gui: allow reverting selected hunk git-gui: allow reverting selected lines
2019-09-17Merge gitk to pick up emergency build fixLibravatar Junio C Hamano1-0/+0
gitk: rename zh_CN.po to zh_cn.po
2019-09-17gitk: rename zh_CN.po to zh_cn.poLibravatar Denton Liu1-0/+0
When running make from a clean environment, all of the *.po files should be converted into *.msg files. After that, when make is run without any changes, make should not do anything. After beffae768a (gitk: Add Chinese (zh_CN) translation, 2017-03-11), zh_CN.po was introduced. When make was run, a zh_cn.msg file was generated (notice the lowercase). However, since make is case-sensitive, it expects zh_CN.po to generate a zh_CN.msg file so make will keep reattempting to generate a zh_CN.msg so successive make invocations result in Generating catalog po/zh_cn.msg msgfmt --statistics --tcl po/zh_cn.po -l zh_cn -d po/ 317 translated messages. happening continuously. Rename zh_CN.po to zh_cn.po so that when make generates the zh_cn.msg file, it will realize that it was successfully generated and only run once. Signed-off-by: Denton Liu <liu.denton@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-09-16Merge branch 'master' of git://ozlabs.org/~paulus/gitkLibravatar Junio C Hamano2-4/+1427
* 'master' of git://ozlabs.org/~paulus/gitk: gitk: Do not mistake unchanged lines for submodule changes gitk: Use right colour for remote refs in the "Tags and heads" dialog gitk: Add Chinese (zh_CN) translation gitk: Make web links clickable
2019-09-14Merge branch 'bp/amend-toggle-bind'Libravatar Pratyush Yadav1-0/+9
Toggle amend on and off with the keyboard shortcut "Ctrl+e". * bp/amend-toggle-bind: git-gui: add hotkey to toggle "Amend Last Commit"
2019-09-14git-gui: add hotkey to toggle "Amend Last Commit"Libravatar Birger Skogeng Pedersen1-0/+9
Selecting whether to "Amend Last Commit" or not does not have a hotkey. With this patch, the user may toggle between the two options with CTRL/CMD+e. Signed-off-by: Birger Skogeng Pedersen <birger.sp@gmail.com> Rebased-by: Bert Wesarg <bert.wesarg@googlemail.com> Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>
2019-09-14gitk: Do not mistake unchanged lines for submodule changesLibravatar Gabriele Mazzotta1-2/+2
Unchanged lines are prefixed with a white-space, thus unchanged lines starting with either " <" or " >" are mistaken for submodule changes. Check if a line starts with either " <" or " >" only if we are listing the changes of a submodule. Signed-off-by: Gabriele Mazzotta <gabriele.mzt@gmail.com> Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
2019-09-14gitk: Use right colour for remote refs in the "Tags and heads" dialogLibravatar Paul Wise1-1/+8
Makes it easier to see which refs are local and which refs are remote. Adds consistency with the remote background colour in the graph display. Signed-off-by: Paul Wise <pabs3@bonedaddy.net> Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
2019-09-14gitk: Add Chinese (zh_CN) translationLibravatar YanKe1-0/+1367
Signed-off-by: YanKe <imyanke@163.com> Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
2019-09-14Merge branch 'bw/commit-scrollbuffer'Libravatar Pratyush Yadav1-0/+6
Add a scrollbar at the bottom of the commit message buffer. * bw/commit-scrollbuffer: git-gui: add horizontal scrollbar to commit buffer
2019-09-14Merge branch 'bw/amend-checkbutton'Libravatar Pratyush Yadav4-36/+18
Change the amend setting from two radio buttons ("New commit" and "Amend commit") to a single checkbutton. The two radio buttons can never be selected together because they are exactly the opposite of each other, so it makes sense to change it to a single checkbutton. * bw/amend-checkbutton: git-gui: convert new/amend commit radiobutton to checkbutton
2019-09-14git-gui: add horizontal scrollbar to commit bufferLibravatar Bert Wesarg1-0/+6
While the commit message widget has a configurable fixed width, it nevertheless allowed to write commit messages which exceeded this limit. Though there is no visual clue, that there is scrolling going on. Now there is a horizontal scrollbar. There seems to be a bug in at least Tcl/Tk up to version 8.6.8, which does not update the horizontal scrollbar if one removes the whole content at once. Suggested-by: Birger Skogeng Pedersen <birger.sp@gmail.com> Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com> Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>
2019-09-14git-gui: convert new/amend commit radiobutton to checkbuttonLibravatar Bert Wesarg4-36/+18
Its a bi-state anyway and also saves one line in the menu. Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com> Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>
2019-09-12Merge branch 'py/revert-hunks-lines'Libravatar Pratyush Yadav2-18/+135
git-gui learned to revert selected lines and hunks, just like it can stage selected lines and hunks. To provide a safety net for accidental revert, the most recent revert can be undone. * py/revert-hunks-lines: git-gui: allow undoing last revert git-gui: return early when patch fails to apply git-gui: allow reverting selected hunk git-gui: allow reverting selected lines
2019-09-12Merge branch 'bp/widget-focus-hotkeys'Libravatar Pratyush Yadav1-1/+31
git-gui learned to switch focus between widgets "unstaged commits", "staged commits", "diff", and "commit message" using the keyboard shortcuts Alt+1, Alt+2, Alt+3, and Alt+4 respectively. * bp/widget-focus-hotkeys: git-gui: add hotkeys to set widget focus
2019-09-11git-gui: add hotkeys to set widget focusLibravatar Birger Skogeng Pedersen1-1/+31
The user cannot change focus between the list of files, the diff view and the commit message widgets without using the mouse (clicking either of the four widgets). With this patch, the user may set ui focus to the previously selected path in either the "Unstaged Changes" or "Staged Changes" widgets, using ALT+1 or ALT+2. The user may also set the ui focus to the diff view widget with ALT+3, or to the commit message widget with ALT+4. This enables the user to select/unselect files, view the diff and create a commit in git-gui using keyboard-only. Signed-off-by: Birger Skogeng Pedersen <birger.sp@gmail.com> Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>
2019-09-09Second batchLibravatar Junio C Hamano1-1/+56
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-09-09Merge branch 'bc/reread-attributes-during-rebase'Libravatar Junio C Hamano9-14/+174
The "git am" based backend of "git rebase" ignored the result of updating ".gitattributes" done in one step when replaying subsequent steps. * bc/reread-attributes-during-rebase: am: reload .gitattributes after patching it path: add a function to check for path suffix
2019-09-09Merge branch 'tg/t0021-racefix'Libravatar Junio C Hamano1-0/+3
A test fix. * tg/t0021-racefix: t0021: make sure clean filter runs
2019-09-09Merge branch 'mp/for-each-ref-missing-name-or-email'Libravatar Junio C Hamano2-3/+22
"for-each-ref" and friends that shows refs did not protect themselves against ancient tags that did not record tagger names when asked to show "%(taggername)", which have been corrected. * mp/for-each-ref-missing-name-or-email: ref-filter: initialize empty name or email fields
2019-09-09Merge branch 'sb/userdiff-dts'Libravatar Junio C Hamano14-0/+168
Device-tree files learned their own userdiff patterns. * sb/userdiff-dts: userdiff: add a builtin pattern for dts files
2019-09-09Merge branch 'rs/sort-oid-array-thread-safe'Libravatar Junio C Hamano1-6/+3
Prepare get_short_oid() codepath to be thread-safe. * rs/sort-oid-array-thread-safe: sha1-name: make sort_ambiguous_oid_array() thread-safe
2019-09-09Merge branch 'nd/diff-parseopt'Libravatar Junio C Hamano1-9/+9
Compilation fix. * nd/diff-parseopt: parseopt: move definition of enum parse_opt_result up
2019-09-09Merge branch 'jt/diff-lazy-fetch-submodule-fix'Libravatar Junio C Hamano2-0/+32
On-demand object fetching in lazy clone incorrectly tried to fetch commits from submodule projects, while still working in the superproject, which has been corrected. * jt/diff-lazy-fetch-submodule-fix: diff: skip GITLINK when lazy fetching missing objs
2019-09-09Merge branch 'ds/midx-expire-repack'Libravatar Junio C Hamano1-1/+1
Code cleanup. * ds/midx-expire-repack: packfile.h: drop extern from function declaration
2019-09-09Merge branch 'cb/fetch-set-upstream'Libravatar Junio C Hamano4-1/+241
"git fetch" learned "--set-upstream" option to help those who first clone from their private fork they intend to push to, add the true upstream via "git remote add" and then "git fetch" from it. * cb/fetch-set-upstream: pull, fetch: add --set-upstream option
2019-09-09Merge branch 'rs/pax-extended-header-length-fix'Libravatar Junio C Hamano2-4/+29
"git archive" recorded incorrect length in extended pax header in some corner cases, which has been corrected. * rs/pax-extended-header-length-fix: archive-tar: turn length miscalculation warning into BUG archive-tar: use size_t in strbuf_append_ext_header() archive-tar: fix pax extended header length calculation archive-tar: report wrong pax extended header length
2019-09-09Merge branch 'bm/repository-layout-typofix'Libravatar Junio C Hamano1-1/+1
Typofix. * bm/repository-layout-typofix: repository-layout.txt: correct pluralization of 'object'
2019-09-09Merge branch 'en/checkout-mismerge-fix'Libravatar Junio C Hamano1-7/+0
Fix a mismerge that happened in 2.22 timeframe. * en/checkout-mismerge-fix: checkout: remove duplicate code
2019-09-09Merge branch 'sg/diff-indent-heuristic-non-experimental'Libravatar Junio C Hamano1-1/+1
We promoted the "indent heuristics" that decides where to split diff hunks from experimental to the default a few years ago, but some stale documentation still marked it as experimental, which has been corrected. * sg/diff-indent-heuristic-non-experimental: diff: 'diff.indentHeuristic' is no longer experimental
2019-09-09Merge branch 'ds/feature-macros'Libravatar Junio C Hamano26-115/+223
A mechanism to affect the default setting for a (related) group of configuration variables is introduced. * ds/feature-macros: repo-settings: create feature.experimental setting repo-settings: create feature.manyFiles setting repo-settings: parse core.untrackedCache commit-graph: turn on commit-graph by default t6501: use 'git gc' in quiet mode repo-settings: consolidate some config settings
2019-09-09Merge branch 'jk/eoo'Libravatar Junio C Hamano6-2/+37
The command line parser learned "--end-of-options" notation; the standard convention for scripters to have hardcoded set of options first on the command line, and force the command to treat end-user input as non-options, has been to use "--" as the delimiter, but that would not work for commands that use "--" as a delimiter between revs and pathspec. * jk/eoo: gitcli: document --end-of-options parse-options: allow --end-of-options as a synonym for "--" revision: allow --end-of-options to end option parsing
2019-09-09Merge branch 'jk/repo-init-cleanup'Libravatar Junio C Hamano3-6/+11
Further clean-up of the initialization code. * jk/repo-init-cleanup: config: stop checking whether the_repository is NULL common-main: delay trace2 initialization t1309: use short branch name in includeIf.onbranch test
2019-09-09Merge branch 'py/git-gui-do-quit'Libravatar Junio C Hamano1-2/+17
"git gui" learned to call the clean-up procedure before exiting. * py/git-gui-do-quit: git-gui: call do_quit before destroying the main window
2019-09-05t3427: accelerate this test by using fast-export and fast-importLibravatar Elijah Newren1-1/+4
fast-export and fast-import can easily handle the simple rewrite that was being done by filter-branch, and should be faster on systems with a slow fork. Measuring the overall time taken for all of t3427 (not just the difference between filter-branch and fast-export/fast-import) shows a speedup of about 5% on Linux and 11% on Mac. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-09-03am: reload .gitattributes after patching itLibravatar brian m. carlson7-5/+141
When applying multiple patches with git am, or when rebasing using the am backend, it's possible that one of our patches has updated a gitattributes file. Currently, we cache this information, so if a file in a subsequent patch has attributes applied, the file will be written out with the attributes in place as of the time we started the rebase or am operation, not with the attributes applied by the previous patch. This problem does not occur when using the -m or -i flags to rebase. To ensure we write the correct data into the working tree, expire the cache after each patch that touches a path ending in ".gitattributes". Since we load these attributes in multiple separate files, we must expire them accordingly. Verify that both the am and rebase code paths work correctly, including the conflict marker size with am -3. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-08-29gitk: Make web links clickableLibravatar Paul Mackerras1-1/+50
This makes gitk look for http or https URLs in the commit description and make the URLs clickable. Clicking on them will invoke an external web browser with the URL. The web browser command is by default "xdg-open" on Linux, "open" on MacOS, and "cmd /c start" on Windows. The command can be changed in the preferences window, and it can include parameters as well as the command name. If it is set to the empty string then URLs will no longer be made clickable. Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
2019-08-29git-gui: allow undoing last revertLibravatar Pratyush Yadav2-5/+66
Accidental clicks on the revert hunk/lines buttons can cause loss of work, and can be frustrating. So, allow undoing the last revert. Right now, a stack or deque are not being used for the sake of simplicity, so only one undo is possible. Any reverts before the previous one are lost. Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>
2019-08-26path: add a function to check for path suffixLibravatar brian m. carlson2-9/+33
We have a function to strip the path suffix from a commit, but we don't have one to check for a path suffix. For a plain filename, we can use basename, but that requires an allocation, since POSIX allows it to modify its argument. Refactor strip_path_suffix into a helper function and a new function, ends_with_path_components, to meet this need. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-08-26git-gui: return early when patch fails to applyLibravatar Pratyush Yadav1-0/+2
In the procedure apply_or_revert_range_or_line, if the patch does not apply successfully, a dialog is shown, but execution proceeds after that. Instead, return early on error so the parts that come after this don't work on top of an error state. Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>