quilt-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Quilt-dev] [PATCH 1/1] Make LESS env variable value user configurable.


From: kspillner
Subject: [Quilt-dev] [PATCH 1/1] Make LESS env variable value user configurable.
Date: Mon, 05 Nov 2012 12:35:06 -0600
User-agent: quilt/0.60-1

Add a QUILT_LESS_ARGS variable that can be used to configure what quilt will
set LESS to when LESS is undefined.  Defaults to -FSRX so no functional change
in the default case, but allows users to drop the -F argument as needed (for
example, when using a multiline shell prompt) without explicitly setting LESS.

Index: quilt/doc/quilt.1.in
===================================================================
--- quilt.orig/doc/quilt.1.in   2012-11-05 10:54:33.961968000 -0600
+++ quilt/doc/quilt.1.in        2012-11-05 12:05:53.195577294 -0600
@@ -207,6 +207,13 @@
 is set, "less" is used.  An empty value indicates that no pager should be
 used.
 
+.IP QUILT_LESS_ARGS 4
+
+The value quilt sets in the LESS environment variable before starting the
+pager regardless of which pager quilt is configured to use.  Defaults to
+the existing value of LESS, or "-FRSX" if LESS is undefined.
+
+
 .IP EDITOR 4
 
 The program to run to edit files.  If it isn't redefined in the
Index: quilt/quilt/scripts/patchfns.in
===================================================================
--- quilt.orig/quilt/scripts/patchfns.in        2012-11-05 10:54:33.971967000 
-0600
+++ quilt/quilt/scripts/patchfns.in     2012-11-05 11:48:25.974829031 -0600
@@ -1002,7 +1002,8 @@
 
        [ -z "$QUILT_PAGER" -o "$QUILT_PAGER" = "cat" ]  && return 0
 
-       export LESS="${LESS:-FRSX}"
+       QUILT_LESS_ARGS="${QUILT_LESS_ARGS-${LESS:-FRSX}}"
+       export LESS="${QUILT_LESS_ARGS}"
 
        # NOTE: with "exec > >($pager)" there is no way to get the pid of the
        # pager so we can't wait for it to complete.  Otherwise we wouldn't




reply via email to

[Prev in Thread] Current Thread [Next in Thread]