diff options
Diffstat (limited to 'text-utils')
| -rw-r--r-- | text-utils/column.1.adoc | 2 | ||||
| -rw-r--r-- | text-utils/column.c | 4 | ||||
| -rw-r--r-- | text-utils/more.c | 6 |
3 files changed, 7 insertions, 5 deletions
diff --git a/text-utils/column.1.adoc b/text-utils/column.1.adoc index 69f2f794ff..e1e5a1c6f4 100644 --- a/text-utils/column.1.adoc +++ b/text-utils/column.1.adoc @@ -99,7 +99,7 @@ Omit printing the header. This option allows having user-supplied column names o *-o, --output-separator* _string_:: Column delimiter for table output (default is two spaces). -*-s, --separator* _separators_:: +*-s, --input-separator, --separator* _separators_:: Possible input-item delimiters (default is whitespace). *-S, --use-spaces* _number_:: diff --git a/text-utils/column.c b/text-utils/column.c index 7a37cb886c..5a9e9a03b6 100644 --- a/text-utils/column.c +++ b/text-utils/column.c @@ -1021,7 +1021,8 @@ static void __attribute__((__noreturn__)) usage(void) fputs(_(" -c, --output-width <width> width of output in number of characters\n"), out); fputs(_(" -o, --output-separator <string> columns separator for table output\n" " (default is two spaces)\n"), out); - fputs(_(" -s, --separator <string> possible table delimiters\n"), out); + fputs(_(" -s, --input-separator, --separator <string>\n" + " possible table delimiters\n"), out); fputs(_(" -x, --fillrows fill rows before columns\n"), out); fputs(_(" -S, --use-spaces <number> minimal whitespaces between columns (no tabs)\n"), out); @@ -1059,6 +1060,7 @@ int main(int argc, char **argv) { "color", optional_argument, NULL, OPT_COLOR }, { "fillrows", no_argument, NULL, 'x' }, { "help", no_argument, NULL, 'h' }, + { "input-separator", required_argument, NULL, 's' }, /* alias for --separator */ { "json", no_argument, NULL, 'J' }, { "keep-empty-lines", no_argument, NULL, 'L' }, { "output-separator", required_argument, NULL, 'o' }, diff --git a/text-utils/more.c b/text-utils/more.c index 4980aef4ca..bc04064cf1 100644 --- a/text-utils/more.c +++ b/text-utils/more.c @@ -89,6 +89,7 @@ #include "widechar.h" #include "closestream.h" #include "env.h" +#include "shells.h" #ifdef TEST_PROGRAM # define NON_INTERACTIVE_MORE 1 @@ -174,7 +175,7 @@ struct more_control { int next_jump; /* number of lines to skip ahead */ char **file_names; /* The list of file names */ int num_files; /* Number of files left to process */ - char *shell; /* name of the shell to use */ + const char *shell; /* name of the shell to use */ int sigfd; /* signalfd() file descriptor */ sigset_t sigset; /* signal operations */ char *line_buf; /* line buffer */ @@ -2110,8 +2111,7 @@ static void initterm(struct more_control *ctl) if ((ctl->backspace_ch = tigetstr(TERM_BACKSPACE)) == NULL) ctl->backspace_ch = BACKSPACE; - if ((ctl->shell = getenv("SHELL")) == NULL) - ctl->shell = _PATH_BSHELL; + ctl->shell = ul_default_shell(0, NULL); } int main(int argc, char **argv) |
