forked from bonsai/harakit
74 lines
2.0 KiB
Groff
74 lines
2.0 KiB
Groff
.\" Copyright (c) 2024 DTB <trinity@trinity.moe>
|
|
.\"
|
|
.\" This work is licensed under CC BY-SA 4.0. To see a copy of this license,
|
|
.\" visit <http://creativecommons.org/licenses/by-sa/4.0/>.
|
|
.\"
|
|
.TH MM 1 2024-07-14 "Harakit X.X.X"
|
|
.SH NAME
|
|
mm \(en middleman
|
|
.\"
|
|
.SH SYNOPSIS
|
|
|
|
mm
|
|
.RB [ -aetu ]
|
|
.RB [ -i\ input ]
|
|
.RB [ -o\ output ]
|
|
.\"
|
|
.SH DESCRIPTION
|
|
|
|
Catenate input files and write them to the start of each output file or stream.
|
|
.\"
|
|
.SH OPTIONS
|
|
|
|
.IP \fB-a\fP
|
|
Opens outputs for appending rather than updating.
|
|
.IP \fB-e\fP
|
|
Use the standard error as an output.
|
|
.IP \fB-t\fP
|
|
Causes outputs to be overwritten instead of being truncated.
|
|
.IP \fB-u\fP
|
|
Ensures neither input or output will be buffered.
|
|
.IP \fB-i\fP\ \fIinput\fP
|
|
Opens a path as an input. If one or more of the input files is \(lq-\(rq or if
|
|
no inputs are specified, the standard input shall be used. If specified as the
|
|
last option and if there are trailing arguments to the program, they shall be
|
|
appended to the list of files to use as inputs.
|
|
.IP \fB-o\fP\ \fIoutput\fP
|
|
Opens a path as an output. If one or more of the output files is \(lq-\(rq or if
|
|
no outputs are specified and the
|
|
.B -e
|
|
option is not specified, the standard output shall be used. If specified as the
|
|
last option and if there are trailing arguments to the program, they shall be
|
|
appended to the list of files to use as outputs.
|
|
.\"
|
|
.SH DIAGNOSTICS
|
|
|
|
If an output cannot be written to, an error occurs; however, exiting will be
|
|
deferred until writing to any other specified outputs completes.
|
|
|
|
When an error is encountered, a diagnostic message is printed and the program
|
|
exits with the appropriate
|
|
.BR sysexits.h (3)
|
|
status.
|
|
.\"
|
|
.SH RATIONALE
|
|
|
|
The
|
|
.BR cat (1p)
|
|
and
|
|
.BR tee (1p)
|
|
programs specified in POSIX together provide similar functionality. The
|
|
separation of the two sets of functionality into separate APIs seemed
|
|
unncessary.
|
|
.\"
|
|
.SH COPYRIGHT
|
|
|
|
Copyright \(co 2024 DTB. License AGPLv3+: GNU AGPL version 3 or later
|
|
<https://gnu.org/licenses/agpl.html>.
|
|
.\"
|
|
.SH SEE ALSO
|
|
.BR cat (1p),
|
|
.BR dd (1),
|
|
.BR dj (1),
|
|
.BR tee (1p)
|