Skip to content

Conversation

@dscho
Copy link
Member

@dscho dscho commented Feb 2, 2026

This PR rebases Microsoft Git patches onto Git for Windows v2.53.0.windows.1.

Previous base: vfs-2.53.0-rc2

Range-diff vs vfs-2.53.0-rc2
  • 1: 86df061 = 1: 86df061 sparse-index.c: fix use of index hashes in expand_index
  • 2: fefc6a3 = 2: fefc6a3 t5300: confirm failure of git index-pack when non-idx suffix requested
  • 3: c658d18 = 3: c658d18 t: remove advice from some tests
  • 4: dbb256f = 4: dbb256f t1092: add test for untracked files and directories
  • 5: dce776a = 5: dce776a index-pack: disable rev-index if index file has non .idx suffix
  • 6: 7d16a9d = 6: 7d16a9d trace2: prefetch value of GIT_TRACE2_DST_DEBUG at startup
  • 7: f0d7d71 = 7: f0d7d71 survey: calculate more stats on refs
  • 8: c6732f1 = 8: c6732f1 survey: show some commits/trees/blobs histograms
  • 9: 9a01ec0 = 9: 9a01ec0 survey: add vector of largest objects for various scaling dimensions
  • 10: 4760c34 = 10: 4760c34 survey: add pathname of blob or tree to large_item_vec
  • 11: 5b2382e = 11: 5b2382e survey: add commit-oid to large_item detail
  • 12: 62ae892 = 12: 62ae892 survey: add commit name-rev lookup to each large_item
  • 13: 9a0fa5f = 13: 9a0fa5f survey: add --no-name-rev option
  • 14: 40e319f = 14: 40e319f survey: started TODO list at bottom of source file
  • 15: eaa4225 = 15: eaa4225 survey: expanded TODO list at the bottom of the source file
  • 16: 3b36e9f = 16: 3b36e9f survey: expanded TODO with more notes
  • 17: 3382fe0 = 17: 3382fe0 reset --stdin: trim carriage return from the paths
  • 18: 93d98d3 = 18: 93d98d3 Identify microsoft/git via a distinct version suffix
  • 19: d80e132 = 19: d80e132 gvfs: ensure that the version is based on a GVFS tag
  • 20: 8d027fb = 20: 8d027fb gvfs: add a GVFS-specific header file
  • 21: d35e0a0 = 21: d35e0a0 gvfs: add the core.gvfs config setting
  • 22: 2223a8f = 22: 2223a8f gvfs: add the feature to skip writing the index' SHA-1
  • 23: 2a469cb = 23: 2a469cb gvfs: add the feature that blobs may be missing
  • 24: 96916ed = 24: 96916ed gvfs: prevent files to be deleted outside the sparse checkout
  • 25: 4b425c4 = 25: 4b425c4 gvfs: optionally skip reachability checks/upload pack during fetch
  • 26: 179d73a = 26: 179d73a gvfs: ensure all filters and EOL conversions are blocked
  • 27: 71db03b = 27: 71db03b gvfs: allow "virtualizing" objects
  • 28: 60d9061 = 28: 60d9061 Hydrate missing loose objects in check_and_freshen()
  • 29: 5468fc8 = 29: 5468fc8 sha1_file: when writing objects, skip the read_object_hook
  • 30: e02add1 = 30: e02add1 gvfs: add global command pre and post hook procs
  • 31: 3d9e59d = 31: 3d9e59d t0400: verify that the hook is called correctly from a subdirectory
  • 32: 2e88faf = 32: 2e88faf t0400: verify core.hooksPath is respected by pre-command
  • 33: 964afb6 = 33: 964afb6 Pass PID of git process to hooks.
  • 34: 8e78b14 = 34: 8e78b14 sparse-checkout: make sure to update files with a modify/delete conflict
  • 35: 957acfe = 35: 957acfe worktree: allow in Scalar repositories
  • 36: 35829fb = 36: 35829fb sparse-checkout: avoid writing entries with the skip-worktree bit
  • 37: 35adc66 = 37: 35adc66 Do not remove files outside the sparse-checkout
  • 38: 833cc09 = 38: 833cc09 send-pack: do not check for sha1 file when GVFS_MISSING_OK set
  • 39: 3eb5a18 = 39: 3eb5a18 gvfs: allow corrupt objects to be re-downloaded
  • 40: 73c8e28 = 40: 73c8e28 cache-tree: remove use of strbuf_addf in update_one
  • 41: 697fb7f = 41: 697fb7f gvfs: block unsupported commands when running in a GVFS repo
  • 42: d3622bd = 42: d3622bd gvfs: allow overriding core.gvfs
  • 43: 849952a = 43: 849952a BRANCHES.md: Add explanation of branches and using forks
  • 44: 04a4279 = 44: 04a4279 git.c: add VFS enabled cmd blocking
  • 45: 05930b8 = 45: 05930b8 git.c: permit repack cmd in Scalar repos
  • 46: db181d1 = 46: db181d1 git.c: permit fsck cmd in Scalar repos
  • 47: bda902b = 47: bda902b git.c: permit prune cmd in Scalar repos
  • 48: 3aa39bf = 48: 3aa39bf worktree: remove special case GVFS cmd blocking
  • 49: 2f4a24f = 49: 2f4a24f builtin/repack.c: emit warning when shared cache is present
  • 50: c613103 = 50: c613103 Add virtual file system settings and hook proc
  • 51: c07b680 = 51: c07b680 virtualfilesystem: don't run the virtual file system hook if the index has been redirected
  • 52: 324d6b2 = 52: 324d6b2 virtualfilesystem: check if directory is included
  • 53: 7ab7a6f = 53: 7ab7a6f backwards-compatibility: support the post-indexchanged hook
  • 54: b09e9f2 = 54: b09e9f2 gvfs: verify that the built-in FSMonitor is disabled
  • 55: fe91cbf = 55: fe91cbf wt-status: add trace2 data for sparse-checkout percentage
  • 56: fe812d5 = 56: fe812d5 status: add status serialization mechanism
  • 57: f810223 = 57: f810223 Teach ahead-behind and serialized status to play nicely together
  • 58: b564d90 = 58: b564d90 status: serialize to path
  • 59: 0c415c3 = 59: 0c415c3 status: reject deserialize in V2 and conflicts
  • 60: 9461448 = 60: 9461448 serialize-status: serialize global and repo-local exclude file metadata
  • 61: 7eed69c = 61: 7eed69c status: deserialization wait
  • 62: ba3cd3b = 62: ba3cd3b status: deserialize with -uno does not print correct hint
  • 63: 6fba8d5 = 63: 6fba8d5 fsmonitor: check CE_FSMONITOR_VALID in ce_uptodate
  • 64: fb4e631 = 64: fb4e631 fsmonitor: add script for debugging and update script for tests
  • 65: e123660 = 65: e123660 status: disable deserialize when verbose output requested.
  • 66: 2f7f608 = 66: 2f7f608 t7524: add test for verbose status deserialzation
  • 67: 45f52c8 = 67: 45f52c8 deserialize-status: silently fallback if we cannot read cache file
  • 68: 879597d = 68: 879597d gvfs:trace2:data: add trace2 tracing around read_object_process
  • 69: 450b594 = 69: 450b594 gvfs:trace2:data: status deserialization information
  • 70: a7ba327 = 70: a7ba327 gvfs:trace2:data: status serialization
  • 71: 5a1b23d = 71: 5a1b23d gvfs:trace2:data: add vfs stats
  • 72: 8bc8369 = 72: 8bc8369 trace2: refactor setting process starting time
  • 73: 5f585a1 = 73: 5f585a1 trace2:gvfs:experiment: clear_ce_flags_1
  • 74: 6ad1c3b = 74: 6ad1c3b trace2:gvfs:experiment: report_tracking
  • 75: 6b9ef21 = 75: 6b9ef21 trace2:gvfs:experiment: read_cache: annotate thread usage in read-cache
  • 76: eb0c636 = 76: eb0c636 trace2:gvfs:experiment: read-cache: time read/write of cache-tree extension
  • 77: 3063875 = 77: 3063875 trace2:gvfs:experiment: add region to apply_virtualfilesystem()
  • 78: 0b0daf4 = 78: 0b0daf4 trace2:gvfs:experiment: add region around unpack_trees()
  • 79: df3a88a = 79: df3a88a trace2:gvfs:experiment: add region to cache_tree_fully_valid()
  • 80: 25397da = 80: 25397da trace2:gvfs:experiment: add unpack_entry() counter to unpack_trees() and report_tracking()
  • 81: 97e98b2 = 81: 97e98b2 trace2:gvfs:experiment: increase default event depth for unpack-tree data
  • 82: 5198802 = 82: 5198802 trace2:gvfs:experiment: add data for check_updates() in unpack_trees()
  • 83: 8d3da11 = 83: 8d3da11 Trace2:gvfs:experiment: capture more 'tracking' details
  • 84: 1e3300a = 84: 1e3300a credential: set trace2_child_class for credential manager children
  • 85: d4ddc88 = 85: d4ddc88 sub-process: do not borrow cmd pointer from caller
  • 86: a84e4d8 = 86: a84e4d8 sub-process: add subprocess_start_argv()
  • 87: cacf682 = 87: cacf682 sha1-file: add function to update existing loose object cache
  • 88: 449205c = 88: 449205c index-pack: avoid immediate object fetch while parsing packfile
  • 89: da598b6 = 89: da598b6 gvfs-helper: create tool to fetch objects using the GVFS Protocol
  • 90: 862766a = 90: 862766a sha1-file: create shared-cache directory if it doesn't exist
  • 91: c57566f = 91: c57566f gvfs-helper: better handling of network errors
  • 92: 6370302 = 92: 6370302 gvfs-helper-client: properly update loose cache with fetched OID
  • 93: 32b11fd = 93: 32b11fd gvfs-helper: V2 robust retry and throttling
  • 94: 9be72e3 = 94: 9be72e3 gvfs-helper: expose gvfs/objects GET and POST semantics
  • 95: 1cd2147 = 95: 1cd2147 gvfs-helper: dramatically reduce progress noise
  • 96: 77ad9c3 = 96: 77ad9c3 gvfs-helper: handle pack-file after single POST request
  • 97: d50e835 = 97: d50e835 test-gvfs-prococol, t5799: tests for gvfs-helper
  • 98: 2a4c72f = 98: 2a4c72f gvfs-helper: move result-list construction into install functions
  • 99: 50dbe2d = 99: 50dbe2d t5799: add support for POST to return either a loose object or packfile
  • 100: 3d4cd12 = 100: 3d4cd12 t5799: cleanup wc-l and grep-c lines
  • 101: f0bd1b3 = 101: f0bd1b3 gvfs-helper: verify loose objects after write
  • 102: 81a647e = 102: 81a647e t7599: create corrupt blob test
  • 103: 5f39891 = 103: 5f39891 gvfs-helper: add prefetch support
  • 104: 033b7e2 = 104: 033b7e2 gvfs-helper: add prefetch .keep file for last packfile
  • 105: af78569 = 105: af78569 gvfs-helper: do one read in my_copy_fd_len_tail()
  • 106: 98e672a = 106: 98e672a gvfs-helper: move content-type warning for prefetch packs
  • 107: 954c917 = 107: 954c917 fetch: use gvfs-helper prefetch under config
  • 108: f6cc97b = 108: f6cc97b gvfs-helper: better support for concurrent packfile fetches
  • 109: ad1138b = 109: ad1138b remote-curl: do not call fetch-pack when using gvfs-helper
  • 110: 1e795c2 = 110: 1e795c2 fetch: reprepare packs before checking connectivity
  • 111: f537ef2 = 111: f537ef2 gvfs-helper: retry when creating temp files
  • 112: 099dfc5 = 112: 099dfc5 sparse: avoid warnings about known cURL issues in gvfs-helper.c
  • 113: 88d480d = 113: 88d480d gvfs-helper: add --max-retries to prefetch verb
  • 114: 162bbb4 = 114: 162bbb4 t5799: add tests to detect corrupt pack/idx files in prefetch
  • 115: 2ea9418 = 115: 2ea9418 gvfs-helper: ignore .idx files in prefetch multi-part responses
  • 116: fac0c1d = 116: fac0c1d t5799: explicitly test gvfs-helper --fallback and --no-fallback
  • 117: 6736288 = 117: 6736288 gvfs-helper: don't fallback with new config
  • 118: 2ea0b9c = 118: 2ea0b9c test-gvfs-protocol: add cache_http_503 to mayhem
  • 119: b93cde8 = 119: b93cde8 maintenance: care about gvfs.sharedCache config
  • 120: 61ba050 = 120: 61ba050 t5799: add unit tests for new gvfs.fallback config setting
  • 121: 4205df8 = 121: 4205df8 unpack-trees:virtualfilesystem: Improve efficiency of clear_ce_flags
  • 122: ffd9a27 = 122: ffd9a27 homebrew: add GitHub workflow to release Cask
  • 123: ae2d05a = 123: ae2d05a Adding winget workflows
  • 124: 6e7bed2 = 124: 6e7bed2 Disable the monitor-components workflow in msft-git
  • 125: ee2bb4c = 125: ee2bb4c .github: enable windows builds on microsoft fork
  • 126: 8a1c992 = 126: 8a1c992 .github/actions/akv-secret: add action to get secrets
  • 127: 6a07891 = 127: 6a07891 release: create initial Windows installer build workflow
  • 128: 1043f5d = 128: 1043f5d release: create initial Windows installer build workflow
  • 129: 36ee5ae = 129: 36ee5ae help: special-case HOST_CPU universal
  • 130: ca989aa = 130: ca989aa release: add Mac OSX installer build
  • 131: 24af6b1 = 131: 24af6b1 release: build unsigned Ubuntu .deb package
  • 132: 23c3155 = 132: 23c3155 release: add signing step for .deb package
  • 133: 8728856 = 133: 8728856 release: create draft GitHub release with packages & installers
  • 134: 1091381 = 134: 1091381 build-git-installers: publish gpg public key
  • 135: b8905fb = 135: b8905fb update-microsoft-git: create barebones builtin
  • 136: bd04c93 = 136: bd04c93 release: continue pestering until user upgrades
  • 137: 0998979 = 137: 0998979 update-microsoft-git: Windows implementation
  • 138: 86b01f7 = 138: 86b01f7 dist: archive HEAD instead of HEAD^{tree}
  • 139: c6d0349 = 139: c6d0349 update-microsoft-git: use brew on macOS
  • 140: 361f14d = 140: 361f14d release: include GIT_BUILT_FROM_COMMIT in MacOS build
  • 141: e53c027 = 141: e53c027 .github: reinstate ISSUE_TEMPLATE.md for microsoft/git
  • 142: a69a1e5 = 142: a69a1e5 release: add installer validation
  • 143: 1bace05 = 143: 1bace05 git_config_set_multivar_in_file_gently(): add a lock timeout
  • 144: 029f035 = 144: 029f035 .github: update PULL_REQUEST_TEMPLATE.md
  • 145: bac336a = 145: bac336a scalar: set the config write-lock timeout to 150ms
  • 146: 2bf835a = 146: 2bf835a Adjust README.md for microsoft/git
  • 147: 67a6b9f = 147: 67a6b9f scalar: add docs from microsoft/scalar
  • 148: b21a1c4 = 148: b21a1c4 scalar (Windows): use forward slashes as directory separators
  • 149: f56e663 = 149: f56e663 scalar: add retry logic to run_git()
  • 150: c766b75 = 150: c766b75 scalar: support the config command for backwards compatibility
  • 151: 58504f9 = 151: 58504f9 scalar: implement a minimal JSON parser
  • 152: 4c5040e = 152: 4c5040e scalar clone: support GVFS-enabled remote repositories
  • 153: 32e5100 = 153: 32e5100 test-gvfs-protocol: also serve smart protocol
  • 154: d74a871 = 154: d74a871 gvfs-helper: add the endpoint command
  • 155: e96e2fe = 155: e96e2fe dir_inside_of(): handle directory separators correctly
  • 156: 92095ba = 156: 92095ba scalar: disable authentication in unattended mode
  • 157: 5450a84 = 157: 5450a84 abspath: make strip_last_path_component() global
  • 158: ac2b69b = 158: ac2b69b scalar: do initialize gvfs.sharedCache
  • 159: c9e2213 = 159: c9e2213 scalar diagnose: include shared cache info
  • 160: ee6ba33 = 160: ee6ba33 scalar: only try GVFS protocol on https:// URLs
  • 161: 7553206 = 161: 7553206 scalar: verify that we can use a GVFS-enabled repository
  • 162: e275b20 = 162: e275b20 scalar: add the cache-server command
  • 163: 6c92bd0 = 163: 6c92bd0 scalar: add a test toggle to skip accessing the vsts/info endpoint
  • 164: bf8559e = 164: bf8559e scalar: adjust documentation to the microsoft/git fork
  • 165: 45587ad = 165: 45587ad scalar: enable untracked cache unconditionally
  • 166: 90dd436 = 166: 90dd436 scalar: parse clone --no-fetch-commits-and-trees for backwards compatibility
  • 167: 5370e99 = 167: 5370e99 scalar: make GVFS Protocol a forced choice
  • 168: 9d8a5b7 = 168: 9d8a5b7 scalar: work around GVFS Protocol HTTP/2 failures
  • 169: c3710cb = 169: c3710cb gvfs-helper-client: clean up server process(es)
  • 170: 7c4cbb7 = 170: 7c4cbb7 scalar diagnose: accommodate Scalar's Functional Tests
  • 171: 01b291b = 171: 01b291b ci: run Scalar's Functional Tests
  • 172: 2f43f0c = 172: 2f43f0c scalar: upgrade to newest FSMonitor config setting
  • 173: 8c34cee = 173: 8c34cee add/rm: allow adding sparse entries when virtual
  • 174: 744e1fd = 174: 744e1fd sparse-checkout: add config to disable deleting dirs
  • 175: 099e21c = 175: 099e21c diff: ignore sparse paths in diffstat
  • 176: 9de6ee2 = 176: 9de6ee2 repo-settings: enable sparse index by default
  • 177: 806dd76 = 177: 806dd76 TO-UPSTREAM: sequencer: avoid progress when stderr is redirected
  • 178: 302cf18 = 178: 302cf18 TO-CHECK: t1092: use quiet mode for rebase tests
  • 179: f0db70a = 179: f0db70a reset: fix mixed reset when using virtual filesystem
  • 180: 5036bd9 = 180: 5036bd9 diff(sparse-index): verify with partially-sparse
  • 181: 0fb283a = 181: 0fb283a stash: expand testing for git stash -u
  • 182: c067f45 = 182: c067f45 sparse-index: add ensure_full_index_with_reason()
  • 183: 356dcf6 = 183: 356dcf6 treewide: add reasons for expanding index
  • 184: 7d42e02 = 184: 7d42e02 treewide: custom reasons for expanding index
  • 185: e9f022d = 185: e9f022d sparse-index: add macro for unaudited expansions
  • 186: d3f09e8 = 186: d3f09e8 Docs: update sparse index plan with logging
  • 187: 5df2aa6 = 187: 5df2aa6 sparse-index: log failure to clear skip-worktree
  • 188: c708938 = 188: c708938 stash: use -f in checkout-index child process
  • 189: 9ed0f66 = 189: 9ed0f66 sparse-index: do not copy hashtables during expansion
  • 190: 08c277f = 190: 08c277f TO-UPSTREAM: sub-process: avoid leaking cmd
  • 191: 272a883 = 191: 272a883 remote-curl: release filter options before re-setting them
  • 192: 8bc18b8 = 192: 8bc18b8 transport: release object filter options
  • 193: 4d1ed62 = 193: 4d1ed62 push: don't reuse deltas with path walk
  • 194: 5ed2aa6 = 194: 5ed2aa6 t7900-maintenance.sh: reset config between tests
  • 195: d14a4e1 = 195: d14a4e1 maintenance: add cache-local-objects maintenance task
  • 196: f9d7b0f = 196: f9d7b0f scalar.c: add cache-local-objects task
  • 197: ea3183f = 197: ea3183f hooks: add custom post-command hook config
  • 198: 5bf6524 = 198: 5bf6524 TO-UPSTREAM: Docs: fix asciidoc failures from short delimiters
  • 199: f312823 = 199: f312823 hooks: make hook logic memory-leak free
  • 200: cf2d0f0 = 200: cf2d0f0 t0401: test post-command for alias, version, typo
  • 201: befed98 = 201: befed98 cat_one_file(): make it easy to see that the size variable is initialized
  • 202: e3f22db = 202: e3f22db hooks: better handle config without gitdir
  • 203: 2c9d815 = 203: 2c9d815 revision: defensive programming
  • 204: 8b69a02 = 204: 8b69a02 get_parent(): defensive programming
  • 205: 6bc2de5 = 205: 6bc2de5 fetch-pack: defensive programming
  • 206: 97ac426 = 206: 97ac426 unparse_commit(): defensive programming
  • 207: 79a4ea8 = 207: 79a4ea8 verify_commit_graph(): defensive programming
  • 208: a1f754e = 208: a1f754e stash: defensive programming
  • 209: a0ebf6a = 209: a0ebf6a fsck: avoid using an uninitialized variable
  • 210: 41fb78a = 210: 41fb78a stash: defensive programming
  • 211: 289dbc4 = 211: 289dbc4 load_revindex_from_disk(): avoid accessing uninitialized data
  • 212: c0d57cc = 212: c0d57cc push: defensive programming
  • 213: 92772a9 = 213: 92772a9 load_pack_mtimes_file(): avoid accessing uninitialized data
  • 214: 9249823 = 214: 9249823 codeql: run static analysis as part of CI builds
  • 215: 44142f3 = 215: 44142f3 codeql: publish the sarif file as build artifact
  • 216: e5e3223 = 216: e5e3223 fetch: silence a CodeQL alert about a local variable's address' use after release
  • 217: add0d88 = 217: add0d88 codeql: disable a couple of non-critical queries for now
  • 218: fb7686f = 218: fb7686f test-tool repository: check return value of lookup_commit()
  • 219: 43beeba = 219: 43beeba date: help CodeQL understand that there are no leap-year issues here
  • 220: e813fa6 = 220: e813fa6 fetch: defensive programming
  • 221: 9b037ec = 221: 9b037ec shallow: handle missing shallow commits gracefully
  • 222: f1282a7 = 222: f1282a7 help: help CodeQL understand that consuming envvars is okay here
  • 223: 4dc0581 = 223: 4dc0581 inherit_tracking(): defensive programming
  • 224: ddc921e = 224: ddc921e commit-graph: suppress warning about using a stale stack addresses
  • 225: 1934ab4 = 225: 1934ab4 ctype: help CodeQL understand that sane_istest() does not access array past end
  • 226: 4262b4f = 226: 4262b4f ctype: accommodate for CodeQL misinterpreting the z in mallocz()
  • 227: 84adeba = 227: 84adeba strbuf_read: help with CodeQL misunderstanding that strbuf_read() does NUL-terminate correctly
  • 228: c08dd96 = 228: c08dd96 codeql: also check JavaScript code
  • 229: 09b63e7 = 229: 09b63e7 scalar: add run_git_argv
  • 230: d9c3a48 = 230: d9c3a48 scalar: add --ref-format option to scalar clone
  • 231: f9555a6 = 231: f9555a6 gvfs-helper: skip collision check for loose objects
  • 232: ac9ff33 = 232: ac9ff33 gvfs-helper: emit advice on transient errors
  • 233: fccfc8a = 233: fccfc8a gvfs-helper: avoid collision check for packfiles
  • 234: 71de75d = 234: 71de75d t5799: update cache-server methods for multiple instances
  • 235: 03d0f70 = 235: 03d0f70 gvfs-helper: override cache server for prefetch
  • 236: 0caeebb = 236: 0caeebb gvfs-helper: override cache server for get
  • 237: 593b3b8 = 237: 593b3b8 gvfs-helper: override cache server for post
  • 238: 1b04e60 = 238: 1b04e60 t5799: add test for all verb-specific cache-servers together
  • 239: 4d10ff3 = 239: 4d10ff3 lib-gvfs-helper: create helper script for protocol tests
  • 240: 8dc9f67 = 240: 8dc9f67 t579*: split t5799 into several parts
  • 241: c041754 = 241: c041754 fixup! survey: show some commits/trees/blobs histograms
  • 242: 8061078 = 242: 8061078 fixup! gvfs-helper: create tool to fetch objects using the GVFS Protocol
  • 243: 10c5baa = 243: 10c5baa fixup! gvfs-helper: create tool to fetch objects using the GVFS Protocol
  • 244: 1599a75 = 244: 1599a75 fixup! release: add Mac OSX installer build
  • 245: 1713b8c = 245: 1713b8c osxkeychain: always apply required build flags
  • 246: 4bb0c56 = 246: 4bb0c56 fixup! release: add Mac OSX installer build
  • 247: bcb773f = 247: bcb773f fixup! survey: show some commits/trees/blobs histograms

