Skip to content

Re-apply sparse-checkout paths on subsequent installs#439

Merged
jacebrowning merged 2 commits intojacebrowning:mainfrom
fhamdi-bdai:fhamdi-bdai/respect-sparse-path-updates
Mar 20, 2026
Merged

Re-apply sparse-checkout paths on subsequent installs#439
jacebrowning merged 2 commits intojacebrowning:mainfrom
fhamdi-bdai:fhamdi-bdai/respect-sparse-path-updates

Conversation

@fhamdi-bdai
Copy link
Contributor

@fhamdi-bdai fhamdi-bdai commented Mar 18, 2026

Hello 👋, I've been using gitman and ran into similar issues to #265, and figured to give resolving it a shot.

Why was this change made?

When sparse_paths are changed in the config and gitman install is run again on an already-cloned repo, the new sparse paths were not applied, only the initial clone respected them.

Change summary

This adds a sparse-checkout set call during update_files so that changed sparse paths take effect on re-install. Glob-style paths (e.g. src/*) are also sanitized to directory names for cone mode compatibility.

Related Issue: #265

I am happy to make any adjustments to this PR. Let me know what changes are required

@jacebrowning jacebrowning self-requested a review March 19, 2026 15:38
@jacebrowning jacebrowning merged commit 2957dd6 into jacebrowning:main Mar 20, 2026
7 checks passed
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.

2 participants