Fix usage message and SYNOPSIS section wrt to option O as suggested by wiz.

This commit is contained in:
seb 2003-01-05 13:07:38 +00:00
parent b99251db10
commit a74ab65529
2 changed files with 10 additions and 7 deletions

View File

@ -1,4 +1,4 @@
.\" $NetBSD: db.1,v 1.5 2002/12/29 18:42:49 seb Exp $ .\" $NetBSD: db.1,v 1.6 2003/01/05 13:07:38 seb Exp $
.\" .\"
.\" Copyright (c) 2002 The NetBSD Foundation, Inc. .\" Copyright (c) 2002 The NetBSD Foundation, Inc.
.\" All rights reserved. .\" All rights reserved.
@ -58,6 +58,9 @@ databases
.Bk -words .Bk -words
.Op Fl f Ar infile .Op Fl f Ar infile
.Ek .Ek
.Bk -words
.Op Fl O Ar str
.Ek
.Ar type .Ar type
.Ar database .Ar database
.Bk -words .Bk -words
@ -209,7 +212,7 @@ Read mode specific options are:
Display key. Display key.
.It Fl V .It Fl V
Display value. Display value.
.It Fl O Ar string .It Fl O Ar str
Field separator string between key and value. Defaults to a single Field separator string between key and value. Defaults to a single
tab tab
.Pq Sq \et . .Pq Sq \et .

View File

@ -1,4 +1,4 @@
/* $NetBSD: db.c,v 1.6 2002/12/29 18:42:49 seb Exp $ */ /* $NetBSD: db.c,v 1.7 2003/01/05 13:07:38 seb Exp $ */
/*- /*-
* Copyright (c) 2002 The NetBSD Foundation, Inc. * Copyright (c) 2002 The NetBSD Foundation, Inc.
@ -38,7 +38,7 @@
#include <sys/cdefs.h> #include <sys/cdefs.h>
#ifndef lint #ifndef lint
__RCSID("$NetBSD: db.c,v 1.6 2002/12/29 18:42:49 seb Exp $"); __RCSID("$NetBSD: db.c,v 1.7 2003/01/05 13:07:38 seb Exp $");
#endif /* not lint */ #endif /* not lint */
#include <db.h> #include <db.h>
@ -461,9 +461,9 @@ usage(void)
const char *p = getprogname(); const char *p = getprogname();
fprintf(stderr, fprintf(stderr,
"Usage: %s [-KV] [-Niq] [-E end] [-f inf] type dbfile [key [...]]\n" "Usage: %s [-KV] [-Niq] [-E end] [-f inf] [-O str] type dbfile [key [...]]\n"
" %s -d [-Niq] [-E end] [-f inf] type dbfile [key [...]]\n" " %s -d [-Niq] [-E end] [-f inf] type dbfile [key [...]]\n"
" %s -w [-Niq] [-E end] [-f inf] [-CDR] [-F sep] [-m mod] [-O str]\n" " %s -w [-Niq] [-E end] [-f inf] [-CDR] [-F sep] [-m mod]\n"
" type dbfile [key val [...]]\n" " type dbfile [key val [...]]\n"
,p ,p ,p ); ,p ,p ,p );
fprintf(stderr, fprintf(stderr,
@ -484,7 +484,7 @@ usage(void)
"\t-i\tignore case of key by converting to lower case\n" "\t-i\tignore case of key by converting to lower case\n"
"\t-m mod\tmode of created database [default: 0644]\n" "\t-m mod\tmode of created database [default: 0644]\n"
"\t-q\tquiet operation (missing keys aren't errors)\n" "\t-q\tquiet operation (missing keys aren't errors)\n"
"\t-O sep\toutput field separator string [default: '\\t']\n" "\t-O str\toutput field separator string [default: '\\t']\n"
); );
exit(1); exit(1);
} }