derrickstolee and others added 30 commits February 2, 2026 19:59
In earlier versions of `microsoft/git`, we found a user who had set
`core.gvfs = false` in their global config. This should not have been
necessary, but it also should not have caused a problem. However, it
did.

The reason was that `gvfs_load_config_value()` was called from
`config.c` when reading config key/value pairs from all the config
files. The local config should override the global config, and this is
done by `config.c` reading the global config first then reading the
local config. However, our logic only allowed writing the `core_gvfs`
variable once.

In v2.51.0, we had to adapt to upstream changes that changed way the
`core.gvfs` config value is read, and the special handling is no longer
necessary, yet we still want the test case that ensures that this bug
does not experience a regression.

Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Replace the special casing of the `worktree` command being blocked on
VFS-enabled repos with the new `BLOCK_ON_VFS_ENABLED` flag.

Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
Emit a warning message when the `gvfs.sharedCache` option is set that
the `repack` command will not perform repacking on the shared cache.

In the future we can teach `repack` to operate on the shared cache, at
which point we can drop this commit.

Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
On index load, clear/set the skip worktree bits based on the virtual
file system data. Use virtual file system data to update skip-worktree
bit in unpack-trees. Use virtual file system data to exclude files and
folders not explicitly requested.

Update 2022-04-05: disable the "present-despite-SKIP_WORKTREE" file removal
behavior when 'core.virtualfilesystem' is enabled.

Signed-off-by: Ben Peart <benpeart@microsoft.com>
…x has been redirected

Fixes #13

Some git commands spawn helpers and redirect the index to a different
location.  These include "difftool -d" and the sequencer
(i.e. `git rebase -i`, `git cherry-pick` and `git revert`) and others.
In those instances we don't want to update their temporary index with
our virtualization data.

Helped-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Ben Peart <Ben.Peart@microsoft.com>
Add check to see if a directory is included in the virtualfilesystem
before checking the directory hashmap.  This allows a directory entry
like foo/ to find all untracked files in subdirectories.
When our patches to support that hook were upstreamed, the hook's name
was eliciting some reviewer suggestions, and it was renamed to
`post-index-change`. These patches (with the new name) made it into
v2.22.0.

However, VFSforGit users may very well have checkouts with that hook
installed under the original name.

To support this, let's just introduce a hack where we look a bit more
closely when we just failed to find the `post-index-change` hook, and
allow any `post-indexchanged` hook to run instead (if it exists).
Teach STATUS to optionally serialize the results of a
status computation to a file.

Teach STATUS to optionally read an existing serialization
file and simply print the results, rather than actually
scanning.

This is intended for immediate status results on extremely
large repos and assumes the use of a service/daemon to
maintain a fresh current status snapshot.

