commit fdd3becc1e7dfda2cf0feb3fe5337be168314da0
parent c136f75f622dc908aca72469438ab9d1410054b3
Author: David Lawrence Ramsey <pooka109@gmail.com>
Date: Sun, 7 Nov 2004 21:30:55 +0000
allow blank buffers at the "Execute Command" prompt, and document it in
the help text
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2085 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
Diffstat:
3 files changed, 11 insertions(+), 12 deletions(-)
diff --git a/ChangeLog b/ChangeLog
@@ -191,6 +191,8 @@ CVS code -
- Update the help text to mention replacing and spell checking
only selected text, and also add a few cosmetic fixes to it.
(DLR)
+ - Update the help text to mention how to get a blank buffer at
+ the "Execute Command" prompt. (DLR)
do_prev_word()
- Tweak to avoid an infinite loop, since current_x is now a
size_t and hence is unsigned. (DLR)
diff --git a/src/files.c b/src/files.c
@@ -540,15 +540,12 @@ void do_insertfile(
#endif
"./");
- /* If we're in multibuffer mode and file insertion mode, and the
- * filename is blank, open a new buffer instead of canceling. */
+ /* If we're in multibuffer mode and the filename or command is
+ * blank, open a new buffer instead of canceling. */
if (i == -1 || (i == -2
#ifdef ENABLE_MULTIBUFFER
&& !ISSET(MULTIBUFFER)
#endif
-#ifndef NANO_SMALL
- && !execute
-#endif
))
{
statusbar(_("Cancelled"));
diff --git a/src/nano.c b/src/nano.c
@@ -304,11 +304,10 @@ void help_init(void)
"or --multibuffer command line flags, the Meta-F toggle, or "
"a nanorc file, inserting a file will cause it to be "
"loaded into a separate buffer (use Meta-< and > to switch "
- "between file buffers).\n\n If you need another blank "
- "buffer, do not enter any filename, or type in a "
- "nonexistent filename at the prompt and press "
- "Enter.\n\n The following function keys are "
- "available in Insert File mode:\n\n");
+ "between file buffers). If you need another blank buffer, "
+ "do not enter any filename, or type in a nonexistent "
+ "filename at the prompt and press Enter.\n\n The following "
+ "function keys are available in Insert File mode:\n\n");
else if (currshortcut == writefile_list)
htx = N_("Write File Help Text\n\n "
"Type the name that you wish to save the current file "
@@ -356,8 +355,9 @@ void help_init(void)
htx = N_("External Command Help Text\n\n "
"This menu allows you to insert the output of a command "
"run by the shell into the current buffer (or a new "
- "buffer in multibuffer mode).\n\n The following keys are "
- "available in this mode:\n\n");
+ "buffer in multibuffer mode). If you need another blank "
+ "buffer, do not enter any command.\n\n The following keys "
+ "are available in this mode:\n\n");
#endif
else
/* Default to the main help list. */