Properly excluding the --quiet option when --disable-nanorc was given.

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5053 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
master
Benno Schulenberg 2014-07-02 19:57:23 +00:00
parent 6c86ee1a5b
commit 85ddc718f8
3 changed files with 11 additions and 2 deletions

View File

@ -9,6 +9,8 @@
* src/search.c (findnextstr): Replace a call of old wrapper * src/search.c (findnextstr): Replace a call of old wrapper
'getfuncfromkey()' with a call of new 'func_from_key()'. 'getfuncfromkey()' with a call of new 'func_from_key()'.
* src/winio.c (getfuncfromkey): Delete now unneeded wrapper. * src/winio.c (getfuncfromkey): Delete now unneeded wrapper.
* src/nano.c (usage, main), doc/texinfo/nano.texi: Properly
exclude the --quiet option when --disable-nanorc was given.
2014-07-01 Benno Schulenberg <bensberg@justemail.net> 2014-07-01 Benno Schulenberg <bensberg@justemail.net>
* src/browser.c (do_browser), src/help.c (do_help): Make sure * src/browser.c (do_browser), src/help.c (do_help): Make sure

View File

@ -1322,8 +1322,9 @@ Disable support for reading the nanorc files at startup. With such
support, you can store custom settings in a system-wide and a per-user support, you can store custom settings in a system-wide and a per-user
nanorc file rather than having to pass command-line options to get nanorc file rather than having to pass command-line options to get
the desired behavior. See @xref{Nanorc Files}, for more info. the desired behavior. See @xref{Nanorc Files}, for more info.
This also eliminates the -I command-line option, which inhibits the Disabling this also eliminates the -I and -q command-line options;
reading of these nanorcfiles. the first inhibits the reading of nanorcfiles, and the second
suppresses warnings about errors in those files.
@item --disable-operatingdir @item --disable-operatingdir
Disable setting the operating directory. This also eliminates the -o Disable setting the operating directory. This also eliminates the -o

View File

@ -863,6 +863,8 @@ void usage(void)
#ifndef DISABLE_HISTORIES #ifndef DISABLE_HISTORIES
print_opt("-H", "--historylog", print_opt("-H", "--historylog",
N_("Log & read search/replace string history")); N_("Log & read search/replace string history"));
#endif
#ifndef DISABLE_NANORC
print_opt("-I", "--ignorercfiles", print_opt("-I", "--ignorercfiles",
N_("Don't look at nanorc files")); N_("Don't look at nanorc files"));
#endif #endif
@ -924,8 +926,10 @@ void usage(void)
#endif #endif
print_opt("-p", "--preserve", print_opt("-p", "--preserve",
N_("Preserve XON (^Q) and XOFF (^S) keys")); N_("Preserve XON (^Q) and XOFF (^S) keys"));
#ifndef DISABLE_NANORC
print_opt("-q", "--quiet", print_opt("-q", "--quiet",
N_("Silently ignore startup issues like rc file errors")); N_("Silently ignore startup issues like rc file errors"));
#endif
#ifndef DISABLE_WRAPJUSTIFY #ifndef DISABLE_WRAPJUSTIFY
print_opt(_("-r <#cols>"), _("--fill=<#cols>"), print_opt(_("-r <#cols>"), _("--fill=<#cols>"),
N_("Set hard-wrapping point at column #cols")); N_("Set hard-wrapping point at column #cols"));
@ -2356,9 +2360,11 @@ int main(int argc, char **argv)
case 'p': case 'p':
SET(PRESERVE); SET(PRESERVE);
break; break;
#ifndef DISABLE_NANORC
case 'q': case 'q':
SET(QUIET); SET(QUIET);
break; break;
#endif
#ifndef DISABLE_WRAPJUSTIFY #ifndef DISABLE_WRAPJUSTIFY
case 'r': case 'r':
if (!parse_num(optarg, &wrap_at)) { if (!parse_num(optarg, &wrap_at)) {