Display Chuck Norris facts when you git pull !

...in just one command :

cd path/to/your/git/repo

cat <<EOF >.git/hooks/pre-rebase
#!/bin/sh
echo -n \$'\x1b[36m' # start coloration (cyan)
curl -s https://raw.githubusercontent.com/jenkinsci/chucknorris-plugin/master/src/main/java/hudson/plugins/chucknorris/FactGenerator.java | sed '1,/FACTS = {/d;s/^ \+"//;s/"..\?$//;/^$/,$d' | shuf -n 1
echo -n \$'\x1b[0m' # end coloration
EOF

And enjoy the message next time you git pull !

Chuck Norris approuve

Thanks to jenkinsci/chucknorris-plugin developpers for collecting those facts.