Forráskód Böngészése

* Document the -V option [1]
* Correct the version string

Submitted by: Mark Linimon <linimon@lonesome.com>

marcus 21 éve
szülő
commit
f6719dc1f2
2 módosított fájl, 7 hozzáadás és 4 törlés
  1. 3 1
      portlint.1
  2. 4 3
      portlint.pl

+ 3 - 1
portlint.1

@@ -10,7 +10,7 @@
 .Nd a verifier for port directory
 .Sh SYNOPSIS
 .Nm portlint
-.Op Fl abchvtN
+.Op Fl abchvtNV
 .Op Fl M Ar ENV
 .Op Fl B Ar n
 .Op Ar dir
@@ -67,6 +67,8 @@ New port flag.
 Adds several checks specific to newly submitted port.
 If you are willing to submit the directory to be checked as a new port,
 use this option.
+.It Fl t
+Print the portlint version and exit.
 .It Fl M Ar ENV
 Set make variables to
 .Pa ENV

+ 4 - 3
portlint.pl

@@ -39,7 +39,8 @@ $portdir = '.';
 
 # version variables
 my $major = 2;
-my $minor = 3;
+my $minor = 4;
+my $micro = 1;
 
 sub l { '[{(]'; }
 sub r { '[)}]'; }
@@ -91,6 +92,7 @@ usage: $prog [-AabchvtN] [-M ENV] [-B#] [port_directory]
 	-v	verbose mode
 	-t	nit pick about use of spaces
 	-N	writing a new port
+	-V  print the version and exit
 	-M ENV	set make variables to ENV (ex. PORTSDIR=/usr/ports.work)
 	-B#	allow # contiguous blank lines (default: $contblank line)
 EOF
@@ -98,11 +100,10 @@ EOF
 }
 
 sub version {
-	print "$prog version $major.$minor\n";
+	print "$prog version $major.$minor.$micro\n";
 	exit $major;
 }
 
-
 getopts('AabchtvB:M:NV');
 
 &usage if $opt_h;