aboutsummaryrefslogtreecommitdiffstats
path: root/builtin/commit.c
diff options
context:
space:
mode:
authorKevin Ballard <kevin@sb.org>2010-11-02 23:26:25 -0700
committerJunio C Hamano <gitster@pobox.com>2010-11-03 12:51:28 -0700
commit98dbe63dbcb44218e23ccc92e1491c36b2e31945 (patch)
tree406d5c2418aaa768e986c18f351888fcc168ab75 /builtin/commit.c
parentsubmodule: preserve all arguments exactly when recursing (diff)
downloadgit-98dbe63dbcb44218e23ccc92e1491c36b2e31945.tar.gz
git-98dbe63dbcb44218e23ccc92e1491c36b2e31945.zip
submodule: only preserve flags across recursive status/update invocations
Recursive invocations of submodule update/status preserve all arguments, so executing git submodule update --recursive -- foo attempts to recursively update a submodule named "foo". Naturally, this fails as one cannot have an infinitely-deep stack of submodules each containing a submodule named "foo". The desired behavior is instead to update foo and then recursively update all submodules inside of foo. This commit accomplishes that by only saving the flags for use in the recursive invocation. Signed-off-by: Kevin Ballard <kevin@sb.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit.c')
0 files changed, 0 insertions, 0 deletions
ix a couple of ambiguitiesEmir Sarı1-9/+9 Signed-off-by: Emir Sarı <bitigchi@me.com> 2020-03-18RelNotes/2.26.0: fix various typosElijah Newren1-4/+4 Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-18l10n: Update Catalan translationJordi Mas1-80/+71 Signed-off-by: Jordi Mas <jmas@softcatala.org> 2020-03-17Git 2.25.2v2.25.2Junio C Hamano3-2/+62 Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-17unicode: update the width tables to Unicode 13.0Beat Bolli1-16/+27 Now that Unicode 13.0 has been announced[0], update the character width tables to the new version. [0] https://home.unicode.org/announcing-the-unicode-standard-version-13-0/ Signed-off-by: Beat Bolli <dev+git@drbeat.li> Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-17l10n: sv.po: Update Swedish translation (4839t0f0u)Peter Krefting1-266/+296 Signed-off-by: Peter Krefting <peter@softwolves.pp.se> 2020-03-17git-gui: create a new namespace for chord script evaluationPratyush Yadav1-2/+4 Evaluating the script in the same namespace as the chord itself creates potential for variable name collision. And in that case the script would unknowingly use the chord's variables. For example, say the script has a variable called 'is_completed', which also exists in the chord's namespace. The script then calls 'eval' and sets 'is_completed' to 1 thinking it is setting its own variable, completely unaware of how the chord works behind the scenes. This leads to the chord never actually executing because it sees 'is_completed' as true and thinks it has already completed. Avoid the potential collision by creating a separate namespace for the script that is a child of the chord's namespace. Signed-off-by: Pratyush Yadav <me@yadavpratyush.com> 2020-03-17git-gui: reduce Tcl version requirement from 8.6 to 8.5Pratyush Yadav3-35/+33 On some MacOS distributions like High Sierra, Tcl 8.5 is shipped by default. This makes git-gui error out at startup because of the version mismatch. The only part that requires Tcl 8.6 is SimpleChord, which depends on TclOO. So, don't use it and use our homegrown class.tcl instead. This means some slight syntax changes. Since class.tcl doesn't have an "unknown" method like TclOO does, we can't just call '$note', but have to use '$note activate' instead. The constructor now needs a proper namespace qualifier. Update the documentation to reflect the new syntax. As of now, the only part of git-gui that needs Tcl 8.5 is a call to 'apply' in lib/index.tcl::lambda. Keep using it until someone shows up shouting that their OS ships with 8.4 only. Then we would have to look into implementing it in pure Tcl. Signed-off-by: Pratyush Yadav <me@yadavpratyush.com> 2020-03-17l10n: zh_CN: Revise v2.26.0 translationFangyi Zhou1-26/+26 Signed-off-by: Fangyi Zhou <me@fangyi.io> Reviewed-by: 依云 <lilydjwg@gmail.com> Signed-off-by: Jiang Xin <worldhello.net@gmail.com> 2020-03-17l10n: zh_CN: for git v2.26.0 l10n round 1 and 2Jiang Xin1-2541/+2844 Translate 79 new messages (4839t0f0u) for git 2.26.0. Signed-off-by: Jiang Xin <worldhello.net@gmail.com> 2020-03-16Git 2.26-rc2v2.26.0-rc2Junio C Hamano2-5/+4 Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-16l10n: vi(4839t): Updated Vietnamese translation for v2.26.0Tran Ngoc Quan1-2557/+2975 Signed-off-by: Tran Ngoc Quan <vnwildman@gmail.com> 2020-03-16l10n: vi: fix translation + grammarĐoàn Trần Công Danh1-14/+14 - context should be translated to ngữ cảnh instead of nội dung - add missing accents - switch adjective and secondary objects position: * The formatted English text will be "To remove '+/-' lines", it should be translated to "Để bỏ dòng bắt đầu với '+/-' Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com> 2020-03-15prefix_path: show gitdir if worktree unavailableEmily Shaffer3-4/+50 If there is no worktree at present, we can still hint the user about Git's current directory by showing them the absolute path to the Git directory. Even though the Git directory doesn't make it as easy to locate the worktree in question, it can still help a user figure out what's going on while developing a script. This fixes a segmentation fault introduced in e0020b2f ("prefix_path: show gitdir when arg is outside repo", 2020-02-14). Signed-off-by: Emily Shaffer <emilyshaffer@google.com> [jc: added minimum tests, with help from Szeder Gábor] Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-15l10n: zh_TW.po: v2.26.0 round 2 (0 untranslated)Yi-Jyun1-388/+289 Revision 2. Signed-off-by: Yi-Jyun Pan <pan93412@gmail.com> 2020-03-15l10n: zh_TW.po: v2.26.0 round 1 (11 untranslated)Yi-Jyun1-2604/+2823 Signed-off-by: Yi-Jyun Pan <pan93412@gmail.com> 2020-03-14git-gui--askpass: coerce answers to UTF-8 on WindowsLuke Bonanomi1-0/+5 This addresses the issue where Git for Windows asks the user for a password, no credential helper is available, and then Git fails to pick up non-ASCII characters from the Git GUI helper. This can be verified e.g. via echo host=http://abc.com | git -c credential.helper= credential fill and then pasting some umlauts. The underlying reason is that Git for Windows tries to communicate using the UTF-8 encoding no matter what the actual current code page is. So let's indulge Git for Windows and do use that encoding. This fixes https://github.com/git-for-windows/git/issues/2215 Signed-off-by: Luke Bonanomi <lbonanomi@gmail.com> Helped-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Pratyush Yadav <me@yadavpratyush.com> 2020-03-13t6022, t6046: fix flaky files-are-updated checksElijah Newren2-23/+17 Several tests wanted to verify that files were actually modified by a merge, which it would do by checking that the mtime was updated. In order to avoid problems with the merge completing so fast that the mtime at the beginning and end of the operation was the same, these tests would first set the mtime of a file to something "old". This "old" value was usually determined as current system clock minus one second, truncated to the nearest integer. Unfortunately, it appears the system clock and filesystem clock are different and comparing across the two runs into race problems resulting in flaky tests. From https://stackoverflow.com/questions/14392975/timestamp-accuracy-on-ext4-sub-millsecond: date will call the gettimeofday system call which will always return the most accurate time available based on the cached kernel time, adjusted by the CPU cycle time if available to give nanosecond resolution. The timestamps stored in the file system however, are only based on the cached kernel time. ie The time calculated at the last timer interrupt. and from https://apenwarr.ca/log/20181113: Does mtime get set to >= the current time? No, this depends on clock granularity. For example, gettimeofday() can return times in microseconds on my system, but ext4 rounds timestamps down to the previous ~10ms (but not exactly 10ms) increment, with the surprising result that a newly-created file is almost always created in the past: $ python -c " import os, time t0 = time.time() open('testfile', 'w').close() print os.stat('testfile').st_mtime - t0 " -0.00234484672546 So, instead of trying to compare across what are effectively two different clocks, just avoid using the system clock. Any new updates to files have to give an mtime at least as big as what is already in the file, so we could define "old" as one second before the mtime found in the file before the merge starts. But, to avoid problems with leap seconds, ntp updates, filesystems that only provide two second resolution, and other such weirdness, let's just pick an hour before the mtime found in the file before the merge starts. Also, clarify in one test where we check the mtime of different files that it really was intentional. I totally forgot the reasons for that and assumed it was a bug when asked. Reported-by: SZEDER Gábor <szeder.dev@gmail.com> Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-12Hopefully the final batch before -rc2Junio C Hamano1-0/+21 Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-12l10n: it.po: update the Italian translation for Git 2.26.0 round 2Alessandro Menti1-267/+297 Signed-off-by: Alessandro Menti <alessandro.menti@alessandromenti.it> 2020-03-11l10n: es: 2.26.0 round#2Christopher Diaz Riveros1-2550/+2979 Signed-off-by: Christopher Diaz Riveros <chrisadr@gentoo.org> 2020-03-12l10n: bg.po: Updated Bulgarian translation (4839t)Alexander Shopov1-242/+270 Signed-off-by: Alexander Shopov <ash@kambanaria.org> 2020-03-12l10n: tr: v2.26.0 round 2Emir Sarı1-262/+284 Signed-off-by: Emir Sarı <bitigchi@me.com> 2020-03-11l10n: fr : v2.26.0 rnd 2Jean-Noël Avila1-353/+308 Signed-off-by: Jean-Noël Avila <jn.avila@free.fr> 2020-03-11git-rebase.txt: highlight backend differences with commit rewordingElijah Newren1-0/+10 As noted by Junio: Back when "git am" was written, it was not considered a bug that the "git am --resolved" option did not offer the user a chance to update the log message to match the adjustment of the code the user made, but honestly, I'd have to say that it is a bug in "git am" in that over time it wasn't adjusted to the new world order where we encourage users to describe what they did when the automation hiccuped by opening an editor. These days, even when automation worked well (e.g. a clean auto-merge with "git merge"), we open an editor. The world has changed, and so should the expectations. Junio also suggested providing a workaround such as allowing --no-edit together with git rebase --continue, but that should probably be done in a patch after the git-2.26.0 release. For now, just document the known difference in the Behavioral Differences section. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-11sequencer: clear state upon dropping a become-empty commitElijah Newren2-0/+10 In commit e98c4269c8 ("rebase (interactive-backend): fix handling of commits that become empty", 2020-02-15), the merge backend was changed to drop commits that did not start empty but became so after being applied (because their changes were a subset of what was already upstream). This new code path did not need to go through the process of creating a commit, since we were dropping the commit instead. Unfortunately, this also means we bypassed the clearing of the CHERRY_PICK_HEAD and MERGE_MSG files, which if there were no further commits to cherry-pick would mean that the rebase would end but assume there was still an operation in progress. Ensure that we clear such state files when we decide to drop the commit. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-11i18n: unmark a message in rebase.cJiang Xin1-1/+1 Commit v2.25.0-4-ge98c4269c8 (rebase (interactive-backend): fix handling of commits that become empty, 2020-02-15) marked "{drop,keep,ask}" for translation, but this message should not be changed. Signed-off-by: Jiang Xin <worldhello.net@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com> 2020-03-11l10n: git.pot: v2.26.0 round 2 (7 new, 2 removed)Jiang Xin1-238/+260 Generate po/git.pot from v2.26.0-rc1 for git v2.26.0 l10n round 2. Signed-off-by: Jiang Xin <worldhello.net@gmail.com> 2020-03-10l10n: tr: Add glossary for Turkish translationsEmir Sarı1-4/+87 Signed-off-by: Emir Sarı <bitigchi@me.com> 2020-03-09l10n: sv.po: Update Swedish translation (4835t0f0u)Peter Krefting1-2379/+2764 Signed-off-by: Peter Krefting <peter@softwolves.pp.se>