Code

diff-highlight: make perl strict and warnings fatal
authorJeff King <peff@peff.net>
Mon, 13 Feb 2012 22:28:10 +0000 (17:28 -0500)
committerJunio C Hamano <gitster@pobox.com>
Mon, 13 Feb 2012 23:57:06 +0000 (15:57 -0800)
These perl features can catch bugs, and we shouldn't be
violating any of the strict rules or creating any warnings,
so let's turn them on.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/diff-highlight/diff-highlight

index d8938982e413a9bf994bd12386121249c888649d..c3302dd8171c47ba89523123cbb7a0de0588971f 100755 (executable)
@@ -1,5 +1,8 @@
 #!/usr/bin/perl
 
+use warnings FATAL => 'all';
+use strict;
+
 # Highlight by reversing foreground and background. You could do
 # other things like bold or underline if you prefer.
 my $HIGHLIGHT   = "\x1b[7m";