Skip to content

Instantly share code, notes, and snippets.

@timerring
Last active November 8, 2024 03:48
Show Gist options
  • Select an option

  • Save timerring/f309a324f52a38c6c7965a423add47a0 to your computer and use it in GitHub Desktop.

Select an option

Save timerring/f309a324f52a38c6c7965a423add47a0 to your computer and use it in GitHub Desktop.
Pull the repository partially

If you want to pull the repository partially, you can try the commmands of sparse clone:

# open the sparse clone
git config core.sparsecheckout true
echo "some/dir/" >> ./git/info/sparse-checkout

Then you just need to pull as usual: git pull origin main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment