Add mandoc-manpage for echo(1)

and mark it as finished in the README.
This commit is contained in:
FRIGN 2015-01-23 23:49:24 +01:00
parent 8ac1165125
commit 22c6502b67
3 changed files with 32 additions and 16 deletions

2
README
View File

@ -26,7 +26,7 @@ The following tools are implemented ('*' == finished, '#' == UTF-8 support,
=* date yes none =* date yes none
=* dirname yes none =* dirname yes none
= du no -H, -L, (-x) = du no -H, -L, (-x)
= echo yes none =* echo yes none
= env yes none = env yes none
# expand yes none # expand yes none
expr yes none expr yes none

44
echo.1
View File

@ -1,14 +1,30 @@
.TH ECHO 1 sbase\-VERSION .Dd January 23, 2015
.SH NAME .Dt ECHO 1 sbase\-VERSION
echo \- print arguments .Sh NAME
.SH SYNOPSIS .Nm echo
.B echo .Nd print arguments
.RB [ \-n ] .Sh SYNOPSIS
.RI [ string ...] .Nm echo
.SH DESCRIPTION .Op Fl n
.B echo .Op Ar string ...
prints its arguments to stdout, separated by spaces and terminated by a newline. .Sh DESCRIPTION
.SH OPTIONS .Nm
.TP prints each
.B \-n .Ar string
Do not print terminating newline. to stdout, separated by spaces and terminated by
a newline.
.Sh OPTIONS
.Bl -tag -width Ds
.It Fl n
Do not print the terminating newline.
.El
.Sh STANDARDS
The
.Nm
utility is compliant with the
.St -p1003.1-2008
specification.
.Pp
The
.Op Fl n
flag is an extension to that specification.

2
echo.c
View File

@ -7,7 +7,7 @@
static void static void
usage(void) usage(void)
{ {
eprintf("usage: %s [-n] text\n", argv0); eprintf("usage: %s [-n] [string ...]\n", argv0);
} }
int int