Skip to content

Rebase shears/seen: 2 conflict(s) (1 skipped, 1 resolved) (#24528777880)#129

Open
gitforwindowshelper[bot] wants to merge 288 commits intobase/shears/seen-24528777880from
shears/seen-24528777880
Open

Rebase shears/seen: 2 conflict(s) (1 skipped, 1 resolved) (#24528777880)#129
gitforwindowshelper[bot] wants to merge 288 commits intobase/shears/seen-24528777880from
shears/seen-24528777880

Conversation

@gitforwindowshelper
Copy link
Copy Markdown

Workflow run

Rebase Summary: seen

From: afbccd0569 (Merge 'readme' into HEAD, 2018-06-07) (58d2d6e597..afbccd0569)

Resolved: d9afdd5 (t5563: verify that NTLM authentication works, 2025-11-26)

kept both upstream SPNEGO tests and downstream NTLM test, appended NTLM test after SPNEGO tests before test_done

Range-diff
  • 1: d9afdd5 ! 1: 14254d0 t5563: verify that NTLM authentication works

    @@ t/lib-httpd/ntlm-handshake.sh (new)
     +esac
     
      ## t/t5563-simple-http-auth.sh ##
    -@@ t/t5563-simple-http-auth.sh: test_expect_success 'access using three-legged auth' '
    - 	EOF
    +@@ t/t5563-simple-http-auth.sh: test_expect_success SPNEGO 'http.emptyAuth=false skips Negotiate' '
    + 	test_line_count = 1 actual_401s
      '
      
     +test_lazy_prereq NTLM 'curl --version | grep -q NTLM'

Skipped: 9302e44 (http: extract http_reauth_prepare() from retry paths, 2026-04-13)

Upstream equivalent: a8faa7a (http: extract http_reauth_prepare() from retry paths, 2026-04-16)

Range-diff
  • 1: 9302e44 ! 1: a8faa7a http: extract http_reauth_prepare() from retry paths

    @@ Commit message
         No functional change.
     
         Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
    +    Signed-off-by: Junio C Hamano <gitster@pobox.com>
     
      ## http.c ##
     @@ http.c: static void init_curl_http_auth(CURL *result)
    @@ http.c: static int http_request_recoverable(const char *url,
     +			http_reauth_prepare(1);
      		}
      
    - 		/*
    + 		ret = http_request(url, result, target, options);
     
      ## http.h ##
     @@ http.h: extern int http_is_verbose;

To: 97a84e1ce1 (Merge 'readme' into HEAD, 2018-06-07) (7c81b18259..97a84e1ce1)

Statistics

Metric Count
Total conflicts 2
Skipped (upstreamed) 1
Resolved surgically 1
Range-diff (click to expand)
  • 1: c4e5621 = 1: a094874 ci(dockerized): reduce the PID limit for private repositories

  • 2: 68f4466 = 2: dec17ab mingw: skip symlink type auto-detection for network share targets

  • 3: ce7e789 = 3: 9420d50 Merge branch 'fix-ci'

  • 4: 6f2a109 = 4: bbfe599 unix-socket: avoid leak when initialization fails

  • 5: 882df5c = 5: 251424f Merge branch 'prevent-accidental-ntlm-exfiltration-via-symlinks'

  • 6: 25f71f2 = 6: 513da8b grep: prevent ^$ false match at end of file

  • 7: 4b48fc6 = 7: 4d94409 Merge branch 'v2.53.0.windows.3'

  • 8: b525a1a = 8: b600850 Merge branch 'fixes-from-the-git-mailing-list'

  • 28: 63196fd = 9: 4506f23 vcpkg_install: detect lack of Git

  • 29: f7d7402 = 10: 8f0cf63 vcpkg_install: add comment regarding slow network connections

  • 30: 5e3fbf3 = 11: 804b5a3 vcbuild: install ARM64 dependencies when building ARM64 binaries

  • 9: 9c3de15 = 12: 343c46c mingw: include the Python parts in the build

  • 31: faf292e = 13: 2e352c8 vcbuild: add an option to install individual 'features'

  • 10: 94c98db = 14: 33d8171 win32/pthread: avoid name clashes with winpthread

  • 32: 3cb8bcc = 15: 06ca204 cmake: allow building for Windows/ARM64

  • 11: 37e6fff = 16: b546fc2 git-compat-util: avoid redeclaring _DEFAULT_SOURCE

  • 33: 4b8bfcb = 17: 4449cee ci(vs-build) also build Windows/ARM64 artifacts

  • 12: 9755b7d = 18: 6e971d2 Import the source code of mimalloc v2.2.7

  • 34: 830a9b1 = 19: f3b663c Add schannel to curl installation

  • 13: 6844e3a = 20: 76956f2 t9350: point out that refs are not updated correctly

  • 14: d04b93f = 21: dec14b7 mimalloc: adjust for building inside Git

  • 36: 9c9d8c3 = 22: cac6eed cmake(): allow setting HOST_CPU for cross-compilation

  • 15: f6b3118 = 23: ac096f8 transport-helper: add trailing --

  • 16: b6924be = 24: 46b9f3d mingw: demonstrate a git add issue with NTFS junctions

  • 17: 7497cb5 = 25: 9bce8cb mimalloc: offer a build-time option to enable it

  • 42: 0282aa6 = 26: 14c89ed t5505/t5516: allow running without .git/branches/ in the templates

  • 38: 3f92bad = 27: 2ef3544 CMake: default Visual Studio generator has changed

  • 18: f04c681 = 28: 6e86568 remote-helper: check helper status after import/export

  • 19: a1619a8 = 29: 79fbcf3 clean: do not traverse mount points

  • 20: 25482a5 = 30: a5f2afc strbuf_realpath(): use platform-dependent API if available

  • 43: a3f1bf6 = 31: 801408b http: use new "best effort" strategy for Secure Channel revoke checking

  • 44: 247dbbb = 32: ae03e57 subtree: update contrib/subtree test target

  • 21: 6f0c744 = 33: fc89356 mingw: use mimalloc

  • 49: 4c6e2c0 = 34: 3dc3f57 t5505/t5516: fix white-space around redirectors

  • 40: 0dec0ac = 35: bbb86fb .gitignore: add Visual Studio CMakeSetting.json file

  • 22: 252aa69 = 36: 96a0db3 Always auto-gc after calling a fast-import transport

  • 23: 426bc6a = 37: 09e7e5b mingw: prevent regressions with "drive-less" absolute paths

  • 24: 8e9f2fa = 38: 1735ab6 clean: remove mount points when possible

  • 25: b0da6be = 39: 576adf4 transport: optionally disable side-band-64k

  • 26: 50e7e7f = 40: 0c2cf9d mingw: fix fatal error working on mapped network drives on Windows

  • 27: 18338d2 = 41: 7c157e5 clink.pl: fix MSVC compile script to handle libcurl-d.lib

  • 51: aa07572 = 42: 4f0a533 mingw: implement a platform-specific strbuf_realpath()

  • 52: 06492ec = 43: 6d3c3e9 t3701: verify that we can add lots of files interactively

  • 53: 93a52a5 = 44: 8ce7172 commit: accept "scissors" with CR/LF line endings

  • 54: 133b3cb = 45: 4230c64 t0014: fix indentation

  • 55: 6218bb4 = 46: 45e6eba git-gui: accommodate for intent-to-add files

  • 56: 4853804 = 47: 9af77a6 mingw: allow for longer paths in parse_interpreter()

  • 57: d755bae = 48: 616e247 compat/vcbuild: document preferred way to build in Visual Studio

  • 58: cfe64fc = 49: 8ba04f8 http: optionally send SSL client certificate

  • 59: 2b3dcf8 = 50: 59fdced ci: run contrib/subtree tests in CI builds

  • 66: e4c611c = 51: cf6a53d windows: skip linking git-<command> for built-ins

  • 67: 323ae85 = 52: 4e5a282 mingw: stop hard-coding CC = gcc

  • 68: a3206e9 = 53: cd73a15 mingw: drop the -D_USE_32BIT_TIME_T option

  • 69: a21c00b = 54: b7a0758 mingw: only use -Wl,--large-address-aware for 32-bit builds

  • 70: 8aa7da3 = 55: f6902c3 mingw: avoid over-specifying --pic-executable

  • 71: a35283a = 56: 29eaf5a mingw: set the prefix and HOST_CPU as per MSYS2's settings

  • 72: a43be7f = 57: 19f8438 mingw: only enable the MSYS2-specific stuff when compiling in MSYS2

  • 73: d2d4b25 = 58: b031e42 mingw: rely on MSYS2's metadata instead of hard-coding it

  • 74: a3a83e7 = 59: 40c102c mingw: always define ETC_* for MSYS2 environments

  • 75: ee98cab = 60: 0d1908f max_tree_depth: lower it for clang builds in general on Windows

  • 76: 0ab8e6b = 61: 337553c mingw: ensure valid CTYPE

  • 77: a9d5297 = 62: fd399a1 mingw: allow git.exe to be used instead of the "Git wrapper"

  • 78: a476fd2 = 63: abbc0be mingw: ignore HOMEDRIVE/HOMEPATH if it points to Windows' system directory

  • 79: 753435c = 64: da5010f Merge branch 'dscho-avoid-d-f-conflict-in-vs-master'

  • 80: 2298f60 = 65: 8285c99 clink.pl: fix libexpatd.lib link error when using MSVC

  • 81: 07b02c9 = 66: f2e9772 Makefile: clean up .ilk files when MSVC=1

  • 35: 354d6ac = 67: 998218b hash-object: demonstrate a >4GB/LLP64 problem

  • 82: b5779d2 = 68: 8d1659d vcbuild: add support for compiling Windows resource files

  • 37: 2d4b77d = 69: e8fecfe object-file.c: use size_t for header lengths

  • 83: 99a6241 = 70: 4b63eb9 config.mak.uname: add git.rc to MSVC builds

  • 50: a1cfda1 = 71: 1d6de9f MinGW: link as terminal server aware

  • 88: 0634544 = 72: 8c74f64 ci: work around a problem with HTTP/2 vs libcurl v8.10.0

  • 39: a8f80ab = 73: 1cb14da hash algorithms: use size_t for section lengths

  • 84: 4a2ae90 = 74: ad6e77a clink.pl: ignore no-stack-protector arg on MSVC=1 builds

  • 85: f015961 = 75: 4266316 http: optionally load libcurl lazily

  • 91: 1abf2d7 = 76: 6d22caa revision: create mark_trees_uninteresting_dense()

  • 41: f8850f5 = 77: 96f4f33 hash-object --stdin: verify that it works with >4GB/LLP64

  • 86: 8313c4b = 78: 69ca06e clink.pl: move default linker options for MSVC=1 builds

  • 87: 699f855 = 79: c14ed01 http: support lazy-loading libcurl also on Windows

  • 104: 116ecbe = 80: 843ee17 survey: stub in new experimental 'git-survey' command

  • 45: e29d66a = 81: 5c5f3e4 CMakeLists: add default "x64-windows" arch for Visual Studio

  • 46: 9d931ff = 82: 8905db9 hash-object: add another >4GB/LLP64 test case

  • 47: 2801e51 = 83: 9c3aab1 setup: properly use "%(prefix)/" when in WSL

  • 48: c7ecd3e = 84: 0e7f37a Add config option windows.appendAtomically

  • 89: 344f800 = 85: 63c148b cmake: install headless-git.

  • 90: 54a10cf = 86: ecdad86 http: when loading libcurl lazily, allow for multiple SSL backends

  • 105: 4ef7c32 = 87: 90f6dee survey: add command line opts to select references

  • 60: 832e840 = 88: b6f01d3 CMake: show Win32 and Generator_platform build-option values

  • 61: 09c9960 = 89: d431de8 hash-object: add a >4GB/LLP64 test case using filtered input

  • 62: 2e09301 = 90: 5d68686 compat/mingw.c: do not warn when failing to get owner

  • 63: 12bc6cd = 91: 66d143a mingw: $env:TERM="xterm-256color" for newer OSes

  • 64: 225aae2 = 92: 15083e4 winansi: check result and Buffer before using Name

  • 65: ca2a331 = 93: 7dad5a0 mingw: change core.fsyncObjectFiles = 1 by default

  • 92: 5629855 = 94: 1ca87bb Fix Windows version resources

  • 93: 7341bd5 = 95: 75357f5 status: fix for old-style submodules with commondir

  • 94: 5830a51 = 96: 68ef1b5 git.rc: include winuser.h

  • 95: 3daf1bd = 97: 6ae655b mingw: do load libcurl dynamically by default

  • 96: 4961f8f = 98: 4c6d744 Add a GitHub workflow to verify that Git/Scalar work in Nano Server

  • 97: c410892 = 99: c80fa76 mingw: suggest windows.appendAtomically in more cases

  • 98: 028afe2 = 100: 3f8b538 win32: use native ANSI sequence processing, if possible

  • 99: 8359193 = 101: 569c418 common-main.c: fflush stdout buffer upon exit

  • 100: afafee5 = 102: 4c18d33 t5601/t7406(mingw): do run tests with symlink support

  • 101: 74dd717 = 103: 03e7ed5 win32: ensure that localtime_r() is declared even in i686 builds

  • 102: 76a0372 = 104: bcb3540 Fallback to AppData if XDG_CONFIG_HOME is unset

  • 103: efd2e47 = 105: 66fc1c1 run-command: be helpful with Git LFS fails on Windows 7

  • 106: d23ba3d = 106: 0e54949 survey: start pretty printing data in table form

  • 107: 6c05eb3 = 107: 3974c17 survey: add object count summary

  • 108: 245adb8 = 108: c855d7d survey: summarize total sizes by object type

  • 109: 7260f43 = 109: 975179a survey: show progress during object walk

  • 113: 6fa2ad5 = 110: 7f6274f mingw: make sure errno is set correctly when socket operations fail

  • 110: 7d39c91 = 111: bee8ba3 survey: add ability to track prioritized lists

  • 115: 8e1786e = 112: a51c996 compat/mingw: handle WSA errors in strerror

  • 111: 449d0a6 = 113: 108fb67 survey: add report of "largest" paths

  • 118: 766e51c = 114: 2a8971c compat/mingw: drop outdated comment

  • 112: e6e9e24 = 115: cfa6c06 survey: add --top= option and config

  • 120: 3c37f5f = 116: c9c8708 t0301: actually test credential-cache on Windows

  • 114: ae38f2e = 117: 4f9a984 survey: clearly note the experimental nature in the output

  • 122: 2106622 = 118: 59a89c0 credential-cache: handle ECONNREFUSED gracefully

  • 123: 4992ef6 = 119: 56806fa reftable: do make sure to use custom allocators

  • 124: 6c54223 = 120: d9d2466 check-whitespace: avoid alerts about upstream commits

  • 125: dca2c14 = 121: 6024920 t/t5571-prep-push-hook.sh: Add test with writing to stderr

  • 116: d9afdd5 ! 122: 14254d0 t5563: verify that NTLM authentication works

    @@ t/lib-httpd/ntlm-handshake.sh (new)
     +esac
     
      ## t/t5563-simple-http-auth.sh ##
    -@@ t/t5563-simple-http-auth.sh: test_expect_success 'access using three-legged auth' '
    - 	EOF
    +@@ t/t5563-simple-http-auth.sh: test_expect_success SPNEGO 'http.emptyAuth=false skips Negotiate' '
    + 	test_line_count = 1 actual_401s
      '
      
     +test_lazy_prereq NTLM 'curl --version | grep -q NTLM'
  • 117: ceb4e7a = 123: 074037a http: disallow NTLM authentication by default

  • 119: d9783c4 ! 124: 45324f1 http: warn if might have failed because of NTLM

    @@ http.c: static int handle_curl_result(struct slot_results *results)
     +			}
      			return HTTP_NOAUTH;
      		} else {
    - 			http_auth_methods &= ~CURLAUTH_GSSNEGOTIATE;
    + 			if (curl_empty_auth == -1 &&
     
      ## t/t5563-simple-http-auth.sh ##
     @@ t/t5563-simple-http-auth.sh: test_expect_success NTLM 'access using NTLM auth' '
  • 121: 97ba02a ! 125: 9535b80 credential: advertise NTLM suppression and allow helpers to re-enable

    @@ http.c: static int handle_curl_result(struct slot_results *results)
      					  "NTLM authentication has been

"
"disabled in Git by default. You can "
@@ http.c: static int http_request_recoverable(const char *url,

  •    	credential_fill(the_repository, &http_auth, 1);
    
  •    	http_reauth_prepare(1);
       }
    
+		/*

* 126:  f699badd1a = 126:  c812404ca5 dir: do not traverse mount points
* 127:  c7a0390506 = 127:  266a0866bd win32: thread-utils: handle multi-socket systems
* 128:  ae8089ead6 = 128:  7d7a24eed0 Merge 'remote-hg-prerequisites' into HEAD
* 129:  372d9317e6 = 129:  b728a62d08 Merge branch 'drive-prefix'
* 130:  fafbc85f91 = 130:  f7ea4a5b60 Merge branch 'dont-clean-junctions'
* 131:  d7eb6ce7db = 131:  023f8f0002 Merge branch 'msys2-python'
* 132:  64ec4dc4bb = 132:  52ed2509a7 Update mimalloc to v2.2.7 (#6048)
* 133:  4eee9d33bd = 133:  86c257e963 Merge pull request #2375 from assarbad/reintroduce-sideband-config
* 143:  cdfd0e535a = 134:  34f57234e4 t5563: add tests for http.emptyAuth with Negotiate
* 134:  0973138e67 = 135:  ea8a53b96f Merge pull request #2488 from bmueller84/master
* 135:  f97aba87d2 = 136:  c34f652b91 Merge pull request #2501 from jeffhostetler/clink-debug-curl
* 136:  4b6af64c52 = 137:  6a1af90703 Merge pull request #2504 from dscho/access-repo-via-junction
* 137:  8e361bc9e7 = 138:  cef138df87 Merge pull request #2535 from dscho/schannel-revoke-best-effort
* 138:  b41ebcb707 = 139:  07c2fce07c Merge pull request #2618 from dscho/avoid-d/f-conflict-in-vs/master
* 139:  9302e44f0b <   -:  ---------- http: extract http_reauth_prepare() from retry paths
* 140:  530a92bc3c = 140:  24d0a84383 Merge 'add-p-many-files'
* 141:  5768bacde8 <   -:  ---------- http: attempt Negotiate auth in http.emptyAuth=auto mode
* 142:  7dd4b0efbd = 141:  03365d59fb Merge pull request #2714 from lbonanomi/crlf-scissors
* 144:  f16cb5b50b = 142:  cef6206a4f Merge pull request #2655 from jglathe/jg/t0014_trace_extra_info
* 145:  ba984f1e1e = 143:  01d4aa77a5 Merge 'git-gui/js/intent-to-add'
* 146:  59249ca447 = 144:  2460218152 Merge pull request #2351 from PhilipOakley/vcpkg-tip
* 147:  c18efcd5cc = 145:  21159c0113 Merge pull request #2915 from dennisameling/windows-arm64-support
* 148:  eba3d5007d = 146:  a1b88a7c6d Merge pull request #3327 from dennisameling/fix-host-cpu
* 149:  01141ffedb = 147:  1ac7a43ea2 Merge pull request #3165 from dscho/increase-allowed-length-of-interpreter-path
* 150:  487127c028 = 148:  87c9140127 Merge pull request #3220 from dscho/there-is-no-vs/master-anymore
* 151:  4aeb306a0d = 149:  0703119239 Merge pull request #3293 from pascalmuller/http-support-automatically-sending-client-certificate
* 152:  306e0ec000 = 150:  f93590b6ec Merge pull request #3349 from vdye/feature/ci-subtree-tests
* 153:  1811a04e0d = 151:  4bfe548277 Merge pull request #3306 from PhilipOakley/vs-sln
* 154:  9ef497ff6d = 152:  9683d339ac Merge pull request #3533 from PhilipOakley/hashliteral_t
* 155:  7c77c2c699 = 153:  3d9d4bb0c6 Merge pull request #3791: Various fixes around `safe.directory`
* 156:  6b4bcc09c7 = 154:  a2331391c6 Merge pull request #3751 from rkitover/native-term
* 157:  fb116656b1 = 155:  82be1a5cc2 Merge pull request #3875 from 1480c1/wine/detect_msys_tty
* 158:  5fbaa195f8 = 156:  1f0d650172 Merge branch 'optionally-dont-append-atomically-on-windows'
* 159:  7f9636cb20 = 157:  f19db9043a Merge branch 'fsync-object-files-always'
* 160:  de665dba39 = 158:  c61f38f377 Merge pull request #3942 from rimrul/mingw-tsaware
* 161:  c9398a49f4 = 159:  cbc4f37e47 Fix Windows version resources (#4092)
* 162:  0aa8c40659 = 160:  4eb91d2357 Fix global repository field not being cleared (#4083)
* 163:  f20d2c66da = 161:  8ed7d42092 Skip linking the "dashed" `git-<command>`s for built-ins (#4252)
* 164:  8ba31e7628 = 162:  74c3c792e6 Add full `mingw-w64-git` (i.e. regular MSYS2 ecosystem) support (#5971)
* 165:  fc0b62d914 = 163:  a7dd6f54fe Merge pull request #2506 from dscho/issue-2283
* 166:  918447740e = 164:  e9d767c68d Merge pull request #2974 from derrickstolee/maintenance-and-headless
* 167:  ae7033b6bc = 165:  2a56b57584 ARM64: Embed manifest properly (#4718)
* 168:  189417d7ff = 166:  9c2e6f9ff0 Lazy load libcurl, allowing for an SSL/TLS backend-specific libcurl (#4410)
* 169:  3fe7fbace9 = 167:  36a364e43d Merge branch 'nano-server'
* 170:  e23f5ef8b9 = 168:  9273cf5bd3 Additional error checks for issuing the windows.appendAtomically warning (#4528)
* 171:  a89a5622ae = 169:  5a25ab0ad9 win32: use native ANSI sequence processing, if possible (#4700)
* 172:  206eb21d63 = 170:  281ad3a7c3 common-main.c: fflush stdout buffer when exit (#4901)
* 173:  5607d1ad11 = 171:  cb6d5b92d3 Merge branch 'run-t5601-and-t7406-with-symlinks-on-windows-10'
* 174:  5955f7263c = 172:  e3bc0d8c26 Merge branch 'Fix-i686-build-with-GCC-v14'
* 175:  2a64276429 = 173:  7c31c83df2 Merge branch 'Fallback-to-AppData-if-XDG-CONFIG-HOME-is-unset'
* 176:  ede3ef81c4 = 174:  f99227d0b8 Merge branch 'run-command-be-helpful-when-Git-LFS-fails-on-Windows-7'
* 177:  72238b64c7 = 175:  b094647f6d pack-objects: create new name-hash algorithm (#5157)
* 178:  e488ec192d = 176:  cc47e9f6a8 Add path walk API and its use in 'git pack-objects' (#5171)
* 179:  1795559fa0 = 177:  79e3f63ed2 Add experimental 'git survey' builtin (#5174)
* 180:  3de431458b = 178:  32e567344c credential-cache: handle ECONNREFUSED gracefully (#5329)
* 181:  7218437948 = 179:  b3c3c3581b Merge branch 'reftable-vs-custom-allocators'
* 182:  232919595d = 180:  d96df75df6 Merge branch 'check-whitespace-only-downstream'
* 183:  fd75aae38b = 181:  c27fddaf0f t/t5571-prep-push-hook.sh: Add test with writing to stderr (#6063)
* 184:  8a48d7524b = 182:  d97615cea8 Merge branch 'disallow-ntlm-auth-by-default'
* 185:  d9d521fb78 = 183:  9cb5796881 Don't traverse mount points in `remove_dir_recurse()` (#6151)
* 186:  a46762c922 = 184:  d9155fdc54 Detect number of cores better on multi-socket systems (#6108)
* 187:  bc8af36bef = 185:  9b8735b7bb http: fix emptyAuth=auto for Negotiate/SPNEGO (#6170)
* 188:  949bda56db = 186:  d1fccedc88 Merge branch 'ready-for-upstream'
* 189:  03fa90baa0 = 187:  0e7ad32cdc ci(macos): skip the `git p4` tests
* 190:  ee23d43581 = 188:  d555a365c0 ci(macos): skip the `git p4` tests (#5954)
* 194:  2a8cb837b8 = 189:  75bda6c00a Win32: make FILETIME conversion functions public
* 195:  28ad21e5b1 = 190:  1d871f6df6 Win32: dirent.c: Move opendir down
* 196:  16a53e4513 = 191:  84e9b30323 mingw: make the dirent implementation pluggable
* 197:  8c8bf65a33 = 192:  e501b6174b Win32: make the lstat implementation pluggable
* 198:  a02dab51a9 = 193:  df0547a248 mingw: add infrastructure for read-only file system level caches
* 199:  427d69392c = 194:  499b999a8f mingw: add a cache below mingw's lstat and dirent implementations
* 200:  67942d5ce9 = 195:  7fc2b4a9a8 fscache: load directories only once
* 201:  49d1dd8486 = 196:  24059da55e fscache: add key for GIT_TRACE_FSCACHE
* 202:  5b1751a7d3 = 197:  f2051970cb fscache: remember not-found directories
* 203:  b0397bee4a = 198:  02637facfc fscache: add a test for the dir-not-found optimization
* 204:  f9834d2b8a = 199:  b6655e6b4a add: use preload-index and fscache for performance
* 205:  0fb9245dd0 = 200:  70dab59e79 dir.c: make add_excludes aware of fscache during status
* 206:  13d77f48db = 201:  1a29bea995 fscache: make fscache_enabled() public
* 207:  4e9d5f5109 = 202:  2879555f2a dir.c: regression fix for add_excludes with fscache
* 191:  af1fd91c5e = 203:  28dd976396 git-gui--askyesno: fix funny text wrapping
* 208:  a1abab3446 = 204:  d237ae9a20 fetch-pack.c: enable fscache for stats under .git/objects
* 192:  d0db07d608 = 205:  3f89a243e1 git-gui--askyesno (mingw): use Git for Windows' icon, if available
* 209:  46e23f04ff = 206:  1ead27993e checkout.c: enable fscache for checkout again
* 193:  ad4da79e67 = 207:  a39d7bca3c Merge branch 'git-gui-askyesno'
* 210:  4e31145c8a = 208:  4210e93799 Enable the filesystem cache (fscache) in refresh_index().
* 211:  280307d9dd = 209:  3a0952a9d1 fscache: use FindFirstFileExW to avoid retrieving the short name
* 212:  23f998f761 = 210:  09acbfadd5 fscache: add GIT_TEST_FSCACHE support
* 213:  4d8ac03d38 = 211:  b7c4371f19 fscache: add fscache hit statistics
* 214:  d085869a4d = 212:  4f8e8570bd unpack-trees: enable fscache for sparse-checkout
* 215:  7715d716eb = 213:  ddd76b9fda status: disable and free fscache at the end of the status command
* 216:  1076b0c835 = 214:  5ddcdde543 mem_pool: add GIT_TRACE_MEMPOOL support
* 217:  aac0a68a60 = 215:  81a062006c fscache: fscache takes an initial size
* 218:  413d908a2d = 216:  771991adc7 fscache: update fscache to be thread specific instead of global
* 219:  f3f4509cee = 217:  b350ace380 fscache: teach fscache to use mempool
* 220:  aba28f5f45 = 218:  a776076998 fscache: make fscache_enable() thread safe
* 221:  5af75627b4 = 219:  7e3ba95e19 fscache: teach fscache to use NtQueryDirectoryFile
* 222:  85eb764ccb = 220:  e8fac49c88 fscache: remember the reparse tag for each entry
* 223:  7c60e1553e = 221:  341f11eabf Merge branch 'fscache'
* 224:  23b6fb12bd = 222:  a90bc24c28 fscache: implement an FSCache-aware is_mount_point()
* 225:  14f48d1daa = 223:  e4f1aed2e8 Merge pull request #1909 from benpeart/free-fscache-after-status-gfw
* 226:  b981de98e7 = 224:  e97b1f2e04 clean: make use of FSCache
* 227:  0277fa12ec = 225:  4d7c3c8ba9 Merge remote-tracking branch 'benpeart/fscache-per-thread-gfw'
* 228:  1410c519ae = 226:  6dba66fae1 Merge branch 'dont-clean-junctions-fscache'
* 229:  329d57a45a = 227:  e18a13ca78 pack-objects (mingw): demonstrate a segmentation fault with large deltas
* 230:  ea18008f29 = 228:  e88d20e9c1 mingw: support long paths
* 231:  074711fb1e = 229:  f2881ee0a9 win32(long path support): leave drive-less absolute paths intact
* 232:  c1954dfbed = 230:  add4c4b351 compat/fsmonitor/fsm-*-win32: support long paths
* 233:  9d5e4a20ca = 231:  5c442c8084 clean: suggest using `core.longPaths` if paths are too long to remove
* 234:  f404cd16c6 = 232:  208c3d2c0c mingw: Support `git_terminal_prompt` with more terminals
* 235:  13b171fe10 = 233:  10a7309744 compat/terminal.c: only use the Windows console if bash 'read -r' fails
* 236:  e87fa1ed3b = 234:  ad6d467e21 mingw (git_terminal_prompt): do fall back to CONIN$/CONOUT$ method
* 237:  04c3c9a06e = 235:  edffaaf04c Win32: symlink: move phantom symlink creation to a separate function
* 238:  b9dd9c3763 = 236:  9abbd324b9 Introduce helper to create symlinks that knows about index_state
* 239:  2c808e4f70 = 237:  3728ccdba2 mingw: allow to specify the symlink type in .gitattributes
* 240:  e43dd75d9a = 238:  d542599de8 Win32: symlink: add test for `symlink` attribute
* 241:  2fc1e8c55b = 239:  d71cdec827 mingw: explicitly specify with which cmd to prefix the cmdline
* 242:  a45ca1e41a = 240:  a2ed09e67f mingw: when path_lookup() failed, try BusyBox
* 243:  9fdeaeb67a = 241:  a2221bc125 test-tool: learn to act as a drop-in replacement for `iconv`
* 245:  e43a12b0cb = 242:  9fb05b9b8c tests(mingw): if `iconv` is unavailable, use `test-helper --iconv`
* 247:  159cd71835 = 243:  09705f4ab3 gitattributes: mark .png files as binary
* 249:  eaee5688cd = 244:  8518eb04a1 tests: move test PNGs into t/lib-diff/
* 251:  ea7ffe1003 = 245:  ef47f070b3 tests: only override sort & find if there are usable ones in /usr/bin/
* 253:  b80ff3e1e6 = 246:  4ca8e3bd3a tests: use the correct path separator with BusyBox
* 254:  88a8073257 = 247:  258bcd5930 mingw: only use Bash-ism `builtin pwd -W` when available
* 255:  430125fa85 = 248:  1af5745229 tests (mingw): remove Bash-specific pwd option
* 256:  4b3e90192e = 249:  6aa0e68c66 test-lib: add BUSYBOX prerequisite
* 244:  d9946583e6 = 250:  5b1973bd1e mingw: introduce code to detect whether we're inside a Windows container
* 257:  358027139c = 251:  b063c243d9 t5003: use binary file from t/lib-diff/
* 246:  9672baf6b4 = 252:  116cb35c9c mingw: when running in a Windows container, try to rename() harder
* 258:  9c7ca7a2d0 = 253:  56362740ae t5532: workaround for BusyBox on Windows
* 248:  95d9effab2 = 254:  eabcc71073 mingw: move the file_attr_to_st_mode() function definition
* 259:  ee372bc083 = 255:  2a1340c723 t5605: special-case hardlink test for BusyBox-w32
* 250:  cc108aab85 = 256:  67e95cc388 mingw: Windows Docker volumes are *not* symbolic links
* 260:  80cd2dfc10 = 257:  0a575a422f t5813: allow for $PWD to be a Windows path
* 252:  35b03ee9b2 = 258:  b7ba476455 mingw: work around rename() failing on a read-only file
* 261:  d9dc806b5e = 259:  8c955d73d2 t9200: skip tests when $PWD contains a colon
* 270:  3f5c06533b = 260:  7ff9bbbec6 Merge branch 'gitk-and-git-gui-patches'
* 278:  133987009f = 261:  0af447f120 Merge branch 'long-paths'
* 279:  a50696eb7a = 262:  780de0e342 Merge branch 'msys2'
* 280:  55ce4787bf = 263:  263b41cc71 Merge 'docker-volumes-are-no-symlinks'
* 281:  6e432c6653 = 264:  a4d6684f12 mingw: try resetting the read-only bit if rename fails (#4527)
* 282:  9a54133eeb = 265:  d73d7e5bb7 Merge pull request #1897 from piscisaureus/symlink-attr
* 262:  c4d99df421 = 266:  c6383b7903 Describe Git for Windows' architecture [no ci]
* 267:  3b0614450a = 267:  cdbe4d4167 mingw: kill child processes in a gentler way
* 271:  a410e4f641 = 268:  8fdcab718a mingw: optionally enable wsl compability file mode bits
* 283:  04fb48152a = 269:  a7261c1e8e Merge branch 'busybox-w32'
* 263:  28c35fb176 = 270:  e70b70afd7 Modify the Code of Conduct for Git for Windows
* 272:  94d6cf57a0 = 271:  9624b94bcb mingw: really handle SIGINT
* 284:  b850fda5ce = 272:  10846e4f32 Merge branch 'wsl-file-mode-bits'
* 264:  b1def4ed80 = 273:  1513f447ef CONTRIBUTING.md: add guide for first-time contributors
* 273:  5b2b503fab = 274:  c2e5071751 Partially un-revert "editor: save and reset terminal after calling EDITOR"
* 285:  a11329c9bf = 275:  f8a120a2e7 Merge pull request #1170 from dscho/mingw-kill-process
* 265:  d0f8e5127c = 276:  10fbb790aa README.md: Add a Windows-specific preamble
* 274:  abb10e60e1 = 277:  1db2d78231 reset: reinstate support for the deprecated --stdin option
* 286:  bba86d512b = 278:  e0232e2918 Merge branch 'un-revert-editor-save-and-reset'
* 266:  95beeacf25 = 279:  587086df72 Add an issue template
* 268:  b6688a6416 = 280:  9294af9b32 Add a GitHub workflow to monitor component updates
* 275:  e2c269960f = 281:  f988e269bc fsmonitor: reintroduce core.useBuiltinFSMonitor
* 287:  fc36fa7b05 = 282:  6aae3ff828 Merge branch 'phase-out-reset-stdin'
* 269:  3cc59eba50 = 283:  5e5f104dfc Modify the GitHub Pull Request template (to reflect Git for Windows)
* 276:  072a66b535 = 284:  03f9a5c1e6 dependabot: help keeping GitHub Actions versions up to date
* 288:  4cb42d01d9 = 285:  7f851b46f3 Merge branch 'deprecate-core.useBuiltinFSMonitor'
* 277:  5aa3792b6a = 286:  9d5e6f5b33 SECURITY.md: document Git for Windows' policies
* 289:  3b3ebef99d = 287:  d81b5d47a4 Merge pull request #2837 from dscho/monitor-component-updates
* 290:  afbccd0569 = 288:  97a84e1ce1 Merge 'readme' into HEAD

</details>

dscho and others added 30 commits April 16, 2026 19:07
The convention in Git project's shell scripts is to have white-space
_before_, but not _after_ the `>` (or `<`).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This change enhances `git commit --cleanup=scissors` by detecting
scissors lines ending in either LF (UNIX-style) or CR/LF (DOS-style).

Regression tests are included to specifically test for trailing
comments after a CR/LF-terminated scissors line.

Signed-off-by: Luke Bonanomi <lbonanomi@gmail.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
For some reason, this test case was indented with 4 spaces instead of 1
horizontal tab. The other test cases in the same test script are fine.

Signed-off-by: Jens Glathe <jens.glathe@oldschoolsolutions.biz>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
As of Git v2.28.0, the diff for files staged via `git add -N` marks them
as new files. Git GUI was ill-prepared for that, and this patch teaches
Git GUI about them.

Please note that this will not even fix things with v2.28.0, as the
`rp/apply-cached-with-i-t-a` patches are required on Git's side, too.

This fixes git-for-windows#2779

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>
The vcpkg downloads may not succeed. Warn careful readers of the time out.

A simple retry will usually resolve the issue.

Signed-off-by: Philip Oakley <philipoakley@iee.email>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Dennis Ameling <dennis@dennisameling.com>
Git's regular Makefile mentions that HOST_CPU should be defined when cross-compiling Git: https://github.com/git-for-windows/git/blob/37796bca76ef4180c39ee508ca3e42c0777ba444/Makefile#L438-L439

This is then used to set the GIT_HOST_CPU variable when compiling Git: https://github.com/git-for-windows/git/blob/37796bca76ef4180c39ee508ca3e42c0777ba444/Makefile#L1337-L1341

Then, when the user runs `git version --build-options`, it returns that value: https://github.com/git-for-windows/git/blob/37796bca76ef4180c39ee508ca3e42c0777ba444/help.c#L658

This commit adds the same functionality to the CMake configuration. Users can now set -DHOST_CPU= to set the target architecture.

Signed-off-by: Dennis Ameling <dennis@dennisameling.com>
As reported in newren/git-filter-repo#225, it
looks like 99 bytes is not really sufficient to represent e.g. the full
path to Python when installed via Windows Store (and this path is used
in the hasb bang line when installing scripts via `pip`).

Let's increase it to what is probably the maximum sensible path size:
MAX_PATH. This makes `parse_interpreter()` in line with what
`lookup_prog()` handles.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Vilius Šumskas <vilius@sumskas.eu>
We used to have that `make vcxproj` hack, but a hack it is. In the
meantime, we have a much cleaner solution: using CMake, either
explicitly, or even more conveniently via Visual Studio's built-in CMake
support (simply open Git's top-level directory via File>Open>Folder...).

Let's let the `README` reflect this.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This adds support for a new http.sslAutoClientCert config value.

In cURL 7.77 or later the schannel backend does not automatically send
client certificates from the Windows Certificate Store anymore.

This config value is only used if http.sslBackend is set to "schannel",
and can be used to opt in to the old behavior and force cURL to send
client certificates.

This fixes git-for-windows#3292

Signed-off-by: Pascal Muller <pascalmuller@gmail.com>
Because `git subtree` (unlike most other `contrib` modules) is included as
part of the standard release of Git for Windows, its stability should be
verified as consistently as it is for the rest of git. By including the
`git subtree` tests in the CI workflow, these tests are as much of a gate to
merging and indicator of stability as the standard test suite.

Signed-off-by: Victoria Dye <vdye@github.com>
This is no longer true in general, not with supporting Clang out of the
box.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This option was added in fa93bb2 (MinGW: Fix stat definitions to
work with MinGW runtime version 4.0, 2013-09-11), i.e. a _long_ time
ago. So long, in fact, that it still targeted MinGW. But we switched to
mingw-w64 in 2015, which seems not to share the problem, and therefore
does not require a fix.

Even worse: This flag is incompatible with UCRT64, which we are about to
support by way of upstreaming `mingw-w64-git` to the MSYS2 project, see
msys2/MINGW-packages#26470 for details.

So let's send that option into its well-deserved retirement.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Merge this early to resolve merge conflicts early.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
That option only matters there, and is in fact only really understood in
those builds; UCRT64 versions of GCC, for example, do not know what to
do with that option.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
When building with `make MSVC=1 DEBUG=1`, link to `libexpatd.lib`
rather than `libexpat.lib`.

It appears that the `vcpkg` package for "libexpat" has changed and now
creates `libexpatd.lib` for debug mode builds.  Previously, both debug
and release builds created a ".lib" with the same basename.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
On LLP64 systems, such as Windows, the size of `long`, `int`, etc. is
only 32 bits (for backward compatibility). Git's use of `unsigned long`
for file memory sizes in many places, rather than size_t, limits the
handling of large files on LLP64 systems (commonly given as `>4GB`).

Provide a minimum test for handling a >4GB file. The `hash-object`
command, with the  `--literally` and without `-w` option avoids
writing the object, either loose or packed. This avoids the code paths
hitting the `bigFileThreshold` config test code, the zlib code, and the
pack code.

Subsequent patches will walk the test's call chain, converting types to
`size_t` (which is larger in LLP64 data models) where appropriate.

Signed-off-by: Philip Oakley <philipoakley@iee.email>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
In bf2d5d8 (Don't let ld strip relocations, 2016-01-16) (picked from
git-for-windows@6a237925bf10),
Git for Windows introduced the `-Wl,-pic-executable` flag, specifying
the exact entry point via `-e`. This required discerning between i686
and x86_64 code because the former required the symbol to be prefixed
with an underscore, the latter did not.

As per https://sourceware.org/bugzilla/show_bug.cgi?id=10865, the
specified symbols are already the default, though.

So let's drop the overly-specific definition.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Continue walking the code path for the >4GB `hash-object --literally`
test. The `hash_object_file_literally()` function internally uses both
`hash_object_file()` and `write_object_file_prepare()`. Both function
signatures use `unsigned long` rather than `size_t` for the mem buffer
sizes. Use `size_t` instead, for LLP64 compatibility.

While at it, convert those function's object's header buffer length to
`size_t` for consistency. The value is already upcast to `uintmax_t` for
print format compatibility.

Note: The hash-object test still does not pass. A subsequent commit
continues to walk the call tree's lower level hash functions to identify
further fixes.

Signed-off-by: Philip Oakley <philipoakley@iee.email>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
MSYS2 already defines a couple of helpful environment variables, and we
can use those to infer the installation location as well as the CPU. No
need for hard-coding ;-)

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Create a wrapper for the Windows Resource Compiler (RC.EXE)
for use by the MSVC=1 builds. This is similar to the CL.EXE
and LIB.EXE wrappers used for the MSVC=1 builds.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Continue walking the code path for the >4GB `hash-object --literally`
test to the hash algorithm step for LLP64 systems.

This patch lets the SHA1DC code use `size_t`, making it compatible with
LLP64 data models (as used e.g. by Windows).

The interested reader of this patch will note that we adjust the
signature of the `git_SHA1DCUpdate()` function without updating _any_
call site. This certainly puzzled at least one reviewer already, so here
is an explanation:

This function is never called directly, but always via the macro
`platform_SHA1_Update`, which is usually called via the macro
`git_SHA1_Update`. However, we never call `git_SHA1_Update()` directly
in `struct git_hash_algo`. Instead, we call `git_hash_sha1_update()`,
which is defined thusly:

    static void git_hash_sha1_update(git_hash_ctx *ctx,
                                     const void *data, size_t len)
    {
        git_SHA1_Update(&ctx->sha1, data, len);
    }

i.e. it contains an implicit downcast from `size_t` to `unsigned long`
(before this here patch). With this patch, there is no downcast anymore.

With this patch, finally, the t1007-hash-object.sh "files over 4GB hash
literally" test case is fixed.

Signed-off-by: Philip Oakley <philipoakley@iee.email>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
The tell-tale is the presence of the `MSYSTEM` value while compiling, of
course. In that case, we want to ensure that `MSYSTEM` is set when
running `git.exe`, and also enable the magic MSYS2 tty detection.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Teach MSVC=1 builds to depend on the `git.rc` file so that
the resulting executables have Windows-style resources and
version number information within them.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
This compile-time option allows to ask Git to load libcurl dynamically
at runtime.

Together with a follow-up patch that optionally overrides the file name
depending on the `http.sslBackend` setting, this kicks open the door for
installing multiple libcurl flavors side by side, and load the one
corresponding to the (runtime-)configured SSL/TLS backend.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Just like the `hash-object --literally` code path, the `--stdin` code
path also needs to use `size_t` instead of `unsigned long` to represent
memory sizes, otherwise it would cause problems on platforms using the
LLP64 data model (such as Windows).

To limit the scope of the test case, the object is explicitly not
written to the object store, nor are any filters applied.

The `big` file from the previous test case is reused to save setup time;
To avoid relying on that side effect, it is generated if it does not
exist (e.g. when running via `sh t1007-*.sh --long --run=1,41`).

Signed-off-by: Philip Oakley <philipoakley@iee.email>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
MSYS2 defines some helpful environment variables, e.g. `MSYSTEM`. There
is code in Git for Windows to ensure that that `MSYSTEM` variable is
set, hard-coding a default.

However, the existing solution jumps through hoops to reconstruct the
proper default, and is even incomplete doing so, as we found out when we
extended it to support CLANGARM64.

This is absolutely unnecessary because there is already a perfectly
valid `MSYSTEM` value we can use at build time. This is even true when
building the MINGW32 variant on a MINGW64 system because `makepkg-mingw`
will override the `MSYSTEM` value as per the `MINGW_ARCH` array.

The same is equally true for the `/mingw64`, `/mingw32` and
`/clangarm64` prefix: those values are already available via the
`MINGW_PREFIX` environment variable, and we just need to pass that
setting through.

Only when `MINGW_PREFIX` is not set (as is the case in Git for Windows'
minimal SDK, where only `MSYSTEM` is guaranteed to be set correctly), we
use as fall-back the top-level directory whose name is the down-cased
value of the `MSYSTEM` variable.

Incidentally, this also broadens the support to all the configurations
supported by the MSYS2 project, i.e. clang64 & ucrt64, too.

Note: This keeps the same, hard-coded MSYSTEM platform support for CMake
as before, but drops it for Meson (because it is unclear how Meson could
do this in a more flexible manner).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
A change between versions 2.4.1 and 2.6.0 of the MSYS2 runtime modified
how Cygwin's runtime (and hence Git for Windows' MSYS2 runtime
derivative) handles locales: d16a56306d (Consolidate wctomb/mbtowc calls
for POSIX-1.2008, 2016-07-20).

An unintended side-effect is that "cold-calling" into the POSIX
emulation will start with a locale based on the current code page,
something that Git for Windows is very ill-prepared for, as it expects
to be able to pass a command-line containing non-ASCII characters to the
shell without having those characters munged.

One symptom of this behavior: when `git clone` or `git fetch` shell out
to call `git-upload-pack` with a path that contains non-ASCII
characters, the shell tried to interpret the entire command-line
(including command-line parameters) as executable path, which obviously
must fail.

This fixes git-for-windows#1036

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
dscho and others added 30 commits April 16, 2026 19:11
To support Git Bash running in a MinTTY, we use a dirty trick to access
the MSYS2 pseudo terminal: we execute a Bash snippet that accesses
/dev/tty.

The idea was to fall back to writing to/reading from CONOUT$/CONIN$ if
that Bash call failed because Bash was not found.

However, we should fall back even in other error conditions, because we
have not successfully read the user input. Let's make it so.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
These are Git for Windows' Git GUI and gitk patches. We will have to
decide at some point what to do about them, but that's a little lower
priority (as Git GUI seems to be unmaintained for the time being, and
the gitk maintainer keeps a very low profile on the Git mailing list,
too).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This was pull request git-for-windows#1645 from ZCube/master

Support windows container.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
…ws#4527)

With this patch, Git for Windows works as intended on mounted APFS
volumes (where renaming read-only files would fail).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
The Git for Windows project has grown quite complex over the years,
certainly much more complex than during the first years where the
`msysgit.git` repository was abusing Git for package management purposes
and the `git/git` fork was called `4msysgit.git`.

Let's describe the status quo in a thorough way.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
The TerminateProcess() function does not actually leave the child
processes any chance to perform any cleanup operations. This is bad
insofar as Git itself expects its signal handlers to run.

A symptom is e.g. a left-behind .lock file that would not be left behind
if the same operation was run, say, on Linux.

To remedy this situation, we use an obscure trick: we inject a thread
into the process that needs to be killed and to let that thread run the
ExitProcess() function with the desired exit status. Thanks J Wyman for
describing this trick.

The advantage is that the ExitProcess() function lets the atexit
handlers run. While this is still different from what Git expects (i.e.
running a signal handler), in practice Git sets up signal handlers and
atexit handlers that call the same code to clean up after itself.

In case that the gentle method to terminate the process failed, we still
fall back to calling TerminateProcess(), but in that case we now also
make sure that processes spawned by the spawned process are terminated;
TerminateProcess() does not give the spawned process a chance to do so
itself.

Please note that this change only affects how Git for Windows tries to
terminate processes spawned by Git's own executables. Third-party
software that *calls* Git and wants to terminate it *still* need to make
sure to imitate this gentle method, otherwise this patch will not have
any effect.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
The Windows Subsystem for Linux (WSL) version 2 allows to use `chmod` on
NTFS volumes provided that they are mounted with metadata enabled (see
https://devblogs.microsoft.com/commandline/chmod-chown-wsl-improvements/
for details), for example:

	$ chmod 0755 /mnt/d/test/a.sh

In order to facilitate better collaboration between the Windows
version of Git and the WSL version of Git, we can make the Windows
version of Git also support reading and writing NTFS file modes
in a manner compatible with WSL.

Since this slightly slows down operations where lots of files are
created (such as an initial checkout), this feature is only enabled when
`core.WSLCompat` is set to true. Note that you also have to set
`core.fileMode=true` in repositories that have been initialized without
enabling WSL compatibility.

There are several ways to enable metadata loading for NTFS volumes
in WSL, one of which is to modify `/etc/wsl.conf` by adding:

```
[automount]
enabled = true
options = "metadata,umask=027,fmask=117"
```

And reboot WSL.

It can also be enabled temporarily by this incantation:

	$ sudo umount /mnt/c &&
	  sudo mount -t drvfs C: /mnt/c -o metadata,uid=1000,gid=1000,umask=22,fmask=111

It's important to note that this modification is compatible with, but
does not depend on WSL. The helper functions in this commit can operate
independently and functions normally on devices where WSL is not
installed or properly configured.

Signed-off-by: xungeng li <xungeng@gmail.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
The Git project followed Git for Windows' lead and added their Code of
Conduct, based on the Contributor Covenant v1.4, later updated to v2.0.

We adapt it slightly to Git for Windows.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Previously, we did not install any handler for Ctrl+C, but now we really
want to because the MSYS2 runtime learned the trick to call the
ConsoleCtrlHandler when Ctrl+C was pressed.

With this, hitting Ctrl+C while `git log` is running will only terminate
the Git process, but not the pager. This finally matches the behavior on
Linux and on macOS.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This patch introduces support to set special NTFS attributes that are
interpreted by the Windows Subsystem for Linux as file mode bits, UID
and GID.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Getting started contributing to Git can be difficult on a Windows
machine. CONTRIBUTING.md contains a guide to getting started, including
detailed steps for setting up build tools, running tests, and
submitting patches to upstream.

[includes an example by Pratik Karki how to submit v2, v3, v4, etc.]

Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
…ITOR"

In e3f7e01 (Revert "editor: save and reset terminal after calling
EDITOR", 2021-11-22), we reverted the commit wholesale where the
terminal state would be saved and restored before/after calling an
editor.

The reverted commit was intended to fix a problem with Windows Terminal
where simply calling `vi` would cause problems afterwards.

To fix the problem addressed by the revert, but _still_ keep the problem
with Windows Terminal fixed, let's revert the revert, with a twist: we
restrict the save/restore _specifically_ to the case where `vi` (or
`vim`) is called, and do not do the same for any other editor.

This should still catch the majority of the cases, and will bridge the
time until the original patch is re-done in a way that addresses all
concerns.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Handle Ctrl+C in Git Bash nicely

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Includes touch-ups by 마누엘, Philip Oakley and 孙卓识.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
The `--stdin` option was a well-established paradigm in other commands,
therefore we implemented it in `git reset` for use by Visual Studio.

Unfortunately, upstream Git decided that it is time to introduce
`--pathspec-from-file` instead.

To keep backwards-compatibility for some grace period, we therefore
reinstate the `--stdin` option on top of the `--pathspec-from-file`
option, but mark it firmly as deprecated.

Helped-by: Victoria Dye <vdye@github.com>
Helped-by: Matthew John Cheetham <mjcheetham@outlook.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
A fix for calling `vim` in Windows Terminal caused a regression and was
reverted. We partially un-revert this, to get the fix again.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
With improvements by Clive Chan, Adric Norris, Ben Bodenmiller and
Philip Oakley.

Helped-by: Clive Chan <cc@clive.io>
Helped-by: Adric Norris <landstander668@gmail.com>
Helped-by: Ben Bodenmiller <bbodenmiller@hotmail.com>
Helped-by: Philip Oakley <philipoakley@iee.org>
Signed-off-by: Brendan Forster <brendan@github.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Rather than using private IFTTT Applets that send mails to this
maintainer whenever a new version of a Git for Windows component was
released, let's use the power of GitHub workflows to make this process
publicly visible.

This workflow monitors the Atom/RSS feeds, and opens a ticket whenever a
new version was released.

Note: Bash sometimes releases multiple patched versions within a few
minutes of each other (i.e. 5.1p1 through 5.1p4, 5.0p15 and 5.0p16). The
MSYS2 runtime also has a similar system. We can address those patches as
a group, so we shouldn't get multiple issues about them.

Note further: We're not acting on newlib releases, OpenSSL alphas, Perl
release candidates or non-stable Perl releases. There's no need to open
issues about them.

Co-authored-by: Matthias Aßhauer <mha1993@live.de>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Reintroduce the 'core.useBuiltinFSMonitor' config setting (originally added
in 0a756b2 (fsmonitor: config settings are repository-specific,
2021-03-05)) after its removal from the upstream version of FSMonitor.

Upstream, the 'core.useBuiltinFSMonitor' setting was rendered obsolete by
"overloading" the 'core.fsmonitor' setting to take a boolean value. However,
several applications (e.g., 'scalar') utilize the original config setting,
so it should be preserved for a deprecation period before complete removal:

* if 'core.fsmonitor' is a boolean, the user is correctly using the new
  config syntax; do not use 'core.useBuiltinFSMonitor'.
* if 'core.fsmonitor' is unspecified, use 'core.useBuiltinFSMonitor'.
* if 'core.fsmonitor' is a path, override and use the builtin FSMonitor if
  'core.useBuiltinFSMonitor' is 'true'; otherwise, use the FSMonitor hook
  indicated by the path.

Additionally, for this deprecation period, advise users to switch to using
'core.fsmonitor' to specify their use of the builtin FSMonitor.

Signed-off-by: Victoria Dye <vdye@github.com>
This topic branch re-adds the deprecated --stdin/-z options to `git
reset`. Those patches were overridden by a different set of options in
the upstream Git project before we could propose `--stdin`.

We offered this in MinGit to applications that wanted a safer way to
pass lots of pathspecs to Git, and these applications will need to be
adjusted.

Instead of `--stdin`, `--pathspec-from-file=-` should be used, and
instead of `-z`, `--pathspec-file-nul`.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Git for Windows accepts pull requests; Core Git does not. Therefore we
need to adjust the template (because it only matches core Git's
project management style, not ours).

Also: direct Git for Windows enhancements to their contributions page,
space out the text for easy reading, and clarify that the mailing list
is plain text, not HTML.

Signed-off-by: Philip Oakley <philipoakley@iee.org>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Originally introduced as `core.useBuiltinFSMonitor` in Git for Windows
and developed, improved and stabilized there, the built-in FSMonitor
only made it into upstream Git (after unnecessarily long hemming and
hawing and throwing overly perfectionist style review sticks into the
spokes) as `core.fsmonitor = true`.

In Git for Windows, with this topic branch, we re-introduce the
now-obsolete config setting, with warnings suggesting to existing users
how to switch to the new config setting, with the intention to
ultimately drop the patch at some stage.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This is the recommended way on GitHub to describe policies revolving around
security issues and about supported versions.

Helped-by: Sven Strickroth <email@cs-ware.de>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
…updates

Start monitoring updates of Git for Windows' component in the open
Add a README.md for GitHub goodness.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.