From 1d02b841f08195b627c31d7952b92504273464fb Mon Sep 17 00:00:00 2001 From: Moritz Grimm Date: Fri, 15 May 2015 22:47:19 +0200 Subject: [PATCH] Update ezstream-file(1) for new command line arguments --- doc/ezstream-file.sh.1.in.in | 24 ++++++++++-------------- src/ezstream-file.sh.in | 19 ++++++++----------- 2 files changed, 18 insertions(+), 25 deletions(-) diff --git a/doc/ezstream-file.sh.1.in.in b/doc/ezstream-file.sh.1.in.in index 6a8ee1a..771320a 100644 --- a/doc/ezstream-file.sh.1.in.in +++ b/doc/ezstream-file.sh.1.in.in @@ -21,7 +21,7 @@ .Sh SYNOPSIS .Nm .Bk -words -.Op Fl hmnqVv +.Op Fl hqrVv .Op Fl T Ar cfg_template .Op Ar .Ek @@ -42,7 +42,7 @@ command line argument, or the environment variable. .Pp The configuration template must be a valid playlist configuration, and contain -the follwing configuration statement: +the follwing configuration statement inside the \& block: .Bd -literal -offset indent \&%FILENAME%\& .Ed @@ -60,18 +60,6 @@ binary. .It Fl h Print a summary of available command line parameters with short descriptions and exit. -.It Fl m -.Po -Passed to -.Nm ezstream . -.Pc -Disable all metadata updates and keep existing metadata in streams untouched. -.It Fl n -.Po -Passed to -.Nm ezstream . -.Pc -Normalize metadata strings by removing excess whitespaces. .It Fl q .Po Passed to @@ -79,6 +67,14 @@ Passed to .Pc Be more quiet. Suppress the output that external programs send to standard error. +.It Fl r +.Po +Passed to +.Nm ezstream . +.Pc +Show a real-time stream status information line on standard output. +Implies +.Fl q . .It Fl T Ar cfg_template Use the configuration in .Ar cfg_template , diff --git a/src/ezstream-file.sh.in b/src/ezstream-file.sh.in index 637f354..59e8edd 100644 --- a/src/ezstream-file.sh.in +++ b/src/ezstream-file.sh.in @@ -21,10 +21,10 @@ _myname="$(basename $0)" _filename_placeholder="%FILENAME%" -_opt_string="hmnqT:Vv" +_opt_string="hqrT:Vv" print_usage() { - echo "usage: ${_myname} [-hmnqVv] [-T cfg_template] [file ...]" >&2 + echo "usage: ${_myname} [-hqrVv] [-T cfg_template] [file ...]" >&2 } print_usage_help() @@ -32,23 +32,22 @@ print_usage_help() cat << __EOT >&2 -h print this help and exit - -m [ezstream] disable metadata updates - -n [ezstream] normalize metadata strings -q [ezstream] suppress STDERR output from external en-/decoders + -r [ezstream] show real-time stream information on stdout -T template run ezstream using template for configuration -V print the version number and exit -v [ezstream] verbose output (use twice for more effect) The configuration template must contain the configuration statement ${_filename_placeholder} +inside the block. See the ezstream-file.sh(1) manual for detailed information. __EOT } -_metadisable="" -_normalize="" _quiet="" +_rtstatus="" _verbose="" _cfg_template="${EZSTREAM_TEMPLATE}" @@ -66,12 +65,10 @@ do print_usage_help exit 0 ;; - -m) - _metadisable="-m"; shift ;; - -n) - _normalize="-n"; shift ;; -q) _quiet="-q"; shift ;; + -r) + _rtstatus="-r"; shift ;; -T) _cfg_template="$2"; shift; shift ;; -V) @@ -144,6 +141,6 @@ else done fi -${EZSTREAM} ${_metadisable} ${_normalize} ${_quiet} ${_verbose} -c "${_cfg}" +${EZSTREAM} ${_quiet} ${_rtstatus} ${_verbose} -c "${_cfg}" exit $?