Skip to content

Instantly share code, notes, and snippets.

@edwinclement08
Created January 24, 2020 20:20
Show Gist options
  • Save edwinclement08/f697f2982d155cdd6137257253a8554d to your computer and use it in GitHub Desktop.
Save edwinclement08/f697f2982d155cdd6137257253a8554d to your computer and use it in GitHub Desktop.
enumerate all present handlebar template variables in sql
#!/bin/bash
for file in queries/*.sql
do
echo $file;
\cat $file | egrep -o '{{[a-zA-Z\. _]*}}' | awk '{print "\t", NR, $0}';
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment