Minor usage tweak for sed.
Denys Vlasenko
vda.linux at googlemail.com
Tue Oct 27 08:12:26 UTC 2009
On Mon, Oct 26, 2009 at 10:04 PM, Rob Landley <rob at landley.net> wrote:
> Makes it slightly smaller and (in my opinion) clearer.
>
> diff --git a/include/usage.h b/include/usage.h
> index 227ed80..3138371 100644
> --- a/include/usage.h
> +++ b/include/usage.h
> @@ -3776,14 +3776,12 @@
> "Options:" \
> "\n -e CMD Add CMD to sed commands to be executed" \
> "\n -f FILE Add FILE contents to sed commands to be executed" \
> - "\n -i Edit files in-place" \
> + "\n -i Edit files in-place (default uses stdout for all output)" \
> "\n -n Suppress automatic printing of pattern space" \
> "\n -r Use extended regex syntax" \
> "\n" \
> - "\nIf no -e or -f is given, the first non-option argument is taken as the sed" \
> - "\ncommand to interpret. All remaining arguments are names of input files; if no" \
> - "\ninput files are specified, then the standard input is read. Source files" \
> - "\nwill not be modified unless -i option is given." \
> + "\nIf no -e or -f, the first non-option argument is the sed command string." \
> + "\nRemaining arguments are input files (stdin if none)."
>
> #define sed_example_usage \
> "$ echo \"foo\" | sed -e 's/f[a-zA-Z]o/bar/g'\n" \
Applied, with this change on top:
- "\n -i Edit files in-place (default uses stdout for
all output)" \
+ "\n -i Edit files in-place (else sends result to stdout)" \
Does it sound ok?
--
vda
More information about the busybox
mailing list