Skip to content

Instantly share code, notes, and snippets.

@kikoseijo
Created March 28, 2017 22:38
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save kikoseijo/055737670161a588239855a4ccdc61cc to your computer and use it in GitHub Desktop.
#!/bin/bash
IFS=$'\n'
while read writable_dir
do
find "$writable_dir" -type f -not -iname '*.php' -print0 | xargs -0 egrep -i "(<\?php|<\?=|<\? *(?!(xml)))" --color
done < writable_dirs.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment