diff options
author | mail_redacted_for_web | 2024-07-14 12:12:21 +0200 |
---|---|---|
committer | mail_redacted_for_web | 2024-07-14 12:12:21 +0200 |
commit | e60e29cb6c941223768634413e7ffa13cc5b0b19 (patch) | |
tree | 4c49b1dfe3a6e6ed5deb05dfdf8da91cfc74007b /.githooks | |
parent | 738ecb82e946043914fc822d8fb877a655e5ad4f (diff) | |
download | dotfiles-e60e29cb6c941223768634413e7ffa13cc5b0b19.tar.bz2 |
move submodule git-prompt to post-checkout
Diffstat (limited to '.githooks')
-rwxr-xr-x | .githooks/post-checkout | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/.githooks/post-checkout b/.githooks/post-checkout new file mode 100755 index 0000000..d4bbbd7 --- /dev/null +++ b/.githooks/post-checkout @@ -0,0 +1,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 |