2021-10-30: packet_read() changed its prototype in ec9a37d (pkt-line.[ch]:
remove unused packet_read_line_buf(), 2021-10-14).

2021-10-30: sscanf() now does an extra check that "%d" goes into an "int"
and complains about "uint32_t". Replacing with "%u" fixes the compile-time
error.

2021-10-30: string_list_init() was removed by abf897b (string-list.[ch]:
remove string_list_init() compatibility function, 2021-09-28), so we need to
initialize manually.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
When using a virtual file system layer, the FSMonitor does not make
sense.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
When sparse-checkout is enabled, add the sparse-checkout percentage to
the Trace2 data stream.  This number was already computed and printed
on the console in the "You are in a sparse checkout..." message.  It
would be helpful to log it too for performance monitoring.

Signed-off-by: Jeff Hostetler <jeffhostetler@github.com>
Teach status serialization to take an optional pathname on
the command line to direct that cache data be written there
rather than to stdout.  When used this way, normal status
results will still be written to stdout.

When no path is given, only binary serialization data is
written to stdout.

Usage:
    git status --serialize[=<path>]

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Teach status deserialize code to reject status cache
when printing in porcelain V2 and there are unresolved
conflicts in the cache file.  A follow-on task might
extend the cache format to include this additiona data.

See code for longer explanation.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Changes to the global or repo-local excludes files can change the
results returned by "git status" for untracked files.  Therefore,
it is important that the exclude-file values used during serialization
are still current at the time of deserialization.

