You are not logged in.

#1 2014-05-23 15:43:01

EvanPurkhiser
Member
From: San Francisco
Registered: 2010-08-17
Posts: 225
Website

TERMINFO environment dropped when using sudo -E or sudioedit

Hey guys,

I use the termite terminal which uses the termcap file 'xterm-termite'. Since this is non-standard I have to copy over the termcap file to remote machines I commonly work on. I put this file in `$HOME/.local/share/terminfo/x/xterm-termite` and set my $TERMINFO environment variable to `$HOME/.local/share/terminfo`.

When I use sudo -E or sudoedit it looks like the TERMINFO environment variable is getting lost. So vim won't display things properly (no colors) and other silly problems (LESS 'Warning terminal is not fully functional").

Why does the TERMINFO get dropped when my other environment variables stick around?

Edit: Looking at the TROUBLESHOOTING document, I see that TERMINFO is removed "to guard against shared library spoofing, shell voodoo, and kerberos server spoofing."

What are my options? I would really rather not copy my termcap file into /usr/share/terminfo since I might not always have root access on my remote machines.

Edit 2: I feel a little silly. I just said I may not have root access. But if I'm using sudo it's almost guaranteed for root access! I'll leave this thread open for other solutions though.

Last edited by EvanPurkhiser (2014-05-23 16:07:45)

Offline

Board footer

Powered by FluxBB