Documentation for reading command line arguments from a file.

This commit is contained in:
Moritz Bunkus 2003-04-20 15:07:11 +00:00
parent 1f2f6dfe8f
commit e5c4e8f95b
2 changed files with 26 additions and 3 deletions

View File

@ -3,7 +3,7 @@
mkvmerge \- Merge multimedia streams into a Matroska file
.SH SYNOPSIS
.B mkvmerge
[\fIglobal options\fR] \-o \fIout\fR [\fIoptions\fR] <file1> [[\fIoptions\fR] <file2> ...]
[\fIglobal options\fR] \-o \fIout\fR [\fIoptions\fR] <file1> [[\fIoptions\fR] <file2> ...] [@optionsfile]
.SH DESCRIPTION
.LP
This program takes the input from several media files and joins
@ -98,6 +98,27 @@ Show usage information.
.TP
\fB\-V\fR, \fB\-\-version\fR
Show version information.
.TP
\fB@\fR\fIoptionsfile\fR
Reads additional command line arguments from the file \fIoptionsfile\fR.
Lines whose first non-whitespace character is a hash mark (#) are treated
as comments and ignored. Whitespaces at the start and end of a line will
be stripped. If a space is encountered then the line will be split into
exactly two arguments - the string before the space and the string after
it. There is no meta character escaping.
.br
The command line \fBmkvmerge \-o "my file.mkv" -A "a movie.avi" sound.ogg\fR
could be converted into the following option file:
.br
# Write to the file "my file.mkv".
.br
\-o my file.mkv
.br
# Only take the video from "a movie.avi".
.br
\-A a movie.avi
.br
sound.ogg
.SH USAGE
.LP
For each file the user can select which tracks \fBmkvmerge\fR should take.

View File

@ -13,7 +13,7 @@
/*!
\file
\version \$Id: mkvmerge.cpp,v 1.39 2003/04/20 14:59:33 mosu Exp $
\version \$Id: mkvmerge.cpp,v 1.40 2003/04/20 15:07:11 mosu Exp $
\brief command line parameter parsing, looping, output handling
\author Moritz Bunkus <moritz @ bunkus.org>
*/
@ -141,7 +141,7 @@ file_type_t file_types[] =
static void usage(void) {
fprintf(stdout,
"mkvmerge -o out [global options] [options] <file1> [[options] <file2> ...]"
"mkvmerge -o out [global options] [options] <file1> [@optionsfile ...]"
"\n\n Global options:\n"
" -v, --verbose verbose status\n"
" -q, --quiet suppress status output\n"
@ -177,6 +177,8 @@ static void usage(void) {
" -l, --list-types Lists supported input file types.\n"
" -h, --help Show this help.\n"
" -V, --version Show version information.\n"
" @optionsfile Reads additional command line options from\n"
" the specified file (see man page).\n"
);
}