Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
305 commits
Select commit Hold shift + click to select a range
5d7f1c8
status: serialize to path
jeffhostetler Feb 2, 2018
c89c8a3
status: reject deserialize in V2 and conflicts
jeffhostetler Feb 7, 2018
fd3fa17
gvfs: verify that the built-in FSMonitor is disabled
dscho Jun 18, 2021
ae20a35
serialize-status: serialize global and repo-local exclude file metadata
jeffhostetler Jul 20, 2018
ae207a6
wt-status: add trace2 data for sparse-checkout percentage
jeffhostetler Jun 21, 2024
85f8b88
status: deserialization wait
jeffhostetler Jul 25, 2018
77a05c8
wt-status: add VFS hydration percentage to normal `git status` output
jeffhostetler Jun 24, 2024
e3eb163
gvfs:trace2:data: add trace2 tracing around read_object_process
jeffhostetler Sep 26, 2018
283754f
status: deserialize with -uno does not print correct hint
jeffhostetler Jun 25, 2019
6271e7d
gvfs:trace2:data: status deserialization information
jeffhostetler Sep 26, 2018
b854957
fsmonitor: check CE_FSMONITOR_VALID in ce_uptodate
kewillford Nov 21, 2019
f2f8e77
gvfs:trace2:data: status serialization
jeffhostetler Jan 7, 2019
bc9d170
fsmonitor: add script for debugging and update script for tests
kewillford Nov 21, 2019
7f640d8
gvfs:trace2:data: add vfs stats
jeffhostetler Nov 19, 2018
b317deb
status: disable deserialize when verbose output requested.
jeffhostetler Apr 11, 2020
816d456
trace2: refactor setting process starting time
jeffhostetler Apr 15, 2019
c748348
t7524: add test for verbose status deserialzation
jeffhostetler Apr 11, 2020
5765d2d
trace2:gvfs:experiment: clear_ce_flags_1
jeffhostetler Apr 30, 2019
da00afe
deserialize-status: silently fallback if we cannot read cache file
jeffhostetler May 13, 2020
12606fb
trace2:gvfs:experiment: report_tracking
jeffhostetler Apr 30, 2019
2b62302
trace2:gvfs:experiment: read_cache: annotate thread usage in read-cache
jeffhostetler Jun 14, 2019
4998f1e
trace2:gvfs:experiment: read-cache: time read/write of cache-tree ext…
jeffhostetler Jul 9, 2019
ecb63bb
trace2:gvfs:experiment: add region to apply_virtualfilesystem()
jeffhostetler Jul 16, 2019
19bd4ef
trace2:gvfs:experiment: add region around unpack_trees()
jeffhostetler Jul 16, 2019
037de62
trace2:gvfs:experiment: add region to cache_tree_fully_valid()
jeffhostetler Jul 16, 2019
b7dfb3e
trace2:gvfs:experiment: add unpack_entry() counter to unpack_trees() …
jeffhostetler Jul 16, 2019
fba6d9c
credential: set trace2_child_class for credential manager children
jeffhostetler Oct 3, 2019
16ed1ac
trace2:gvfs:experiment: increase default event depth for unpack-tree …
jeffhostetler Jul 25, 2019
e64d4da
sub-process: do not borrow cmd pointer from caller
jeffhostetler Sep 18, 2019
fb4f5ff
trace2:gvfs:experiment: add data for check_updates() in unpack_trees()
jeffhostetler Jul 25, 2019
0e5b181
sub-process: add subprocess_start_argv()
jeffhostetler Sep 18, 2019
f60deec
Trace2:gvfs:experiment: capture more 'tracking' details
jeffhostetler Jul 26, 2019
12f7afa
sha1-file: add function to update existing loose object cache
jeffhostetler Sep 24, 2019
c92a2c6
packfile: add install_packed_git_and_mru()
jeffhostetler Sep 25, 2019
07ccbe9
index-pack: avoid immediate object fetch while parsing packfile
jeffhostetler Sep 24, 2019
87c5076
gvfs-helper: create tool to fetch objects using the GVFS Protocol
jeffhostetler Aug 13, 2019
da78e18
sha1-file: create shared-cache directory if it doesn't exist
jeffhostetler Oct 7, 2019
a195263
gvfs-helper: better handling of network errors
jeffhostetler Oct 8, 2019
8a883d3
gvfs-helper-client: properly update loose cache with fetched OID
jeffhostetler Oct 8, 2019
cbb83f0
gvfs-helper: V2 robust retry and throttling
jeffhostetler Oct 10, 2019
2388db8
gvfs-helper: expose gvfs/objects GET and POST semantics
jeffhostetler Oct 21, 2019
79f28e6
gvfs-helper: dramatically reduce progress noise
derrickstolee Oct 24, 2019
218ea02
gvfs-helper: handle pack-file after single POST request
derrickstolee Nov 11, 2019
a55dcac
test-gvfs-prococol, t5799: tests for gvfs-helper
jeffhostetler Oct 25, 2019
0b60864
gvfs-helper: move result-list construction into install functions
jeffhostetler Nov 13, 2019
925542d
t5799: add support for POST to return either a loose object or packfile
jeffhostetler Nov 13, 2019
6773657
t5799: cleanup wc-l and grep-c lines
jeffhostetler Nov 13, 2019
9b3c664
gvfs-helper: verify loose objects after write
derrickstolee Sep 18, 2020
43e9855
gvfs-helper: add prefetch support
jeffhostetler Nov 11, 2019
71616cb
t7599: create corrupt blob test
jeffhostetler Sep 18, 2020
4c2bf79
gvfs-helper: add prefetch .keep file for last packfile
jeffhostetler Nov 26, 2019
a9aff75
gvfs-helper: do one read in my_copy_fd_len_tail()
derrickstolee Dec 16, 2019
8ddd012
gvfs-helper: move content-type warning for prefetch packs
derrickstolee Dec 16, 2019
e5ad80a
fetch: use gvfs-helper prefetch under config
derrickstolee Dec 17, 2019
90a8c49
gvfs-helper: better support for concurrent packfile fetches
jeffhostetler Dec 18, 2019
4b943d3
remote-curl: do not call fetch-pack when using gvfs-helper
derrickstolee Feb 3, 2020
fdf5b90
t5799: explicitly test gvfs-helper --fallback and --no-fallback
jeffhostetler Jun 28, 2024
72e3ce8
fetch: reprepare packs before checking connectivity
derrickstolee Mar 12, 2020
9e9eed1
gvfs-helper: add --max-retries to prefetch verb
jeffhostetler Apr 12, 2023
5ea8127
gvfs-helper: don't fallback with new config
derrickstolee Jun 27, 2024
29e6969
gvfs-helper: retry when creating temp files
derrickstolee Dec 26, 2019
03fcf76
t5799: add tests to detect corrupt pack/idx files in prefetch
jeffhostetler Apr 13, 2023
53dbe72
test-gvfs-protocol: add cache_http_503 to mayhem
jeffhostetler Jun 28, 2024
bf00f92
sparse: avoid warnings about known cURL issues in gvfs-helper.c
derrickstolee Aug 3, 2021
fef0017
gvfs-helper: ignore .idx files in prefetch multi-part responses
jeffhostetler Apr 13, 2023
d65eea4
t5799: add unit tests for new `gvfs.fallback` config setting
jeffhostetler Jun 28, 2024
7eb56c8
homebrew: add GitHub workflow to release Cask
mjcheetham Jul 24, 2020
57124c3
Disable the `monitor-components` workflow in msft-git
dscho May 13, 2022
6b8ae45
.github/actions/akv-secret: add action to get secrets
mjcheetham Apr 1, 2025
d9b2dcd
maintenance: care about gvfs.sharedCache config
derrickstolee Dec 15, 2020
e29d04e
unpack-trees:virtualfilesystem: Improve efficiency of clear_ce_flags
neerajsi-msft2 Feb 6, 2021
0f8e14f
Adding winget workflows
Apr 29, 2021
0431002
.github: enable windows builds on microsoft fork
derrickstolee Mar 8, 2023
5ac788d
release: create initial Windows installer build workflow
vdye Jul 16, 2021
85a2780
release: create initial Windows installer build workflow
mjcheetham Mar 21, 2025
a0e80d0
help: special-case HOST_CPU `universal`
jeffhostetler Oct 17, 2023
ddc2bca
release: add Mac OSX installer build
vdye Jul 16, 2021
13f92e0
release: build unsigned Ubuntu .deb package
vdye Jul 16, 2021
e8b80df
release: add signing step for .deb package
vdye Jul 16, 2021
7dcec35
release: create draft GitHub release with packages & installers
vdye Jul 16, 2021
9308b72
dist: archive HEAD instead of HEAD^{tree}
vdye Dec 2, 2021
73168c4
build-git-installers: publish gpg public key
ldennington Oct 24, 2023
8ee6938
release: include GIT_BUILT_FROM_COMMIT in MacOS build
vdye Dec 2, 2021
4d9a7d8
release: continue pestering until user upgrades
derrickstolee Oct 6, 2021
531fc95
release: add installer validation
ldennington Aug 17, 2022
3ede924
update-microsoft-git: create barebones builtin
derrickstolee Apr 29, 2021
dd6be5c
.github: reinstate ISSUE_TEMPLATE.md for microsoft/git
derrickstolee Mar 16, 2022
9272521
update-microsoft-git: Windows implementation
derrickstolee Apr 29, 2021
1f4fc34
.github: update PULL_REQUEST_TEMPLATE.md
derrickstolee Mar 16, 2022
e827bc4
git_config_set_multivar_in_file_gently(): add a lock timeout
dscho May 18, 2021
5bebc82
update-microsoft-git: use brew on macOS
derrickstolee Apr 29, 2021
74ddf0b
Adjust README.md for microsoft/git
May 4, 2021
bd144f8
scalar: set the config write-lock timeout to 150ms
dscho May 18, 2021
b8035a1
scalar: add docs from microsoft/scalar
derrickstolee Jun 16, 2021
92bdcec
Merge branch 'scalar-gentler-config-locking'
dscho May 19, 2021
324afd0
Merge branch 'scalar-extra-docs'
dscho Nov 16, 2021
59f4b95
scalar (Windows): use forward slashes as directory separators
dscho May 10, 2022
e04c82b
scalar: add retry logic to run_git()
derrickstolee Jun 17, 2021
916c432
scalar: support the `config` command for backwards compatibility
dscho May 27, 2021
b049a2a
Merge branch 'microsoft/vfs-2.35.0'
dscho Oct 7, 2021
a1a8744
scalar: implement a minimal JSON parser
dscho Apr 26, 2021
5cf2815
Merge branch 'scalar'
dscho Aug 24, 2021
96ac103
scalar clone: support GVFS-enabled remote repositories
dscho Aug 24, 2021
2559da3
test-gvfs-protocol: also serve smart protocol
dscho Apr 16, 2021
e8e4251
gvfs-helper: add the `endpoint` command
dscho Apr 26, 2021
007c22d
dir_inside_of(): handle directory separators correctly
dscho May 14, 2021
d26e243
scalar: disable authentication in unattended mode
dscho May 6, 2021
6bae332
scalar: do initialize `gvfs.sharedCache`
dscho May 3, 2021
b3c317e
scalar diagnose: include shared cache info
dscho Jun 1, 2021
0b806b5
scalar: only try GVFS protocol on https:// URLs
dscho Apr 28, 2021
8f62ab7
scalar: verify that we can use a GVFS-enabled repository
dscho Apr 16, 2021
9d5cd82
scalar: add the `cache-server` command
dscho Apr 23, 2021
217fdab
scalar: add a test toggle to skip accessing the vsts/info endpoint
dscho May 12, 2021
1437866
scalar: adjust documentation to the microsoft/git fork
dscho Jan 25, 2022
eacd5a0
scalar: enable untracked cache unconditionally
derrickstolee Jun 21, 2021
a3af3c2
scalar: parse `clone --no-fetch-commits-and-trees` for backwards comp…
dscho Aug 24, 2021
2d923b0
scalar: make GVFS Protocol a forced choice
derrickstolee May 1, 2024
1b9c41a
scalar diagnose: accommodate Scalar's Functional Tests
dscho May 9, 2022
1f77217
abspath: make strip_last_path_component() global
derrickstolee Oct 4, 2022
1880963
scalar: work around GVFS Protocol HTTP/2 failures
Copilot May 22, 2025
07af3a3
ci: run Scalar's Functional Tests
dscho Jun 8, 2021
a689d52
scalar: upgrade to newest FSMonitor config setting
vdye Apr 5, 2022
b029a04
scalar: .scalarCache should live above enlistment
derrickstolee Sep 30, 2022
4050f15
Merge branch 'scalar-with-gvfs'
dscho May 3, 2021
86d2aa0
Merge branch 'run-scalar-functional-tests'
dscho Nov 16, 2021
32639c7
Merge branch 'scalar-reconfigure'
dscho Jun 1, 2021
e3dce1d
add/rm: allow adding sparse entries when virtual
derrickstolee Jun 29, 2021
8907404
Merge pull request #536: Allow --no-src during clones and git worktre…
dscho Oct 4, 2022
f40961e
sparse-checkout: add config to disable deleting dirs
derrickstolee Aug 22, 2021
6d8eba0
diff: ignore sparse paths in diffstat
derrickstolee Jul 26, 2021
84679f2
Merge pull request #392: add: allow adding sparse entries when virtual
derrickstolee Jul 1, 2021
725c9e2
repo-settings: enable sparse index by default
derrickstolee Jun 15, 2021
89c64e3
Merge pull request #410: Sparse Index: latest integrations
derrickstolee Aug 24, 2021
0dc5abd
diff(sparse-index): verify with partially-sparse
ldennington Sep 10, 2021
c9e1b30
Merge pull request #414: Make sparse index the default
derrickstolee Aug 26, 2021
58b2522
stash: expand testing for `git stash -u`
vdye Sep 22, 2021
a670d49
Merge pull request #419 from ldennington/sparse-index-diff
ldennington Sep 12, 2021
5d6f2f6
sequencer: avoid progress when stderr is redirected
derrickstolee Sep 23, 2021
68345e6
Merge pull request #430 from vdye/sparse-index/clean
vdye Sep 23, 2021
43a798c
Merge pull request #432: sequencer: avoid progress when stderr is red…
derrickstolee Sep 23, 2021
40a9a47
sparse: add vfs-specific precautions
derrickstolee Oct 31, 2021
ef9e9e7
reset: fix mixed reset when using virtual filesystem
Mar 15, 2017
6a8860d
Merge pull request #494: reset: fix mixed reset when using virtual fi…
derrickstolee Apr 4, 2022
3b868b8
Merge core VFS features
dscho Jun 11, 2018
38e190a
Merge advanced VFS-specific features
dscho Jun 11, 2018
9902ceb
Merge virtualfilesystem hook
dscho Jun 11, 2018
b428276
Merge updates to serialized status
dscho Jun 11, 2018
ca20ad2
Merge trace2 experimental regions
jeffhostetler Apr 23, 2019
659cd12
Merge first wave of gvfs-helper feature
jeffhostetler Nov 14, 2019
6dc900a
Merge gvfs-helper prefetch feature
derrickstolee Dec 17, 2019
59b8133
Harden gvfs-helper to validate the packfiles in a multipart prefetch …
jeffhostetler Apr 17, 2023
0f05b5b
gvfs-helper: add gvfs.fallback and unit tests (#665)
dscho Jul 1, 2024
cccffdd
Merge pull request #301: Update 'git maintenance' to match upstream
derrickstolee Dec 15, 2020
f7de76d
Merge pull request #315: unpack-trees:virtualfilesystem: Improve effi…
derrickstolee Feb 16, 2021
9cd3d55
Merge branch 'add-workflows'
derrickstolee Apr 30, 2021
f45f221
Merge branch 'adjust-g4w-workflows'
dscho May 13, 2022
9c35894
Merge pull request #399 from vdye/feature/build-installers
vdye Jul 29, 2021
630b847
Merge pull request #472 from vdye/ms/macos-build-options
vdye Dec 6, 2021
6e28cd8
Merge pull request #329: Add `git update-microsoft-git`
derrickstolee Apr 30, 2021
c9a56ed
Merge pull request #333: update microsoft/git README
derrickstolee May 17, 2021
07ed7bf
Merge pull request #371 from dscho/run-scalar-functional-tests-and-fi…
dscho Jun 9, 2021
eb92d8b
sparse-index: add ensure_full_index_with_reason()
derrickstolee Sep 30, 2024
312cee3
treewide: add reasons for expanding index
derrickstolee Sep 30, 2024
2ed5e99
treewide: custom reasons for expanding index
derrickstolee Sep 30, 2024
e816d9e
sparse-index: add macro for unaudited expansions
derrickstolee Sep 30, 2024
b3c4b3a
Docs: update sparse index plan with logging
derrickstolee Sep 30, 2024
86ee1d2
sparse-index: log failure to clear skip-worktree
derrickstolee Sep 30, 2024
1c539fe
Merge branch 'sparse-index-stuff'
dscho Jun 17, 2022
eabc8df
sparse-checkout: remove use of the_repository
derrickstolee Jul 7, 2025
10f201b
stash: use -f in checkout-index child process
derrickstolee Sep 30, 2024
08cbe49
sparse-checkout: add basics of 'clean' command
derrickstolee Jul 7, 2025
636faf3
sparse-index: do not copy hashtables during expansion
derrickstolee Sep 27, 2024
f71f513
Sparse Index: log why the index is being expanded (#691)
dscho Oct 9, 2024
b40b74f
sparse-checkout: match some 'clean' behavior
derrickstolee Jul 15, 2025
1188812
Fix rare segfault in sparse-index (#690)
dscho Oct 9, 2024
1c55ee3
dir: add generic "walk all files" helper
derrickstolee Jul 15, 2025
e1aba5d
sparse-checkout: add --verbose option to 'clean'
derrickstolee Jul 15, 2025
c0035c9
sparse-index: point users to new 'clean' action
derrickstolee Jul 7, 2025
4bf26c6
t: expand tests around sparse merges and clean
derrickstolee Jul 16, 2025
0503b78
sparse-checkout: make 'clean' clear more files
derrickstolee Jul 16, 2025
43c3da3
sparse-checkout: mark 'clean' as experimental
derrickstolee Aug 5, 2025
d19af00
sub-process: avoid leaking `cmd`
dscho Dec 18, 2024
58ff48a
remote-curl: release filter options before re-setting them
dscho Dec 18, 2024
e5bf48f
transport: release object filter options
dscho Dec 18, 2024
464562c
Add 'git sparse-checkout clean' (#779)
dscho Aug 5, 2025
b53e5c2
push: don't reuse deltas with path walk
derrickstolee Nov 16, 2024
51901a8
Merge branch 'leak-fixes'
dscho Dec 18, 2024
99f167c
t7900-maintenance.sh: reset config between tests
mjcheetham Jan 22, 2025
7f890e6
maintenance: add cache-local-objects maintenance task
mjcheetham Jan 14, 2025
107be90
scalar.c: add cache-local-objects task
mjcheetham Jan 23, 2025
39b61e5
pack-objects: don't reuse deltas with path walk (#707)
dscho Dec 19, 2024
f148e94
git.c: add VFS enabled cmd blocking
mjcheetham Mar 6, 2025
8d18b51
git.c: permit repack cmd in Scalar repos
mjcheetham Mar 6, 2025
514cbe6
git.c: permit fsck cmd in Scalar repos
mjcheetham Mar 13, 2025
24b1abe
git.c: permit prune cmd in Scalar repos
mjcheetham Mar 13, 2025
f61256c
maintenance: add new `cache-local-objects` maintenance task (#720)
mjcheetham Jan 31, 2025
2b83a1d
hooks: add custom post-command hook config
derrickstolee Mar 25, 2025
b8cd956
worktree: remove special case GVFS cmd blocking
mjcheetham Mar 6, 2025
f7a55e9
Docs: fix asciidoc failures from short delimiters
derrickstolee Mar 25, 2025
d5cd206
builtin/repack.c: emit warning when shared cache is present
mjcheetham Mar 26, 2025
e42a475
hooks: make hook logic memory-leak free
derrickstolee Mar 25, 2025
105f49c
Permit `repack` command in Scalar clones (#732)
mjcheetham Mar 31, 2025
7942a1e
hooks: add custom post-command hook config (#736)
dscho Apr 7, 2025
3f8ca8d
t5309: create failing test for 'git index-pack'
derrickstolee Apr 23, 2025
c1a3bc7
gvfs-helper: pass `long` values where expected
dscho Jun 6, 2025
edafff0
Fix REF_DELTA chain bug in 'git index-pack' (#745)
dscho Apr 25, 2025
0dea22e
gvfs-helper-client: clean up server process(es)
derrickstolee May 23, 2025
ae8b6d3
Merge branch 'curl-options-want-long-instead-of-int-msft-git'
dscho Jun 6, 2025
66f6357
clar: pass a string for a `%s` format placeholder
dscho Mar 21, 2025
2795fa7
clar(clar__assert_equal): do in-bounds check before accessing element
dscho Mar 21, 2025
fdd8377
clar(clar_summary_testsuite): avoid thread-unsafe `localtime()`
dscho Mar 21, 2025
559396e
cat_one_file(): make it easy to see that the `size` variable is initi…
dscho Oct 27, 2022
13a1ed0
fsck: avoid using an uninitialized variable
dscho Dec 16, 2022
ae4a90a
load_revindex_from_disk(): avoid accessing uninitialized data
dscho Dec 16, 2022
877e3a3
revision: defensive programming
dscho Dec 16, 2022
8046321
load_pack_mtimes_file(): avoid accessing uninitialized data
dscho Dec 16, 2022
07ea788
get_parent(): defensive programming
dscho Dec 16, 2022
5694bb5
fetch-pack: defensive programming
dscho Dec 16, 2022
7120035
unparse_commit(): defensive programming
dscho Dec 16, 2022
a8f231c
verify_commit_graph(): defensive programming
dscho Dec 16, 2022
f561dfc
stash: defensive programming
dscho Dec 16, 2022
00e3d8d
stash: defensive programming
dscho Dec 16, 2022
0448b70
push: defensive programming
dscho Dec 16, 2022
7b22fca
fetch: defensive programming
dscho Dec 16, 2022
c9e5c48
fetch: silence a CodeQL alert about a local variable's address' use a…
dscho Dec 14, 2022
23009bf
describe: defensive programming
dscho Dec 16, 2022
c3fb973
submodule: check return value of `submodule_from_path()`
dscho Dec 16, 2022
7d161d3
inherit_tracking(): defensive programming
dscho Dec 16, 2022
4b1d576
codeql: run static analysis as part of CI builds
dscho Aug 9, 2022
0a1a0cf
test-tool repository: check return value of `lookup_commit()`
dscho Dec 16, 2022
137c9ca
codeql: publish the sarif file as build artifact
dscho Mar 22, 2023
afefd5a
shallow: handle missing shallow commits gracefully
dscho Dec 16, 2022
d2daf2d
codeql: disable a couple of non-critical queries for now
dscho Mar 21, 2025
c01e438
commit-graph: suppress warning about using a stale stack addresses
dscho Dec 17, 2022
3c93a94
date: help CodeQL understand that there are no leap-year issues here
dscho Jul 23, 2025
800fb94
help: help CodeQL understand that consuming envvars is okay here
dscho Jul 23, 2025
1fe452c
ctype: help CodeQL understand that `sane_istest()` does not access ar…
dscho Jul 23, 2025
ecbecc9
ctype: accommodate for CodeQL misinterpreting the `z` in `mallocz()`
dscho Jul 23, 2025
69e0125
strbuf_read: help with CodeQL misunderstanding that `strbuf_read()` d…
dscho Jul 23, 2025
4fa44ec
codeql: also check JavaScript code
dscho Jul 24, 2025
a3c6542
Merge branch 'clar'
dscho Mar 21, 2025
84f8a78
Merge branch 'uninitialized-variables'
dscho Oct 27, 2022
c12f52f
Merge branch 'defensive-programming'
dscho Mar 21, 2025
41df2a1
Merge branch 'codeql-fixes'
dscho Mar 21, 2025
f2737e5
Merge branch 'codeql'
dscho Mar 21, 2025
a802cad
gvfs-helper-client: clean up server process (#756)
dscho Jun 13, 2025
13ccaa1
Merge branch 'codeql'
dscho Mar 21, 2025
248367f
Merge branch 'codeql'
dscho Mar 21, 2025
fe36b13
fixup! codeql: run static analysis as part of CI builds
mjcheetham Jul 8, 2025
a042926
fixup! maintenance: care about gvfs.sharedCache config
dscho Aug 21, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions t/t7900-maintenance.sh
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,37 @@ test_expect_success 'maintenance.loose-objects.batchSize' '
test_must_be_empty err
'

test_expect_success 'loose-objects and gvfs.sharedCache' '
git init gvfs-worktree &&
git init --bare gvfs-shared &&
git -C gvfs-worktree config gvfs.sharedCache "$PWD/gvfs-shared/objects" &&

# Hack to stop maintenance from running during "git commit"
echo in use >gvfs-worktree/.git/objects/maintenance.lock &&
git -C gvfs-worktree config maintenance.loose-objects.auto 1 &&
test_commit -C gvfs-worktree create-loose-object &&
rm gvfs-worktree/.git/objects/maintenance.lock &&
! ls -l gvfs-shared/objects/??/* &&
ls -l gvfs-worktree/.git/objects/??/* >loose-objects &&
test_file_not_empty loose-objects &&
! ls -l gvfs-shared/objects/pack/*.pack &&

# move the loose objects into the shared objects as if they had been
# fetched via the `gvfs-helper`
mv gvfs-worktree/.git/objects/?? gvfs-shared/objects/ &&

# Run `loose-objects` twice: The first run creates a pack-file
# but does not delete loose objects, the second run deletes
# loose objects but does not create a pack-file.
git -C gvfs-worktree maintenance run --task=loose-objects &&
git -C gvfs-worktree maintenance run --task=loose-objects &&

! ls -l gvfs-worktree/.git/objects/??/* &&
! ls -l gvfs-shared/.git/objects/??/* &&
ls -l gvfs-shared/objects/pack/*.pack >shared-packs &&
test_file_not_empty shared-packs
'

test_expect_success 'incremental-repack task' '
packDir=.git/objects/pack &&
for i in $(test_seq 1 5)
Expand Down
Loading