Teach "git status --serialize" to report metadata on the user's global
exclude file (which defaults to "$XDG_HOME/git/ignore") and for the
repo-local excludes file (which is in ".git/info/excludes").  Serialize
will record the pathnames and mtimes for these files in the serialization
header (next to the mtime data for the .git/index file).

Teach "git status --deserialize" to validate this new metadata.  If either
exclude file has changed since the serialization-cache-file was written,
then deserialize will reject the cache file and force a full/normal status
run.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Teach `git status --deserialize` to either wait indefintely
or immediately fail if the status serialization cache file
is stale.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
With the "--untracked-files=complete" option status computes a
superset of the untracked files.  We use this when writing the
status cache.  If subsequent deserialize commands ask for either
the complete set or one of the "no", "normal", or "all" subsets,
it can still use the cache file because of filtering in the
deserialize parser.

When running status with the "-uno" option, the long format
status would print a "(use -u to show untracked files)" hint.

When deserializing with the "-uno" option and using a cache computed
with "-ucomplete", the "nothing to commit, working tree clean" message
would be printed instead of the hint.

It was easy to miss because the correct hint message was printed
if the cache was rejected for any reason (and status did the full
fallback).

The "struct wt_status des" structure was initialized with the
content of the status cache (and thus defaulted to "complete").
This change sets "des.show_untracked_files" to the requested
subset from the command-line or config.  This allows the long
format to print the hint.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
When using fsmonitor the CE_FSMONITOR_VALID flag should be checked when
wanting to know if the entry has been updated. If the flag is set the
entry should be considered up to date and the same as if the CE_UPTODATE
is set.

In order to trust the CE_FSMONITOR_VALID flag, the fsmonitor data needs to
be refreshed when the fsmonitor bitmap is applied to the index in
tweak_fsmonitor. Since the fsmonitor data is kept up to date for every
command, some tests needed to be updated to take that into account.

istate->untracked->use_fsmonitor was set in tweak_fsmonitor when the
fsmonitor bitmap data was loaded and is now in refresh_fsmonitor since
that is being called in tweak_fsmonitor. refresh_fsmonitor will only be
called once and any other callers should be setting it when refreshing
the fsmonitor data so that code can use the fsmonitor data when checking
untracked files.

When writing the index, fsmonitor_last_update is used to determine if
the fsmonitor bitmap should be created and the extension data written to
the index. When running through unpack-trees this is not copied to the
result index. This makes the next time a git command is ran do all the
work of lstating all files to determine what is clean since all entries
in the index are marked as dirty since there wasn't any fsmonitor data
saved in the index extension.

Copying the fsmonitor_last_update to the result index will cause the
extension data for fsmonitor to be in the index for the next git command
to use.

