git.lirion.de

Of git, get, and gud

aboutsummaryrefslogtreecommitdiffstats
path: root/.githooks/post-checkout
blob: e02dfcfbee7048be4f3aece3e2ae5cc502600dbc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/usr/bin/env sh
rm -rf ./git-prompt
git -c submodule.sha1collisiondetection.update=none clone --no-checkout --depth 1 https://github.com/git/git.git ./git-prompt &&\
(
	cd ./git-prompt || exit 110
	#mkdir -pv contrib/completion || exit 111
	#git show HEAD:contrib/completion/git-prompt.sh > contrib/completion/git-prompt.sh || exit 112
	git restore --staged contrib/completion/git-prompt.sh
	git checkout contrib/completion/git-prompt.sh
	# if you can't cope with git reporting a truckload of deleted files, do this:
	#rm -rf .git
	# ...mind you this will alwasys pull in the whole repository on checkout/clone.
)