git.lirion.de

Of git, get, and gud

aboutsummaryrefslogtreecommitdiffstats
path: root/.githooks/post-checkout
blob: d4bbbd7bbb13752cbf77d01868a3f6cad8578839 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/usr/bin/env sh
# client-side
install -dvm 0750 .git/modules
install -dvm 0750 .git/modules/git-prompt
install -dvm 0750 .git/modules/git-prompt/info
cat > .git/modules/git-prompt/info/sparse-checkout <<EOF
contrib/completion/git-prompt.sh
EOF
rm -rf ./git-prompt
git -c submodule.sha1collisiondetection.update=none clone --depth=1 --no-checkout https://github.com/git/git.git git-prompt &&\
git submodule add https://github.com/git/git.git git-prompt &&\
git -C git-prompt config core.sparseCheckout true &&\
git submodule update --force --checkout git-prompt