Signed-off-by: Kevin Willford <Kevin.Willford@microsoft.com>
The fsmonitor script that can be used for running all the git tests
using watchman was causing some of the tests to fail because it wrote
to stderr and created some files for debugging purposes.

Add a new debug script to use with debugging and modify the other script
to remove the code that would cause tests to fail.

Signed-off-by: Kevin Willford <Kevin.Willford@microsoft.com>
Disable deserialization when verbose output requested.

Verbose mode causes Git to print diffs for modified files.
This requires the index to be loaded to have the currently
staged OID values.  Without loading the index, verbose output
make it look like everything was deleted.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Verify that `git status --deserialize=x -v` does not crash and
generates the same output as a normal (scanning) status command.

These issues are described in the previous 2 commits.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Add trace2 region around read_object_process to collect
time spent waiting for missing objects to be dynamically
fetched.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Add trace2 region and data events describing attempts to deserialize
status data using a status cache.

A category:status, label:deserialize region is pushed around the
deserialize code.

Deserialization results when reading from a file are:
    category:status, path   = <path>
    category:status, polled = <number_of_attempts>
    category:status, result = "ok" | "reject"

When reading from STDIN are:
    category:status, path   = "STDIN"
    category:status, result = "ok" | "reject"

Status will fallback and run a normal status scan when a "reject"
is reported (unless "--deserialize-wait=fail").

If "ok" is reported, status was able to use the status cache and
avoid scanning the workdir.

Additionally, a cmd_mode is emitted for each step: collection,
deserialization, and serialization.  For example, if deserialization
is attempted and fails and status falls back to actually computing
the status, a cmd_mode message containing "deserialize" is issued
and then a cmd_mode for "collect" is issued.

Also, if deserialization fails, a data message containing the
rejection reason is emitted.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Add trace information around status serialization.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Report virtual filesystem summary data.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Create trace2_initialize_clock() and call from main() to capture
process start time in isolation and before other sub-systems are
ready.

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Add trace2_thread_start() and trace2_thread_exit() events to the worker
threads used to read the index.  This gives per-thread perf data.

These workers were introduced in:
abb4bb8 read-cache: load cache extensions on a worker thread
77ff112 read-cache: load cache entries on worker threads

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
…ension

Add regions around code to read and write the cache-tree extension
when the index is read or written.

This is an experiment and may be dropped in future releases if
we don't need it anymore.

This experiment demonstrates that it takes more time to parse and
deserialize the cache-tree extension than it does to read the
cache-entries.

Commits [1] and [2] spreads cache-entry reading across N-1 cores
and dedicates a single core to simultaneously read the index extensions.

Local testing (on my machine) shows that reading the cache-tree extension
takes ~0.28 seconds.  The 11 cache-entry threads take ~0.08 seconds.
The main thread is blocked for 0.15 to 0.20 seconds waiting for the
extension thread to finish.

Let's use this commit to gather some telemetry and confirm this.

My point is that improvements, such as index V5 which makes the
cache entries smaller, may improve performance, but the gains may
be limited because of this extension.  And that we may need to
look inside the cache-tree extension to truly improve do_read_index()
performance.

[1] abb4bb8 read-cache: load cache extensions on a worker thread
[2] 77ff112 read-cache: load cache entries on worker threads

Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
dscho and others added 26 commits February 2, 2026 20:00
This patch series has been long in the making, ever since Johannes
Nicolai and myself spiked this in November/December 2020.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
The microsoft/git fork includes pre- and post-command hooks, with the
initial intention of using these for VFS for Git. In that environment,
these are important hooks to avoid concurrent issues when the
virtualization is incomplete.

However, in the Office monorepo the post-command hook is used in a
different way. A custom hook is used to update the sparse-checkout, if
necessary. To avoid this hook from being incredibly slow on every Git
command, this hook checks for the existence of a "sentinel file" that is
written by a custom post-index-change hook and no-ops if that file does
not exist.

However, even this "no-op" is 200ms due to the use of two scripts (one
simple script in .git/hooks/ does some environment checking and then
calls a script from the working directory which actually contains the
logic).

Add a new config option, 'postCommand.strategy', that will allow for
multiple possible strategies in the future. For now, the one we are
adding is 'post-index-change' which states that we should write a
sentinel file instead of running the 'post-index-change' hook and then
skip the 'post-command' hook if the proper sentinel file doesn't exist.
(If it does exist, then delete it and run the hook.)

--- 

This fork contains changes specific to monorepo scenarios. If you are an
external contributor, then please detail your reason for submitting to
this fork:

* [ ] This is an early version of work already under review upstream.
* [ ] This change only applies to interactions with Azure DevOps and the
      GVFS Protocol.
* [ ] This change only applies to the virtualization hook and VFS for
Git.
* [x] This change only applies to custom bits in the microsoft/git fork.
This patch series has been long in the making, ever since Johannes
Nicolai and myself spiked this in November/December 2020.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
When we are installing a loose object, finalize_object_file() first
checks to see if the contents match what already exists in a loose
object file of the target name. However, this doesn't check if the
target is valid, it assumes the target is valid.

However, in the case of a power outage or something like that, the file
may be corrupt (for example: all NUL bytes). That is a common occurrence
when we are needing to install a loose object _again_: we don't think we
have it already so any copy that exists is probably bogus.

Use the flagged version with FOF_SKIP_COLLISION_CHECK to avoid these
types of errors, as seen in GitHub issue
microsoft#837.

Signed-off-by: Derrick Stolee <stolee@gmail.com>
Add ability to run Git commands for Scalar by passing a struct strvec
rather than having to use varargs.

Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
Users sometimes see transient network errors, but they are actually due
to some other problem within the installation of a packfile. Observed
resolutions include freeing up space on a full disk or deleting the
shared object cache because something was broken due to a file
corruption or power outage.

This change only provides the advice to suggest those workarounds to
help users help themselves.

This is our first advice custom to the microsoft/git fork, so I have
partitioned the key away from the others to avoid adjacent change
conflicts (at least until upstream adds a new change at the end of the
alphabetical list).

We could consider providing a tool that does a more robust check of the
shared object cache, but since 'git fsck' isn't safe to run as it may
download missing objects, we do not have that ability at the moment.

The good news is that it is safe to delete and rebuild the shared object
cache as long as all local branches are pushed. The branches must be
pushed because the local .git/objects/ directory is moved to the shared
object cache in the 'cache-local-objects' maintenance task.

