Created
February 7, 2011 17:14
-
-
Save timruffles/814748 to your computer and use it in GitHub Desktop.
saves you time
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
js_path = 'public/javascripts' | |
problems = `grep -rP "\}[\s\n]*,[\s\n]*\}" #{js_path}` | |
if problems.length > 1 | |
puts "Woops, Internet Explorer HATES it when you use too many commas. Fix this or you'll be sad:" | |
puts problems | |
exit 1 | |
else | |
exit 0 | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment