1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-06-03 08:46:11 +02:00
Commit Graph

63792 Commits

Author SHA1 Message Date
Daniel Santos ffbb3ee955 l10n: pt_PT: update translation tables
* update translation tables

Signed-off-by: Daniel Santos <hello@brighterdan.com>
2021-08-10 19:32:01 +01:00
Daniel Santos d0c637e6b9 l10n: pt_PT: translated git v2.33.0
* translated new entries of git v2.33.0

Signed-off-by: Daniel Santos <hello@brighterdan.com>
2021-08-10 19:31:49 +01:00
Jonathan Nieder 6a38e33331 Revert 'diff-merges: let "-m" imply "-p"'
This reverts commit f5bfcc823b, which
made "git log -m" imply "--patch" by default.  The logic was that
"-m", which makes diff generation for merges perform a diff against
each parent, has no use unless I am viewing the diff, so we could save
the user some typing by turning on display of the resulting diff
automatically.  That wasn't expected to adversely affect scripts
because scripts would either be using a command like "git diff-tree"
that already emits diffs by default or would be combining -m with a
diff generation option such as --name-status.  By saving typing for
interactive use without adversely affecting scripts in the wild, it
would be a pure improvement.

The problem is that although diff generation options are only relevant
for the displayed diff, a script author can imagine them affecting
path limiting.  For example, I might run

	git log -w --format=%H -- README

hoping to list commits that edited README, excluding whitespace-only
changes.  In fact, a whitespace-only change is not TREESAME so the use
of -w here has no effect (since we don't apply these diff generation
flags to the diff_options struct rev_info::pruning used for this
purpose), but the documentation suggests that it should work

	Suppose you specified foo as the <paths>. We shall call
	commits that modify foo !TREESAME, and the rest TREESAME. (In
	a diff filtered for foo, they look different and equal,
	respectively.)

and a script author who has not tested whitespace-only changes
wouldn't notice.

Similarly, a script author could include

	git log -m --first-parent --format=%H -- README