Signed-off-by: Derrick Stolee <stolee@gmail.com>
Add the `--ref-format` option to the `scalar clone` command. This will
allow users to opt-in to creating a Scalar repository using alternative
ref storage backends, such as reftable. Example:

  scalar clone --ref-format reftable $URL

Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
Similar to a recent change to avoid the collision check for loose
objects, do the same for prefetch packfiles. This should be more rare,
but the same prefetch packfile could be downloaded from the same cache
server so this isn't out of the range of possibility.

Signed-off-by: Derrick Stolee <stolee@gmail.com>
…-for-windows#832)

Add the `--ref-format` option to the `scalar clone` command. This will allow users to opt-in to creating a Scalar repository using alternative ref storage backends, such as reftable. Example:

```shell
scalar clone --ref-format reftable $URL
```
In anticipation of tests for multiple cache-servers, update the existing
logic that sets up and tears down cache-servers to allow multiple instances
on different ports.

Signed-off-by: Derrick Stolee <stolee@gmail.com>
…ed object cache (git-for-windows#840)

There have been a number of customer-reported problems with errors of
the form

```
error: inflate: data stream error (unknown compression method)
error: unable to unpack a163b1302d4729ebdb0a12d3876ca5bca4e1a8c3 header
error: files 'D:/.scalarCache/id_49b0c9f4-555f-4624-8157-a57e6df513b3/pack/tempPacks/t-20260106-014520-049919-0001.temp' and 'D:/.scalarCache/id_49b0c9f4-555f-4624-8157-a57e6df513b3/a1/63b1302d4729ebdb0a12d3876ca5bca4e1a8c3' differ in contents
error: gvfs-helper error: 'could not install loose object 'D:/.scalarCache/id_49b0c9f4-555f-4624-8157-a57e6df513b3/a1/63b1302d4729ebdb0a12d3876ca5bca4e1a8c3': from GET a163b1302d4729ebdb0a12d3876ca5bca4e1a8c3'
```

or 

```
Receiving packfile 1/1 with 1 objects (bytes received): 17367934, done.
Receiving packfile 1/1 with 1 objects [retry 1/6] (bytes received): 17367934, done.
Waiting to retry after network error (sec): 100% (8/8), done.
Receiving packfile 1/1 with 1 objects [retry 2/6] (bytes received): 17367934, done.
Waiting to retry after network error (sec): 100% (16/16), done.
Receiving packfile 1/1 with 1 objects [retry 3/6] (bytes received): 17367934, done.
```

These are not actually due to network issues, but they look like it
based on the stack that is doing retries. Instead, these actually have
problems when installing the loose object or packfile into the shared
object cache.

The loose objects are hitting issues when installing and the target
loose object is corrupt in some way, such as all NUL bytes because the
disk wasn't flushed when the machine shut down. The error results
because we are doing a collision check without confirming that the
existing contents are valid.

The packfiles may be hitting similar comparison cases, but it is less
likely. We update these packfile installations to also skip the
collision check.

In both cases, if we have a transient network error, we add a new advice
message that helps users with the two most common workarounds:

1. Your disk may be full. Make room.
2. Your shared object cache may be corrupt. Push all branches, delete
it, and fetch to refill it.

I make special note of when the shared object cache doesn't exist and
point that it probably should so the whole repo is suspect at that
point.

* [X] This change only applies to interactions with Azure DevOps and the
      GVFS Protocol.

Resolves git-for-windows#837.
This extension of the gvfs.cache-server config now allows a new key,
gvfs.prefetch.cache-server, to override the cache-server URL for only
the prefetch endpoint.

The purpose of this config is to allow for incremental testing and
deployment of new cache-server infrastructure. Hypothetically, we could
have special-purpose cache-servers that are glorified bundle servers and
other servers that focus on the object and size endpoints.

More realistically, this will allow us to test cache servers that have
only the prefetch endpoint ready to go. This allows some incremental
rollout that is more controlled than a flag day replacing the entire
infrastructure.

Signed-off-by: Derrick Stolee <stolee@gmail.com>
This extension of the gvfs.cache-server config now allows a new key,
gvfs.get.cache-server, to override the cache-server URL for only the
prefetch endpoint.

The purpose of this config is to allow for incremental testing and
deployment of new cache-server infrastructure.

Signed-off-by: Derrick Stolee <stolee@gmail.com>
This extension of the gvfs.cache-server config now allows a new key,
gvfs.post.cache-server, to overrid the cache-server URL for only the
batched objects endpoint.

The purpose of this config is to allow for incremental testing and
deployment of new cache-server infrastructure.

Signed-off-by: Derrick Stolee <stolee@gmail.com>
Test that all three verb-specific cache-server configs can be used
simultaneously, each directing requests to a different server. This
verifies that prefetch, get, and post verbs each respect their own
override and don't interfere with each other.
The t5799-gvfs-helper.sh script is long and takes forever. This slows down
PR merges and the local development inner loop is a pain. Before
distributing the tests into a set of new test scripts by topic, extract
important helper methods that can be imported by the new scripts.

Signed-off-by: Derrick Stolee <stolee@gmail.com>
Move the tests from t5799-gvfs-helper.sh into multiple scripts that can run
in parallel. To ensure that the ports do not overlap, add a large multiplier
on the instance when needing multiple ports within the same test (currently
limited to the verb-specific cache servers).

Signed-off-by: Derrick Stolee <stolee@gmail.com>
…or-windows#836)

I'm exploring ideas around a new cache-server infrastructure. One of the
trickiest parts of deploying new infrastructure is the need to have all
endpoints ready to go at launch without incremental learning.

This change adds new `gvfs.<verb>.cache-server` config keys that allow
for verb-by-verb overrides of the typical `gvfs.cache-server` config
key. These are loaded on a per-verb basis and then reset after the
request. Further, if there is a failure then the request is retried with
the base cache-server URL.

This would allow us to, for example, deploy a service that serves only
the `gvfs/prefetch` endpoint and see if that is improving on latency and
throughput expectations before moving on to the GET and POST verbs for
single and batched object downloads.

As I was adding tests, I realized that we should split this test script
into distinct parts so we can have a faster inner loop when testing
specific areas. I know that this script is frequently the longest script
running in our PR and CI builds, so the parallel split should help
significantly.

Use commit-by-commit review. I tried to keep the last two commits as
obviously "copy-and-paste only" except for a small change to the port
calculation to avoid overlap when using multiple ports in parallel
tests.

* [X] This change only applies to interactions with Azure DevOps and the
      GVFS Protocol.
The `OI_DBCACHED` flag was removed in 7a4bd1b (packfile: always
declare object info to be OI_PACKED, 2026-01-12). The commit message
suggests to use the `is_delta` flag instead, but that is only
populated if `OBJECT_INFO_QUICK` isn't passed (which is part of
`OBJECT_INFO_FOR_PREFETCH`, which we use here).

At the same time, no caller ever looked at the `cnt_dbcached` count. So
let's just remove it.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This is needed because of 84f0e60 (packfile: move packfile store
into object source, 2026-01-09).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
The v2.53.0-rc0.vfs.0.0 build began failing with:

    Undefined symbols for architecture arm64:
      "_iconv", referenced from:
          __libintl_find_msg in libintl.a[arm64][13](dcigettext.o)
      "_iconv_open", referenced from:
          __libintl_find_msg in libintl.a[arm64][13](dcigettext.o)
    ld: symbol(s) not found for architecture arm64

See https://github.com/microsoft/git/actions/runs/21450597958 for the
failing run. The previous release v2.52.0.vfs.0.5 built successfully on
January 24, 2026 (https://github.com/microsoft/git/actions/runs/21313971421).

The root cause is upstream commit cee341e ("macOS: use iconv from
Homebrew if needed and present", 2025-12-24), which was included in Git
v2.53.0-rc0 to work around an iconv bug in macOS 15.7.2. That commit
introduced USE_HOMEBREW_LIBICONV, which config.mak.uname now sets on
Darwin 24+, causing the Makefile to add Homebrew's libiconv to the
linker search path.

The problem is a symbol name mismatch: Homebrew's libiconv exports
symbols with a prefix (_libiconv, _libiconv_open) to avoid conflicting
with the system library, but Homebrew's gettext/libintl was built
against the system iconv which uses unprefixed symbols (_iconv,
_iconv_open). When building universal binaries, the linker finds
Homebrew's libiconv first and cannot resolve the symbols libintl needs.

The fix is to explicitly unset USE_HOMEBREW_LIBICONV and ICONVDIR in
config.mak, forcing the linker to use the system's /usr/lib/libiconv.dylib
which is already universal and exports the correct unprefixed symbols.

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Starting with upstream commit 4580bcd ("osxkeychain: avoid
incorrectly skipping store operation", 2025-11-14), the osxkeychain
credential helper includes git-compat-util.h and links against
libgit.a.

The osxkeychain Makefile has:

    CFLAGS ?= -g -O2 -Wall -I../../.. $(BASIC_CFLAGS)

The ?= operator means "set only if not already set". When building
via a parent Makefile that passes CFLAGS on the command line, this
entire assignment is ignored - including the -I../../.. needed to find
git-compat-util.h and the $(BASIC_CFLAGS) needed for -DNO_OPENSSL:

    git-credential-osxkeychain.c:5:10: fatal error:
        'git-compat-util.h' file not found

Using += instead of ?= is not sufficient either, because command-line
variables in Make override even += assignments. We need to use
"override CFLAGS +=" to force these flags to be appended regardless
of how CFLAGS was set.

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Starting with upstream commit 4580bcd ("osxkeychain: avoid
incorrectly skipping store operation", 2025-11-14), the osxkeychain
credential helper includes git-compat-util.h. That header includes
openssl/ssl.h unless -DNO_OPENSSL is defined:

    ../../../git-compat-util.h:199:10: fatal error:
        'openssl/ssl.h' file not found

On macOS, the main Makefile sets NO_OPENSSL (because Apple Common
Crypto is used instead) and adds -DNO_OPENSSL to BASIC_CFLAGS. But
contrib Makefiles that only include config.mak* files don't get this
logic - they only see the variables, not the Makefile rules that
convert NO_OPENSSL into -DNO_OPENSSL.

Add -DNO_OPENSSL to BASIC_CFLAGS in config.mak so that contrib builds
like osxkeychain can pick it up.

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
The previous fixup for 84f0e60 (packfile: move packfile store
into object source, 2026-01-09) was incorrect.

That upstream commit moved the packfile store from being a single
global store in `struct object_database` to being per-source in
`struct odb_source`. The previous fixup adapted the
`packfile_store_reprepare()` call by changing:

    the_repository->objects->packfiles

to:

    the_repository->objects->sources->packfiles

However, this only reprepares the packfile store of the *first*
source in the linked list. This is incorrect because GVFS-helper
writes downloaded objects to `gh_client__chosen_odb`, which is
typically the shared cache alternate (configured via
`gvfs.sharedCache`), not the primary .git/objects directory.

When objects are downloaded into the shared cache but only the
primary source's packfile store is reprepared, the newly created
packfiles remain invisible to subsequent object lookups. This causes
the object lookup code in odb.c to fall through to the expensive
`gh_client__get_immediate()` path, re-fetching objects that were
already successfully downloaded via the batched queue mechanism.

The test t5793.3 "integration: fully implicit: diff 2 commits"
caught this regression. It verifies that blob objects are fetched
via the efficient batched queue path (`gh_client__queue_oid`) and
NOT via the single-object immediate path (`gh_client__get_immediate`).
With the broken fixup, objects were being fetched twice: once via
the queue (correct), and then again via immediate fetch (incorrect)
because the packfile store for the shared cache was never reprepared.

Fix this by repreparing the packfile store of the actual chosen ODB
where objects are written:

    gh_client__chosen_odb->packfiles

This variable is guaranteed to be set before
`gh_client__objects__receive_response()` is called, since all
callers go through `gh_client__find_long_running_process()` which
calls `gh_client__choose_odb()` first.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This includes the fixes I had to make to get
https://github.com/microsoft/git/releases/tag/v2.53.0-rc0.vfs.0.0 to
build, plus a fix for an overlooked stale `GIT-VERSION-GEN`,
This is now required due to `rs/tree-wo-the-repository`, specifically
ec7a16b (cocci: convert parse_tree functions to repo_ variants,
2026-01-09).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
@dscho dscho closed this Feb 2, 2026
@dscho dscho deleted the tentative/vfs-2.53.0 branch February 2, 2026 19:43
@dscho
Copy link
Member Author

dscho commented Feb 2, 2026

Oh wow. I tried to automate this with the help of AI, but the result was completely bogus.

@dscho
Copy link
Member Author

dscho commented Feb 2, 2026

Not that I could have gone any further, for now, as GitHub Actions is once again having issues:

image

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.