=head1 NAME
aa-incmdline - Helper to parse kernel command line
=head1 SYNOPSIS
B<aa-incmdline> [B<-D>] [B<-O> I<FILE|FD>] [B<-q>] [B<-f> I<FILE>] [B<-r>] [B<-s>] I<NAME>
=head1 OPTIONS
=over
=item B<-D, --double-output>
Enable double-output mode. Instead of using stdout for regular output, and
stderr for warnings and errors, everything is sent both to stdout and stderr.
This is intended to redirect stderr to a log file, so full output can be both
shown on console and logged.
B<Deprecation warning:> Note that this option has been deprecated and will be
removed in the next version; You should use B<--log-file> instead.
=item B<-f, --file> I<FILE>
Read command line from I<FILE> instead of I</proc/cmdline>
=item B<-h, --help>
Show help screen and exit.
=item B<-O, --log-file> I<FILE|FD>
Will duplicate all output (everything written to stdout or stderr) to the given
file or file descriptor. I<FILE|FD> can either be a (previously opened for
writing) file descriptor (must be > 2), or a file which will then be opened in
append mode.
=item B<-q, --quiet>
Do not print value (if any) on stdout
=item B<-r, --required>
Ignore argument (i.e. exit 3) if no value was specified.
=item B<-s, --safe>[=I<C>]
Ignore argument (i.e. exit 3) if it contains I<C> (defaults to I</>).
=item B<-V, --version>
Show version information and exit.
=back
=head1 DESCRIPTION
B<aa-incmdline>(1) is a small helper to parse arguments from the kernel command
line. It will read I</proc/cmdline> (or I<FILE> specified with B<--file>) and
look for an argument I<NAME>. If reading the file fails, it exits 2. If no
I<NAME> was specified, it exits 1.
If there's no such argument on the command line, or B<--safe> was used and the
argument's value contains I<C>, or there's no value and B<--required> was used,
it exits 4; Else it exits 0.
If the argument had a value specified it will be printed on stdout unless
B<--quiet> was used.
=head1 RETURN CODES
Return codes are somewhat unified inside B<anopa>. Odd return codes represent
fatal errors, and are detailled in B<anopa-rc>(1)
Possible even return codes for B<aa-incmdline>(1) are as described above.