less/less-429-shell.patch

62 lines
2.5 KiB
Diff
Raw Normal View History

Index: filename.c
===================================================================
--- filename.c.orig 2009-07-06 22:52:23.000000000 +0200
+++ filename.c 2009-07-10 10:23:12.000000000 +0200
@@ -577,7 +577,7 @@ shellcmd(cmd)
#if HAVE_SHELL
char *shell;
- shell = lgetenv("SHELL");
+ shell = lgetenv("LESSSHELL");
if (shell != NULL && *shell != '\0')
{
char *scmd;
Index: less.hlp
===================================================================
--- less.hlp.orig 2009-07-10 10:23:07.000000000 +0200
+++ less.hlp 2009-07-10 10:23:12.000000000 +0200
@@ -95,7 +95,7 @@
___<_n_a_m_e_> Display the setting of an option, by name.
+_c_m_d Execute the less cmd each time a new file is examined.
- !_c_o_m_m_a_n_d Execute the shell command with $SHELL.
+ !_c_o_m_m_a_n_d Execute the shell command with $LESSSHELL.
|XX_c_o_m_m_a_n_d Pipe file between current pos & mark XX to shell command.
v Edit the current file with $VISUAL or $EDITOR.
V Print version number of "less".
Index: less.nro
===================================================================
--- less.nro.orig 2009-07-10 10:23:07.000000000 +0200
+++ less.nro 2009-07-10 10:23:12.000000000 +0200
@@ -395,7 +395,7 @@ current file.
A pound sign (#) is replaced by the name of the previously examined file.
"!!" repeats the last shell command.
"!" with no shell command simply invokes a shell.
-On Unix systems, the shell is taken from the environment variable SHELL,
+On Unix systems, the shell is taken from the environment variable LESSSHELL,
or defaults to "sh".
On MS-DOS and OS/2 systems, the shell is the normal command processor.
.IP "| <m> shell-command"
@@ -1667,7 +1667,7 @@ LINES and COLUMNS environment variables.
.IP PATH
User's search path (used to find a lesskey file
on MS-DOS and OS/2 systems).
-.IP SHELL
+.IP LESSSHELL
The shell used to execute the ! command, as well as to expand filenames.
.IP TERM
The type of terminal on which
Index: lsystem.c
===================================================================
--- lsystem.c.orig 2009-07-06 22:52:23.000000000 +0200
+++ lsystem.c 2009-07-10 10:23:12.000000000 +0200
@@ -129,7 +129,7 @@ lsystem(cmd, donemsg)
*/
#if HAVE_SHELL
p = NULL;
- if ((shell = lgetenv("SHELL")) != NULL && *shell != '\0')
+ if ((shell = lgetenv("LESSSHELL")) != NULL && *shell != '\0')
{
if (*cmd == '\0')
p = save(shell);