Skip to content
Snippets Groups Projects

Sparse checkout in git

  • Clone with SSH
  • Clone with HTTPS
  • Embed
  • Share
    The snippet can be accessed without any authentication.
    Authored by Felipe Zipitria
    git-sparse.sh 131 B
    #!/bin/sh
    echo > .git/info/sparse-checkout
    for i in "$@"
    do
     echo "$i" >> .git/info/sparse-checkout
    done
    git read-tree -m -u HEAD
     
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Please register or to comment