Skip to content

Instantly share code, notes, and snippets.

@CarsonSlovoka
Created July 29, 2025 06:26
Show Gist options
  • Save CarsonSlovoka/b95db1e46caa6ddac4bc1ef8a64ddc73 to your computer and use it in GitHub Desktop.
Save CarsonSlovoka/b95db1e46caa6ddac4bc1ef8a64ddc73 to your computer and use it in GitHub Desktop.
git clone *.xlsx
git rev-list HEAD --count # 1722
git log --oneline --since="2025-03-20" --reverse | head -n 1
# 40b3136
echo "1722 - 1367" | bc
# 355
git clone file://$(realpath ..) --depth=355 --no-checkout ~/Downloads/temp/test-git/
git init
{
echo '[remote "origin"]'
echo ' url = file:///path/to/project'
echo ' fetch = +refs/heads/*:refs/remotes/origin/*'
echo ' partialclonefilter = blob:none'
} >> .git/config
git sparse-checkout init
{
echo '*.xlsx'
} > .git/info/sparse-checkout
git pull origin master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment