Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
search all Contao Hooks
#/bin/bash
# Alle Hooks aus Contao suchen
#WEBROOT=/your/web/root/directory
WEBROOT=/Users/andreas/Sites
# ROOT Verzeichnis einer Contao Installation
TL_ROOT=$WEBROOT/contao3.2
hooks=$(grep -R "foreach (\$GLOBALS\['TL_HOOKS'\]" $TL_ROOT | cut -d"'" -f4 | sort | uniq)
for hook in $hooks
do
echo "HOOK $hook found in"
grep -Rl "\['$hook'\]" $TL_ROOT
echo ""
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment