mailr24412 - in /trunk: dep_check.py relax.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on July 02, 2014 - 15:38:
Author: bugman
Date: Wed Jul  2 15:38:13 2014
New Revision: 24412

URL: http://svn.gna.org/viewcvs/relax?rev=24412&view=rev
Log:
Fix for the breakage of the relax help system. 

This was reported at 
http://thread.gmane.org/gmane.science.nmr.relax.devel/6481.

The problem was that the TERM environmental variable was turned off to avoid 
the GNU readline
library on Linux systems emitting the ^[[?1034h escape code.  See the message 
at
http://thread.gmane.org/gmane.science.nmr.relax.devel/6481/focus=6489 for 
more details.  However the
Python help system obviously requires this environmental variable.  Now only 
if the TERM variable is
set to 'xterm' will it be reset, and to 'linux' instead of the blank string 
''.


Modified:
    trunk/dep_check.py
    trunk/relax.py

Modified: trunk/dep_check.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/dep_check.py?rev=24412&r1=24411&r2=24412&view=diff
==============================================================================
--- trunk/dep_check.py  (original)
+++ trunk/dep_check.py  Wed Jul  2 15:38:13 2014
@@ -88,7 +88,7 @@
 try:
     import os
     if os.environ['TERM'] == 'xterm':
-        os.environ['TERM'] = ''
+        os.environ['TERM'] = 'linux'
     import readline
     readline_module = True
 except ImportError:

Modified: trunk/relax.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/relax.py?rev=24412&r1=24411&r2=24412&view=diff
==============================================================================
--- trunk/relax.py      (original)
+++ trunk/relax.py      Wed Jul  2 15:38:13 2014
@@ -38,7 +38,8 @@
 
 # Eliminate the ^[[?1034h escape code being produced on Linux systems by the 
import of the readline module.
 import os
-os.environ['TERM'] = ''
+if os.environ['TERM'] == 'xterm':
+    os.environ['TERM'] = 'linux'
 
 # Set up the Python 2 and 3 work-arounds.
 import lib.compat




Related Messages


Powered by MHonArc, Updated Wed Jul 02 16:00:03 2014