summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2019-05-08perf-lib.sh: remove GIT_TEST_INSTALLED from perf-lib.shLibravatar Ævar Arnfjörð Bjarmason3-32/+38
Follow-up my preceding change which fixed the immediate "./run <revisions>" regression in 0baf78e7bc ("perf-lib.sh: rely on test-lib.sh for --tee handling", 2019-03-15) and entirely get rid of GIT_TEST_INSTALLED from perf-lib.sh (and aggregate.perl). As noted in that change the dance we're doing with GIT_TEST_INSTALLED perf-lib.sh isn't necessary, but there I was doing the most minimal set of changes to quickly fix a regression. But it's much simpler to never deal with the "GIT_TEST_INSTALLED" we were setting in perf-lib.sh at all. Instead the run_dirs_helper() sets the previously inferred $PERF_RESULTS_PREFIX directly. Setting this at the callsite that's already best positioned to exhaustively know about all the different cases we need to handle where PERF_RESULTS_PREFIX isn't what we want already (the empty string) makes the most sense. In one-off cases like: ./run ./p0000-perf-lib-sanity.sh ./p0000-perf-lib-sanity.sh We'll just do the right thing because PERF_RESULTS_PREFIX will be empty, and test-lib.sh takes care of finding where our git is. Any refactoring of this code needs to change both the shell code and the Perl code in aggregate.perl, because when running e.g.: ./run ../../ -- <test> The "../../" path to a relative bindir needs to be munged to a filename containing the results, and critically aggregate.perl does not get passed the path to those aggregations, just "../..". Let's fix cases where aggregate.perl would print e.g. ".." in its report output for this, and "git" for "/home/avar/g/git", i.e. it would always pick the last element. Now'll always print the full path instead. This also makes the code sturdier, e.g. you can feed "../.." to "./run" and then an absolute path to the aggregate.perl script, as long as the absolute path and "../.." resolved to the same directory printing the aggregation will work. Also simplify the "[_*]" on the RHS of "tr -c", we're trimming everything to "_", so we don't need that. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
2019-05-08perf-lib.sh: make "./run <revisions>" use the correct gitsLibravatar Ævar Arnfjörð Bjarmason2-2/+10
Fix a really bad regression in 0baf78e7bc ("perf-lib.sh: rely on test-lib.sh for --tee handling", 2019-03-15). Since that change all runs of different <revisions> of git have used the git found in the user's $PATH, e.g. /usr/bin/git instead of the <revision> we just built and wanted to performance test. The problem starts with GIT_TEST_INSTALLED not working like our non-perf tests with the "run" script. I.e. you can't run performance tests against a given installed git. Instead we expect to use it ourselves to point GIT_TEST_INSTALLED to the <revision> we just built. However, we had been relying on '$(cd "$GIT_TEST_INSTALLED" && pwd)' to resolve that relative $GIT_TEST_INSTALLED to an absolute path *before* test-lib.sh was loaded, in cases where it was e.g. "build/<rev>/bin-wrappers" and we wanted "<abs_path>build/...". This change post-dates another proposed solution by a few days[1], I didn't notice that version when I initially wrote this. I'm doing the most minimal thing to solve the regression here, a follow-up change will move this result prefix selection logic entirely into the "run" script. This makes e.g. these cases all work: ./run . $PWD/../../ origin/master origin/next HEAD -- <tests> As well as just a plain one-off: ./run <tests> And, since we're passing down the new GIT_PERF_DIR_MYDIR_REL we make sure the bug relating to aggregate.perl not finding our files as described in 0baf78e7bc doesn't happen again. What *doesn't* work is setting GIT_TEST_INSTALLED to a relative path, this will subtly fail in test-lib.sh. This has always been the case even before 0baf78e7bc, and as documented in t/README the GIT_TEST_INSTALLED variable should be set to an absolute path (needs to be set "to the bindir", which is always absolute), and the "perf" framework expects to munge it itself. Perhaps that should be dealt with in the future to allow manually setting GIT_TEST_INSTALLED, but as a preceding commit showed the user can just use the "run" script, which'll also pick the right output directory for the test results as expected by aggregate.perl. 1. https://public-inbox.org/git/20190502222409.GA15631@sigill.intra.peff.net/ Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
2019-05-08perf aggregate: remove GIT_TEST_INSTALLED from --codespeedLibravatar Ævar Arnfjörð Bjarmason1-3/+0
Remove the setting of the "environment" from the --codespeed output. I don't think this is useful, and it helps with a later refactoring where we GIT_TEST_INSTALLED stop munging/reading GIT_TEST_INSTALLED in the perf tests in so many places. This was added in 05eb1c37ed ("perf/aggregate: implement codespeed JSON output", 2018-01-05), but since the "run" scripts uses "GIT_TEST_INSTALLED" internally this was only ever useful for one-off runs of a single revision as all the "environment" values would be ones for whatever directory the "run" script ran last. Let's instead fall back on the "uname -r" case, which is the sort of thing the environment should be set to, not something that duplicates other parts of the codpseed output. For setting the "environment" to something custom the perf.repoName variable can be used. See 19cf57a92e ("perf/run: read GIT_PERF_REPO_NAME from perf.repoName", 2018-01-05). Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
2019-05-08perf README: correct docs for 3c8f12c96c regressionLibravatar Ævar Arnfjörð Bjarmason1-1/+1
Since 3c8f12c96c ("test-lib: reorder and include GIT-BUILD-OPTIONS a lot earlier", 2012-06-24) the suggested advice of overriding GIT_BUILD_DIR has not worked. We've printed a hard error like this given e.g. GIT_BUILD_DIR=/home/avar/g/git: /bin-wrappers/git is not executable; using GIT_EXEC_PATH error: You haven't built things yet, have you? Let's just suggest that the user run other gits via the "run" script. That'll do the right thing for setting the path to the other git, and running the "aggregate.perl" scripts afterwards will work. As an aside, if setting GIT_BUILD_DIR had still worked, then the MODERN_GIT feature/fix added in 1a0962dee5 ("t/perf: fix regression in testing older versions of git", 2016-06-22) would have broke. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
2019-03-18perf-lib.sh: rely on test-lib.sh for --tee handlingLibravatar Jeff King1-23/+11
Since its inception, the perf-lib.sh script has manually handled the "--tee" option (and other options which imply it, like "--valgrind") with a cut-and-pasted block from test-lib.sh. That block has grown stale over the years, and has at least three problems: 1. It uses $SHELL to re-exec the script, whereas the version in test-lib.sh learned to use $TEST_SHELL_PATH. 2. It does an ad-hoc search of the "$*" string, whereas test-lib.sh learned to carefully parse the arguments left to right. 3. It never learned about --verbose-log (which also implies --tee), so it would not trigger for that option. This last one was especially annoying, because t/perf/run uses the GIT_TEST_OPTS from your config.mak to run the perf scripts. So if you've set, say, "-x --verbose-log" there, it will be passed as part of most perf runs. And while this script doesn't recognize the option, the test-lib.sh that we source _does_, and the behavior ends up being much more annoying: - as the comment at the top of the block says, we have to run this tee code early, before we start munging variables (it says GIT_BUILD_DIR, but the problematic variable is actually GIT_TEST_INSTALLED). - since we don't recognize --verbose-log, we don't trigger the block. We go on to munge GIT_TEST_INSTALLED, converting it from a relative to an absolute path. - then we source test-lib.sh, which _does_ recognize --verbose-log. It re-execs the script, which runs again. But this time with an absolute version of GIT_TEST_INSTALLED. - As a result, we copy the absolute version of GIT_TEST_INSTALLED into perf_results_prefix. Instead of writing our results to the expected "test-results/build_1234abcd.p1234-whatever.times", we instead write them to "test-results/_full_path_to_repo_t_perf_build_1234...". The aggregate.perl script doesn't expect this, and so it prints "<missing>" for each result (even though it spent considerable time running the tests!). We can solve all of these in one blow by just deleting our custom handling, and relying on the inclusion of test-lib.sh to handle --tee, --verbose-log, etc. There's one catch, though. We want to handle GIT_TEST_INSTALLED after we've included test-lib.sh, since we want it un-munged in the re-exec'd version of the script. But if we want to convert it from a relative to an absolute path, we must do so before we load test-lib.sh, since it will change our working directory. So we compute the absolute directory first, store it away, then include test-lib.sh, and finally assign to GIT_TEST_INSTALLED as appropriate. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-18Merge git://ozlabs.org/~paulus/gitkLibravatar Junio C Hamano1-317/+343
* git://ozlabs.org/~paulus/gitk: gitk: Update Bulgarian translation (317t)
2019-03-14gitk: Update Bulgarian translation (317t)Libravatar Alexander Shopov1-317/+343
Signed-off-by: Alexander Shopov <ash@kambanaria.org> Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
2019-03-11The second batchLibravatar Junio C Hamano1-0/+22
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-11Sync with maintLibravatar Junio C Hamano1-1/+1
* maint: mingw: allow building with an MSYS2 runtime v3.x
2019-03-11Merge branch 'js/rebase-recreate-merge'Libravatar Junio C Hamano1-1/+1
Docfix. * js/rebase-recreate-merge: rebase docs: fix "gitlink" typo
2019-03-11Merge branch 'js/untravis-windows'Libravatar Junio C Hamano2-113/+0
Dev support. * js/untravis-windows: travis: remove the hack to build the Windows job on Azure Pipelines
2019-03-11Merge branch 'rd/gc-prune-doc-fix'Libravatar Junio C Hamano1-1/+1
Doxfix. * rd/gc-prune-doc-fix: docs/git-gc: fix typo "--prune=all" to "--prune=now"
2019-03-11Merge branch 'js/find-lib-h-with-ls-files-when-possible'Libravatar Junio C Hamano1-2/+3
The Makefile uses 'find' utility to enumerate all the *.h header files, which is expensive on platforms with slow filesystems; it now optionally uses "ls-files" if working within a repository, which is a trick similar to how all sources are enumerated to run ETAGS on. * js/find-lib-h-with-ls-files-when-possible: Makefile: use `git ls-files` to list header files, if possible
2019-03-11Merge branch 'rj/hdr-check-gcrypt-fix'Libravatar Junio C Hamano1-1/+4
The set of header files used by "make hdr-check" unconditionally included sha256/gcrypt.h, even when it is not used, causing the make target to fail. We now skip it when GCRYPT_SHA256 is not in use. * rj/hdr-check-gcrypt-fix: Makefile: fix 'hdr-check' when GCRYPT not installed
2019-03-11Merge branch 'jk/guard-bswap-header'Libravatar Junio C Hamano1-0/+5
The include file compat/bswap.h has been updated so that it is safe to (accidentally) include it more than once. * jk/guard-bswap-header: compat/bswap: add include header guards
2019-03-11Merge branch 'rd/attr.c-comment-typofix'Libravatar Junio C Hamano1-4/+4
In-code comment typofix. * rd/attr.c-comment-typofix: attr.c: ".gitattribute" -> ".gitattributes" (comments)
2019-03-11Merge branch 'yb/utf-16le-bom-spellfix'Libravatar Junio C Hamano1-1/+1
Doc update. * yb/utf-16le-bom-spellfix: gitattributes.txt: fix typo
2019-03-11mingw: allow building with an MSYS2 runtime v3.xLibravatar Johannes Schindelin1-1/+1
Recently the Git for Windows project started the upgrade process to a MSYS2 runtime version based on Cygwin v3.x. This has the very notable consequence that `$(uname -r)` no longer reports a version starting with "2", but a version with "3". That breaks our build, as df5218b4c30b (config.mak.uname: support MSys2, 2016-01-13) simply did not expect the version reported by `uname -r` to depend on the underlying Cygwin version: it expected the reported version to match the "2" in "MSYS2". So let's invert that test case to test for *anything else* than a version starting with "1" (for MSys). That should safeguard us for the future, even if Cygwin ends up releasing versionsl like 314.272.65536. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-08mingw: drop MakeMaker referenceLibravatar Johannes Schindelin1-1/+0
In 20d2a30f8ffe (Makefile: replace perl/Makefile.PL with simple make rules, 2017-12-10), Git stopped using MakeMaker. Therefore, that definition in the MINGW-specific section became useless. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Reviewed-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-07Start 2.22 cycleLibravatar Junio C Hamano3-2/+81
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-07Merge branch 'jt/http-auth-proto-v2-fix'Libravatar Junio C Hamano4-207/+213
Unify RPC code for smart http in protocol v0/v1 and v2, which fixes a bug in the latter (lack of authentication retry) and generally improves the code base. * jt/http-auth-proto-v2-fix: remote-curl: use post_rpc() for protocol v2 also remote-curl: refactor reading into rpc_state's buf remote-curl: reduce scope of rpc_state.result remote-curl: reduce scope of rpc_state.stdin_preamble remote-curl: reduce scope of rpc_state.argv
2019-03-07Merge branch 'jk/diff-no-index-initialize'Libravatar Junio C Hamano4-17/+21
"git diff --no-index" may still want to access Git goodies like --ext-diff and --textconv, but so far these have been ignored, which has been corrected. * jk/diff-no-index-initialize: diff: reuse diff setup for --no-index case
2019-03-07Merge branch 'nd/no-more-check-racy'Libravatar Junio C Hamano1-28/+0
Unused code removal. * nd/no-more-check-racy: Delete check-racy.c
2019-03-07Merge branch 'rd/doc-hook-used-in-sample'Libravatar Junio C Hamano1-0/+4
Doc update. * rd/doc-hook-used-in-sample: mention use of "hooks.allownonascii" in "man githooks"
2019-03-07Merge branch 'nd/diff-parseopt-2'Libravatar Junio C Hamano2-211/+319
Second batch to teach the diff machinery to use the parse-options API. * nd/diff-parseopt-2: (21 commits) diff-parseopt: convert --ignore-some-changes diff-parseopt: convert --[no-]minimal diff-parseopt: convert --relative diff-parseopt: convert --no-renames|--[no--rename-empty diff-parseopt: convert --find-copies-harder diff-parseopt: convert -C|--find-copies diff-parseopt: convert -D|--irreversible-delete diff-parseopt: convert -M|--find-renames diff-parseopt: convert -B|--break-rewrites diff-parseopt: convert --output-* diff-parseopt: convert --[no-]compact-summary diff-parseopt: convert --stat* diff-parseopt: convert -s|--no-patch diff-parseopt: convert --name-status diff-parseopt: convert --name-only diff-parseopt: convert --patch-with-stat diff-parseopt: convert --summary diff-parseopt: convert --check diff-parseopt: convert --dirstat and friends diff-parseopt: convert --numstat and --shortstat ...
2019-03-07Merge branch 'en/merge-options-doc'Libravatar Junio C Hamano1-3/+8
Doc update. * en/merge-options-doc: merge-options.txt: correct wording of --no-commit option
2019-03-07Merge branch 'nd/completion-more-parameters'Libravatar Junio C Hamano18-4/+126
The command line completion (in contrib/) has been taught to complete more subcommand parameters. * nd/completion-more-parameters: completion: add more parameter value completion
2019-03-07Merge branch 'ab/receive-pack-use-after-free-fix'Libravatar Junio C Hamano1-8/+15
Memfix. * ab/receive-pack-use-after-free-fix: receive-pack: fix use-after-free bug
2019-03-07Merge branch 'dl/doc-submodule-wo-subcommand'Libravatar Junio C Hamano2-1/+6
Doc update. * dl/doc-submodule-wo-subcommand: submodule: document default behavior
2019-03-07Merge branch 'jk/unused-params'Libravatar Junio C Hamano8-59/+45
Code clean-up. * jk/unused-params: ref-filter: drop unused "sz" parameters ref-filter: drop unused "obj" parameters ref-filter: drop unused buf/sz pairs files-backend: drop refs parameter from split_symref_update() pack-objects: drop unused parameter from oe_map_new_pack() merge-recursive: drop several unused parameters diff: drop complete_rewrite parameter from run_external_diff() diff: drop unused emit data parameter from sane_truncate_line() diff: drop unused color reset parameters diff: drop options parameter from diffcore_fix_diff_index()
2019-03-07Merge branch 'jk/prune-optim'Libravatar Junio C Hamano4-20/+129
"git prune" has been taught to take advantage of reachability bitmap when able. * jk/prune-optim: t5304: rename "sha1" variables to "oid" prune: check SEEN flag for reachability prune: use bitmaps for reachability traversal prune: lazily perform reachability traversal
2019-03-07Merge branch 'jh/trace2'Libravatar Junio C Hamano67-23/+6629
A more structured way to obtain execution trace has been added. * jh/trace2: trace2: add for_each macros to clang-format trace2: t/helper/test-trace2, t0210.sh, t0211.sh, t0212.sh trace2:data: add subverb for rebase trace2:data: add subverb to reset command trace2:data: add subverb to checkout command trace2:data: pack-objects: add trace2 regions trace2:data: add trace2 instrumentation to index read/write trace2:data: add trace2 hook classification trace2:data: add trace2 transport child classification trace2:data: add trace2 sub-process classification trace2:data: add editor/pager child classification trace2:data: add trace2 regions to wt-status trace2: collect Windows-specific process information trace2: create new combined trace facility trace2: Documentation/technical/api-trace2.txt
2019-03-07Merge branch 'js/doc-symref-in-proto-v1'Libravatar Junio C Hamano1-0/+18
Doc update. * js/doc-symref-in-proto-v1: protocol-capabilities.txt: document symref
2019-03-07Merge branch 'nd/split-index-null-base-fix'Libravatar Junio C Hamano3-18/+39
Split-index fix. * nd/split-index-null-base-fix: read-cache.c: fix writing "link" index ext with null base oid
2019-03-07Merge branch 'rj/prune-packed-excess-args'Libravatar Junio C Hamano1-0/+5
"git prune-packed" did not notice and complain against excess arguments given from the command line, which now it does. * rj/prune-packed-excess-args: prune-packed: check for too many arguments
2019-03-07Merge branch 'jc/test-yes-doc'Libravatar Junio C Hamano2-1/+14
Test doc update. * jc/test-yes-doc: test: caution on our version of 'yes'
2019-03-07Merge branch 'en/combined-all-paths'Libravatar Junio C Hamano10-17/+212
Output from "diff --cc" did not show the original paths when the merge involved renames. A new option adds the paths in the original trees to the output. * en/combined-all-paths: log,diff-tree: add --combined-all-paths option
2019-03-07Merge branch 'sc/pack-redundant'Libravatar Junio C Hamano2-140/+559
Update the implementation of pack-redundant for performance in a repository with many packfiles. * sc/pack-redundant: pack-redundant: consistent sort method pack-redundant: rename pack_list.all_objects pack-redundant: new algorithm to find min packs pack-redundant: delete redundant code pack-redundant: delay creation of unique_objects t5323: test cases for git-pack-redundant
2019-03-07Merge branch 'du/branch-show-current'Libravatar Junio C Hamano3-3/+72
"git branch" learned a new subcommand "--show-current". * du/branch-show-current: branch: introduce --show-current display option
2019-03-07Merge branch 'dl/complete-submodule-absorbgitdirs'Libravatar Junio C Hamano1-1/+1
Command-line completion (in contrib/) learned to tab-complete the "git submodule absorbgitdirs" subcommand. * dl/complete-submodule-absorbgitdirs: completion: complete git submodule absorbgitdirs
2019-03-07Merge branch 'wh/author-committer-ident-config'Libravatar Junio C Hamano10-24/+197
Four new configuration variables {author,committer}.{name,email} have been introduced to override user.{name,email} in more specific cases. * wh/author-committer-ident-config: config: allow giving separate author and committer idents
2019-03-07Merge branch 'aw/pretty-trailers'Libravatar Junio C Hamano7-135/+417
The %(trailers) formatter in "git log --format=..." now allows to optionally pick trailers selectively by keyword, show only values, etc. * aw/pretty-trailers: pretty: add support for separator option in %(trailers) strbuf: separate callback for strbuf_expand:ing literals pretty: add support for "valueonly" option in %(trailers) pretty: allow showing specific trailers pretty: single return path in %(trailers) handling pretty: allow %(trailers) options with explicit value doc: group pretty-format.txt placeholders descriptions
2019-03-07Merge branch 'nd/diff-parseopt'Libravatar Junio C Hamano10-158/+318
The diff machinery, one of the oldest parts of the system, which long predates the parse-options API, uses fairly long and complex handcrafted option parser. This is being rewritten to use the parse-options API. * nd/diff-parseopt: diff.c: convert --raw diff.c: convert -W|--[no-]function-context diff.c: convert -U|--unified diff.c: convert -u|-p|--patch diff.c: prepare to use parse_options() for parsing diff.h: avoid bit fields in struct diff_flags diff.h: keep forward struct declarations sorted parse-options: allow ll_callback with OPTION_CALLBACK parse-options: avoid magic return codes parse-options: stop abusing 'callback' for lowlevel callbacks parse-options: add OPT_BITOP() parse-options: disable option abbreviation with PARSE_OPT_KEEP_UNKNOWN parse-options: add one-shot mode parse-options.h: remove extern on function prototypes
2019-03-07Merge branch 'tg/checkout-no-overlay'Libravatar Junio C Hamano14-58/+191
"git checkout --no-overlay" can be used to trigger a new mode of checking out paths out of the tree-ish, that allows paths that match the pathspec that are in the current index and working tree and are not in the tree-ish. * tg/checkout-no-overlay: revert "checkout: introduce checkout.overlayMode config" checkout: introduce checkout.overlayMode config checkout: introduce --{,no-}overlay option checkout: factor out mark_cache_entry_for_checkout function checkout: clarify comment read-cache: add invalidate parameter to remove_marked_cache_entries entry: support CE_WT_REMOVE flag in checkout_entry entry: factor out unlink_entry function move worktree tests to t24*
2019-03-07attr.c: ".gitattribute" -> ".gitattributes" (comments)Libravatar Robert P. J. Day1-4/+4
Correct misspelled ".gitattribute" in comments only, so no functional change. Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-07gitattributes.txt: fix typoLibravatar Yash Bhatambare1-1/+1
`UTF-16-LE-BOM` to `UTF-16LE-BOM`. this closes https://github.com/git-for-windows/git/issues/2095 Signed-off-by: Yash Bhatambare <ybhatambare@gmail.com> Signed-off-by: Torsten Bögershausen <tboegi@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-07compat/bswap: add include header guardsLibravatar Jeff King1-0/+5
Our compat/bswap.h lacks the usual preprocessor guards against multiple inclusion. This usually isn't an issue since it only gets included from git-compat-util.h, which has its own guards. But it would produce redeclaration errors if any file included it separately. Our hdr-check target would complain about this, except that it currently skips items in compat/ entirely. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-06Makefile: fix 'hdr-check' when GCRYPT not installedLibravatar Ramsay Jones1-1/+4
If the GCRYPT_SHA256 build variable is not set, then the 'hdr-check' target complains about the missing <gcrypt.h> header file. Add the 'sha256/gcrypt.h' header file to the exception list, if the build variable is not defined. While here, replace the 'xdiff%' filter pattern with 'xdiff/%' (and similarly for the compat pattern) since the original pattern inadvertently excluded the 'xdiff-interface.h' header. Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-05Makefile: use `git ls-files` to list header files, if possibleLibravatar Johannes Schindelin1-2/+3
In d85b0dff72 (Makefile: use `find` to determine static header dependencies, 2014-08-25), we switched from a static list of header files to a dynamically-generated one, asking `find` to enumerate them. Back in those days, we did not use `$(LIB_H)` by default, and many a `make` implementation seems smart enough not to run that `find` command in that case, so it was deemed okay to run `find` for special targets requiring this macro. However, as of ebb7baf02f (Makefile: add a hdr-check target, 2018-09-19), $(LIB_H) is part of a global rule and therefore must be expanded. Meaning: this `find` command has to be run upon every `make` invocation. In the presence of many a worktree, this can tax the developers' patience quite a bit. Even in the absence of worktrees or other untracked files and directories, the cost of I/O to generate that list of header files is simply a lot larger than a simple `git ls-files` call. Therefore, just like in 335339758c (Makefile: ask "ls-files" to list source files if available, 2011-10-18), we now prefer to use `git ls-files` to enumerate the header files to enumerating them via `find`, falling back to the latter if the former failed (which would be the case e.g. in a worktree that was extracted from a source .tar file rather than from a clone of Git's sources). This has one notable consequence: we no longer include `command-list.h` in `LIB_H`, as it is a generated file, not a tracked one, but that is easily worked around. Of the three sites that use `LIB_H`, two (`LOCALIZED_C` and `CHK_HDRS`) already handle generated headers separately. In the third, the computed-dependency fallback, we can just add in a reference to $(GENERATED_H). Likewise, we no longer include not-yet-tracked header files in `LIB_H`. Given the speed improvements, these consequences seem a comparably small price to pay. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Acked-by: Ramsay Jones <ramsay@ramsayjones.plus.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-05Merge tag 'l10n-2.21.0-rnd2.1' of git://github.com/git-l10n/git-poLibravatar Junio C Hamano3-4481/+3979
L10n for Git 2.21.0 round 2.1 * tag 'l10n-2.21.0-rnd2.1' of git://github.com/git-l10n/git-po: l10n: Fixes to Catalan translation l10n: Updated Vietnamese translation for v2.21 rd2 l10n: fr.po remove obsolete entries