summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason McIntyre <jmc@cvs.openbsd.org>2013-08-21 13:22:04 +0000
committerJason McIntyre <jmc@cvs.openbsd.org>2013-08-21 13:22:04 +0000
commit6b3d9bc766ee46a8b5a719fb8fd6b786c9013cc3 (patch)
tree137e58e868f976a5fbccd9c2db2619442b254887
parent4aa51cb5eada6aed3bd38d5355c2399ed4f7ab28 (diff)
recognise dragonfly; from jan stary
-rw-r--r--regress/usr.bin/mdoclint/mdoclint14
-rw-r--r--regress/usr.bin/mdoclint/mdoclint.110
2 files changed, 14 insertions, 10 deletions
diff --git a/regress/usr.bin/mdoclint/mdoclint b/regress/usr.bin/mdoclint/mdoclint
index c6457c0975d..def742ce0bb 100644
--- a/regress/usr.bin/mdoclint/mdoclint
+++ b/regress/usr.bin/mdoclint/mdoclint
@@ -1,7 +1,7 @@
#!/usr/bin/perl
#
-# $OpenBSD: mdoclint,v 1.36 2013/08/05 07:24:19 jmc Exp $
-# $NetBSD: mdoclint,v 1.39 2013/08/02 13:16:54 wiz Exp $
+# $OpenBSD: mdoclint,v 1.37 2013/08/21 13:22:03 jmc Exp $
+# $NetBSD: mdoclint,v 1.41 2013/08/21 11:22:15 wiz Exp $
#
# Copyright (c) 2001-2013 Thomas Klausner
# All rights reserved.
@@ -82,7 +82,7 @@ usage: mdoclint [-$options] file ...
-s warn about whitespace problems
-v verbose output
-w show section header in warnings
- -X warn about explicit mentions of FreeBSD, NetBSD, or OpenBSD
+ -X warn about explicit mentions of the *BSD system names
-x warn about cross-references with missing targets
Default is $default if no flag is specified.
EOF
@@ -93,6 +93,7 @@ EOF
my %short = (
"Free" => ".Fx",
"Net" => ".Nx",
+ "DragonFly" => ".Dx",
"Open" => ".Ox"
);
@@ -523,15 +524,16 @@ sub process_line
}
}
- if (/\b(Free|Net|Open)BSD\b/o
- and not /\b(?:www|ftp)\.(?:Free|Net|Open)BSD\.org\b/o
+ if (/\b(Free|Net|DragonFly|Open)BSD\b/o
+ and not /\b(?:www|ftp)\.(?:Free|Net|DragonFly|Open)BSD\.org\b/o
and not /\bOpenBSD\::.*3p\b/o
and not /\/pub\/OpenBSD\//o
and not /\@(?:Free|Net|Open)BSD\.(?i:org)\b/o) {
$s->warning("verbose mention of `$1BSD' instead of "
. "`$short{$1}': `$_'") if $opt_X;
}
- if (/^\./o and (/Bx (Open)/o or /Bx (Free)/o or /Bx (Net)/o)) {
+ if (/^\./o and (/Bx (Open)/o or /Bx (Free)/o
+ or /Bx (DragonFly)/o or /Bx (Net)/o)) {
$s->warning("`.Bx $1' found -- use $short{$1} instead")
if $opt_X;
}
diff --git a/regress/usr.bin/mdoclint/mdoclint.1 b/regress/usr.bin/mdoclint/mdoclint.1
index d31862b4136..2b5a87dfc6d 100644
--- a/regress/usr.bin/mdoclint/mdoclint.1
+++ b/regress/usr.bin/mdoclint/mdoclint.1
@@ -1,5 +1,5 @@
-.\" $OpenBSD: mdoclint.1,v 1.15 2013/08/05 07:09:42 jmc Exp $
-.\" $NetBSD: mdoclint.1,v 1.10 2013/07/30 18:50:07 wiz Exp $
+.\" $OpenBSD: mdoclint.1,v 1.16 2013/08/21 13:22:03 jmc Exp $
+.\" $NetBSD: mdoclint.1,v 1.13 2013/08/21 11:22:15 wiz Exp $
.\"
.\" Copyright (c) 2001-2013 Thomas Klausner
.\" All rights reserved.
@@ -25,7 +25,7 @@
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
-.Dd $Mdocdate: August 5 2013 $
+.Dd $Mdocdate: August 21 2013 $
.Dt MDOCLINT 1
.Os
.Sh NAME
@@ -127,12 +127,14 @@ in warnings.
Warn about explicit mentions of the words
.Dq FreeBSD ,
.Dq NetBSD ,
+.Dq DragonFlyBSD ,
and
.Dq OpenBSD ,
-which should be replaced by .Fx, .Nx, and .Ox respectively.
+which should be replaced by .Fx, .Nx, .Dx, and .Ox respectively.
Also notices occurrences of
.Dq \&.Bx Free ,
.Dq \&.Bx Net ,
+.Dq \&.Bx DragonFly ,
and
.Dq \&.Bx Open ,
for which the same applies.