to filter the first-parent history for commits that modified README.
The -m is a no-op but it reflects the script author's intent.  For
example, until 1e20a407fe (stash list: stop passing "-m" to "git
log", 2021-05-21), "git stash list" did this.

As a result, we can't safely change "-m" to imply "-p" without fear of
breaking such scripts.  Restore the previous behavior.

Noticed because Rust's src/bootstrap/bootstrap.py made use of this
same construct: https://github.com/rust-lang/rust/pull/87513.  That
script has been updated to omit the unnecessary "-m" option, but we
can expect other scripts in the wild to have similar expectations.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-09 13:52:01 -07:00
Peter Krefting 9d66d5eae4 l10n: sv.po: Update Swedish translation (5227t0f0u)
Signed-off-by: Peter Krefting <peter@softwolves.pp.se>
2021-08-09 20:38:56 +01:00
Carlo Marcelo Arenas Belón dd3c8a72a2 object-store: avoid extra ';' from KHASH_INIT
cf2dc1c238 (speed up alt_odb_usable() with many alternates, 2021-07-07)
introduces a KHASH_INIT invocation with a trailing ';', which while
commonly expected will trigger warnings with pedantic on both
clang[-Wextra-semi] and gcc[-Wpedantic], because that macro has already
a semicolon and is meant to be invoked without one.

while fixing the macro would be a worthy solution (specially considering
this is a common recurring problem), remove the extra ';' for now to
minimize churn.

Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-09 09:01:30 -07:00
Carlo Marcelo Arenas Belón 14825944d7 oidtree: avoid nested struct oidtree_node
92d8ed8ac1 (oidtree: a crit-bit tree for odb_loose_cache, 2021-07-07)
adds a struct oidtree_node that contains only an n field with a
struct cb_node.

unfortunately, while building in pedantic mode witch clang 12 (as well
as a similar error from gcc 11) it will show:

  oidtree.c:11:17: error: 'n' may not be nested in a struct due to flexible array member [-Werror,-Wflexible-array-extensions]
          struct cb_node n;
                         ^

because of a constrain coded in ISO C 11 6.7.2.1¶3 that forbids using
structs that contain a flexible array as part of another struct.

use a strict cb_node directly instead.

Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-09 09:01:30 -07:00
Tran Ngoc Quan e84f865118 l10n: vi.po(5227t): Updated Vietnamese translation for v2.32.0
Signed-off-by: Tran Ngoc Quan <vnwildman@gmail.com>
2021-08-09 07:58:57 +07:00
Junio C Hamano 2d755dfac9 Git 2.33-rc1
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-06 12:53:06 -07:00
Junio C Hamano aa7d2fe355 Merge branch 'cb/t7508-regexp-fix'
* cb/t7508-regexp-fix:
  t7508: avoid non POSIX BRE
2021-08-06 12:52:22 -07:00
Junio C Hamano 55194925e6 Merge branch 'ab/pickaxe-pcre2'
* ab/pickaxe-pcre2:
  diff: --pickaxe-all typofix
2021-08-06 12:52:15 -07:00
Junio C Hamano c87977a0c5 Merge branch 'fc/disable-checkwinsize'
* fc/disable-checkwinsize:
  test: fix for COLUMNS and bash 5
2021-08-06 12:50:26 -07:00
Felipe Contreras 390b44eb2b test: fix for COLUMNS and bash 5
Since c49a177bec (test-lib.sh: set COLUMNS=80 for --verbose
repeatability, 2021-06-29) multiple tests have been failing when using
bash 5 because checkwinsize is enabled by default, therefore COLUMNS is
reset using TIOCGWINSZ even for non-interactive shells.

It's debatable whether or not bash should even be doing that, but for
now we can avoid this undesirable behavior by disabling this option.

Reported-by: Fabian Stelzer <fabian.stelzer@campoint.net>
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
[jc: with SZEDER Gábor's suggestion to do this before setting COLUMNS]
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-06 09:59:55 -07:00
Alexander Shopov 12515dc49e l10n: bg.po: Updated Bulgarian translation (5227t)
Signed-off-by: Alexander Shopov <ash@kambanaria.org>
2021-08-06 13:40:56 +03:00
Jiang Xin 5fee9b925e Merge branch 'po-id' of github.com:bagasme/git-po
* 'po-id' of github.com:bagasme/git-po:
  l10n: id: po-id for 2.33.0 (round 1)
2021-08-06 08:00:45 +08:00
Daniel Santos 01758866ba l10n: pt_PT: update git-po-helper
Signed-off-by: Daniel Santos <hello@brighterdan.com>
2021-08-05 14:05:11 +01:00
Daniel Santos cece123d71 l10n: pt_PT: remove trailing comments
* removed all unecessary trailing file comments

Signed-off-by: Daniel Santos <hello@brighterdan.com>
2021-08-05 14:05:11 +01:00
Daniel Santos 2a68d66127 l10n: pt_PT: translation tables
* filled translation table
 * add other translation table helper

Signed-off-by: Daniel Santos <hello@brighterdan.com>
2021-08-05 14:05:04 +01:00
Bagas Sanjaya 310dc40996 l10n: id: po-id for 2.33.0 (round 1)
Translate following new components:
  * builtin/show-branch.c
  * builtin/show-index.c
  * builtin/show-ref.c
  * builtin/shortlog.c
  * builtin/describe.c
  * bisect.c
  * builtin/bisect--helper.c
  * blame.c
  * builtin/blame.c
  * grep.c
  * builtin/grep.c
  * builtin/diff-tree.c
  * builtin/diff.c
  * help.c

Update translation for following components:
  * diff.c
  * builtin/clone.c
  * builtin/fetch.c

Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com>
2021-08-05 18:08:57 +07:00
Jiang Xin fac4caefa7 Merge branch 'tr-loc-v2.33' of github.com:bitigchi/git-po
* 'tr-loc-v2.33' of github.com:bitigchi/git-po:
  l10n: tr: v2.33.0 round 1
2021-08-05 12:56:29 +08:00
Emir Sarı 87c67efc0c l10n: tr: v2.33.0 round 1
Signed-off-by: Emir Sarı <bitigchi@me.com>
2021-08-05 07:45:52 +03:00
Jiang Xin 518bb518d1 Merge branch 'fr_v2.33_rnd1' of github.com:jnavila/git
* 'fr_v2.33_rnd1' of github.com:jnavila/git:
  l10n: fr.po v2.33 rnd 1
  l10n: fr: fix typo
2021-08-05 08:36:31 +08:00
Junio C Hamano e5a14ddd2d The eighth batch
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-04 13:28:56 -07:00
Junio C Hamano 099a64aa39 Merge branch 'tb/mingw-rmdir-symlink-to-directory'
Windows rmdir() equivalent behaves differently from POSIX ones in
that when used on a symbolic link that points at a directory, the
target directory gets removed, which has been corrected.

* tb/mingw-rmdir-symlink-to-directory:
  mingw: align symlinks-related rmdir() behavior with Linux
2021-08-04 13:28:56 -07:00
Junio C Hamano dfbbe8bd49 Merge branch 'ar/doc-markup-fix'
Doc mark-up fix.

* ar/doc-markup-fix:
  Documentation: render special characters correctly
2021-08-04 13:28:55 -07:00
Junio C Hamano fea3738ac5 Merge branch 'ab/getcwd-test'
Portability test update.

* ab/getcwd-test:
  t0001: fix broken not-quite getcwd(3) test in bed67874e2
2021-08-04 13:28:55 -07:00
Junio C Hamano 4dc964691f Merge branch 'rs/use-fspathhash'
Code simplification.

* rs/use-fspathhash:
  use fspathhash() everywhere
2021-08-04 13:28:54 -07:00
Junio C Hamano 5fef3b15db Merge branch 'pb/merge-autostash-more'
The local changes stashed by "git merge --autostash" were lost when
the merge failed in certain ways, which has been corrected.

* pb/merge-autostash-more:
  merge: apply autostash if merge strategy fails
  merge: apply autostash if fast-forward fails
  Documentation: define 'MERGE_AUTOSTASH'
  merge: add missing word "strategy" to a message
2021-08-04 13:28:54 -07:00
Junio C Hamano 1a6fb019d6 Merge branch 'en/ort-perf-batch-14'
Further optimization on "merge -sort" backend.

* en/ort-perf-batch-14:
  merge-ort: restart merge with cached renames to reduce process entry cost
  merge-ort: avoid recursing into directories when we don't need to
  merge-ort: defer recursing into directories when merge base is matched
  merge-ort: add a handle_deferred_entries() helper function
  merge-ort: add data structures for allowable trivial directory resolves
  merge-ort: add some more explanations in collect_merge_info_callback()
  merge-ort: resolve paths early when we have sufficient information
2021-08-04 13:28:54 -07:00
Junio C Hamano 506d2a354a Merge branch 'ds/commit-and-checkout-with-sparse-index'
"git checkout" and "git commit" learn to work without unnecessarily
expanding sparse indexes.

* ds/commit-and-checkout-with-sparse-index:
  unpack-trees: resolve sparse-directory/file conflicts
  t1092: document bad 'git checkout' behavior
  checkout: stop expanding sparse indexes
  sparse-index: recompute cache-tree
  commit: integrate with sparse-index
  p2000: compress repo names
  p2000: add 'git checkout -' test and decrease depth
2021-08-04 13:28:53 -07:00
Junio C Hamano 58705b4903 Merge branch 'ab/update-submitting-patches'
Reorganize and update the SubmitingPatches document.

* ab/update-submitting-patches:
  SubmittingPatches: replace discussion of Travis with GitHub Actions
  SubmittingPatches: move discussion of Signed-off-by above "send"
2021-08-04 13:28:53 -07:00
Junio C Hamano 31f9acf9ce Merge branch 'ah/plugleaks'
Leak plugging.

* ah/plugleaks:
  reset: clear_unpack_trees_porcelain to plug leak
  builtin/rebase: fix options.strategy memory lifecycle
  builtin/merge: free found_ref when done
  builtin/mv: free or UNLEAK multiple pointers at end of cmd_mv
  convert: release strbuf to avoid leak
  read-cache: call diff_setup_done to avoid leak
  ref-filter: also free head for ATOM_HEAD to avoid leak
  diffcore-rename: move old_dir/new_dir definition to plug leak
  builtin/for-each-repo: remove unnecessary argv copy to plug leak
  builtin/submodule--helper: release unused strbuf to avoid leak
  environment: move strbuf into block to plug leak
  fmt-merge-msg: free newly allocated temporary strings when done
2021-08-04 13:28:52 -07:00
Junio C Hamano 10f57e0eb9 Merge branch 'ar/submodule-add'
Rewrite of "git submodule" in C continues.

* ar/submodule-add:
  submodule: drop unused sm_name parameter from show_fetch_remotes()
  submodule--helper: introduce add-clone subcommand
  submodule--helper: refactor module_clone()
  submodule: prefix die messages with 'fatal'
  t7400: test failure to add submodule in tracked path
2021-08-04 13:28:52 -07:00
Bagas Sanjaya 11c649b891 diff: --pickaxe-all typofix
When I was fixing fuzzies as I updating po/id.po for 2.33.0 l10n round,
I noticed a triple-dash typo (--pickaxe-all) at diff.c, which according
to git-diff(1) manpage, the correct option name should be --pickaxe-all.

Fix the typo.

Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com>
Acked-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-04 10:34:47 -07:00
Jean-Noël Avila c131aab043 l10n: fr.po v2.33 rnd 1
Signed-off-by: Jean-Noël Avila <jn.avila@free.fr>
2021-08-03 22:13:07 +02:00
Jean-Noël Avila 98bdfc0c1b l10n: fr: fix typo
Reported-by: Andrei Rybak <rybak.a.v@gmail.com>
Signed-off-by: Jean-Noël Avila <jn.avila@free.fr>
2021-08-03 21:06:47 +02:00
Daniel Santos 8d2cca9754 l10n: pt_PT: add Portuguese translations part 5
* git-po-helper update

Signed-off-by: Daniel Santos <hello@brighterdan.com>
2021-08-03 13:20:18 +01:00
Daniel Santos ea00f105a7 l10n: pt_PT: add Portuguese translations part 4
* Fixed some typos
* Transformed 'não' (no) into affirmative
* Substituted 'excerto' to 'pedaço'

Signed-off-by: Daniel Santos <hello@brighterdan.com>
2021-08-03 13:20:15 +01:00
Jordi Mas 4ef987fab4 l10n: Update Catalan translation
Signed-off-by: Jordi Mas <jmas@softcatala.org>
2021-08-03 12:50:24 +02:00
Jiang Xin d4df71b2b0 l10n: git.pot: v2.33.0 round 1 (38 new, 15 removed)
Generate po/git.pot from v2.33.0-rc0 for git v2.33.0 l10n round 1.

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
2021-08-03 17:06:56 +08:00
Jiang Xin 972c9cf6ae Merge branch 'master' of github.com:git/git
* 'master' of github.com:git/git: (397 commits)
  Git 2.33-rc0
  The seventh batch
  ci/install-dependencies: handle "sparse" job package installs
  ci: run "apt-get update" before "apt-get install"
  cache-tree: prefetch in partial clone read-tree
  unpack-trees: refactor prefetching code
  pack-bitmap: check pack validity when opening bitmap
  bundle tests: use test_cmp instead of grep
  bundle tests: use ">file" not ": >file"
  The sixth batch
  doc: pull: fix rebase=false documentation
  pack-bitmap: clarify comment in filter_bitmap_exclude_type()
  doc: clarify description of 'submodule.recurse'
  doc/git-config: simplify "override" advice for FILES section
  doc/git-config: clarify GIT_CONFIG environment variable
  doc/git-config: explain --file instead of referring to GIT_CONFIG
  t0000: fix test if run with TEST_OUTPUT_DIRECTORY
  multi-pack-index: fix potential segfault without sub-command
  refs/debug: quote prefix
  t0000: clear GIT_SKIP_TESTS before running sub-tests
  ...
2021-08-03 17:03:35 +08:00
Thomas Bétous 3e7d4888e5 mingw: align symlinks-related rmdir() behavior with Linux
When performing a rebase, rmdir() is called on the folder .git/logs. On
Unix rmdir() exits without deleting anything in case .git/logs is a
symbolic link but the equivalent functions on Windows (_rmdir, _wrmdir
and RemoveDirectoryW) do not behave the same and remove the folder if it
is symlinked even if it is not empty.

This creates issues when folders in .git/ are symlinks which is
especially the case when git-repo[1] is used: It replaces `.git/logs/`
with a symlink.

One such issue is that the _target_ of that symlink is removed e.g.
during a `git rebase`, where `delete_reflog("REBASE_HEAD")` will not
only try to remove `.git/logs/REBASE_HEAD` but then recursively try to
remove the parent directories until an error occurs, a technique that
obviously relies on `rmdir()` refusing to remove a symlink.

This was reported in https://github.com/git-for-windows/git/issues/2967.

This commit updates mingw_rmdir() so that its behavior is the same as
Linux rmdir() in case of symbolic links.

To verify that Git does not regress on the reported issue, this patch
adds a regression test for the `git rebase` symptom, even if the same
`rmdir()` behavior is quite likely to cause potential problems in other
Git commands as well.

[1]: git-repo is a python tool built on top of Git which helps manage
many Git repositories. It stores all the .git/ folders in a central
place by taking advantage of symbolic links.
More information: https://gerrit.googlesource.com/git-repo/

Signed-off-by: Thomas Bétous <tomspycell@gmail.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-02 15:10:58 -07:00
Carlo Marcelo Arenas Belón 4da8b2fcd4 t7508: avoid non POSIX BRE
24c30e0b6 (wt-status: tolerate dangling marks, 2020-09-01) adds a test
that uses a BRE which breaks at least with OpenBSD's grep.

switch to an ERE as it is done for similar checks and while at it, remove
the now obsolete test_i18ngrep call.

Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-02 15:05:23 -07:00
Junio C Hamano 66262451ec Git 2.33-rc0
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-08-02 14:06:43 -07:00
Junio C Hamano 9bcdaab13e Merge branch 'jk/check-pack-valid-before-opening-bitmap'
A race between repacking and using pack bitmaps has been corrected.

* jk/check-pack-valid-before-opening-bitmap:
  pack-bitmap: check pack validity when opening bitmap
2021-08-02 14:06:43 -07:00
Junio C Hamano 8230107f33 Merge branch 'jt/bulk-prefetch'
"git read-tree" had a codepath where blobs are fetched one-by-one
from the promisor remote, which has been corrected to fetch in bulk.

* jt/bulk-prefetch:
  cache-tree: prefetch in partial clone read-tree
  unpack-trees: refactor prefetching code
2021-08-02 14:06:42 -07:00
Junio C Hamano e9fe413fc2 Merge branch 'fc/pull-no-rebase-merges-theirs-into-ours'
Documentation fix for "git pull --rebase=no".

* fc/pull-no-rebase-merges-theirs-into-ours:
  doc: pull: fix rebase=false documentation
2021-08-02 14:06:42 -07:00
Junio C Hamano 107687b5af Merge branch 'ab/bundle-tests'
"git bundle" gained more test coverage.

* ab/bundle-tests:
  bundle tests: use test_cmp instead of grep
  bundle tests: use ">file" not ": >file"
2021-08-02 14:06:41 -07:00
Junio C Hamano e163f73b7b Merge branch 'ps/perf-with-separate-output-directory'
Test update.

* ps/perf-with-separate-output-directory:
  perf: fix when running with TEST_OUTPUT_DIRECTORY
2021-08-02 14:06:41 -07:00
Junio C Hamano 8a49dfacd6 Merge branch 'js/ci-check-whitespace-updates'
CI update.

* js/ci-check-whitespace-updates:
  ci(check-whitespace): restrict to the intended commits
  ci(check-whitespace): stop requiring a read/write token
2021-08-02 14:06:40 -07:00
Junio C Hamano 5a9b455146 Merge branch 'jk/config-env-doc'
Documentation around GIT_CONFIG has been updated.

* jk/config-env-doc:
  doc/git-config: simplify "override" advice for FILES section
  doc/git-config: clarify GIT_CONFIG environment variable
  doc/git-config: explain --file instead of referring to GIT_CONFIG
2021-08-02 14:06:40 -07:00