Created

Embed URL

HTTPS clone URL

SSH clone URL

You can clone with HTTPS or SSH.

Download Gist

grep .emit() calls

View emit.sh
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
#!/usr/bin/env bash
 
echo
 
find ${1:-.} -name "*.js" \
| xargs cat \
| grep '.emit(' \
| sed 's/.*.emit(//g' \
| sed -E "s/,|'|); *$//g" \
| awk '{
printf " \033[36m%-10s\033[0m", $1
for (i = 2; i <= NF; ++i)
printf " \033[90m%s\033[0m", $i
printf "\n"
}'
 
echo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.