lkml.org 
[lkml]   [2012]   [Aug]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 1/4] scripts/checkincludes.pl: Print usage with heredoc
Date
This is already used in checkpatch.pl, and is easier to
read, so I am changing it in checkincludes as well.

Additionally, this makes the usage output theoretically
easier to edit. In practise, there's almost no difference

Signed-off-by: Cruz Julian Bishop <cruzjbishop@gmail.com>
---
scripts/checkincludes.pl | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/scripts/checkincludes.pl b/scripts/checkincludes.pl
index 97b2c61..801ed5f 100755
--- a/scripts/checkincludes.pl
+++ b/scripts/checkincludes.pl
@@ -14,9 +14,13 @@
use strict;

sub usage {
- print "Usage: checkincludes.pl [-r]\n";
- print "By default we just warn of duplicates\n";
- print "To remove duplicated includes in place use -r\n";
+ print <<EOM;
+Usage: checkincludes.pl [OPTIONS]... FILE...
+By default, we just warn of duplicates.
+
+Options:
+ -r Remove duplicated includes in place
+EOM
exit 1;
}

--
1.7.9.5


\
 
 \ /
  Last update: 2012-08-31 16:01    [W:1.416 / U:0.284 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site