serhii.net

In the middle of the desert you can say anything you want

14 Dec 2021

Git sparse checkout

Had a big repo, wanted to clone only some folders.

The setup below automatically fetched the subfolders I added to the sparse-checkout set.

git clone --filter=blob:none --no-checkout --branch main ssh://git@me.me/my/repo.git
cd myrepo
git sparse-checkout init --cone
git sparse-checkout set "activitywatch" "friends" ".task" ".timewarrior"
Nel mezzo del deserto posso dire tutto quello che voglio.