Reply
Thread Tools
aflegg's Avatar
Posts: 1,463 | Thanked: 81 times | Joined on Oct 2005 @ UK
#11
The problem with using .profile is that XTerm doesn't start login shells, and osso-af-init resets the path at desktop startup (IIRC).

Setting your .profile and then typing sh --login after starting XTerm fixes this.
 
Posts: 16 | Thanked: 25 times | Joined on Dec 2005
#12
It works fine. I use it on my 770. You just have to reboot for the .profile to take effect. I can start an xterm, type 'vim', and there it is.
 
aflegg's Avatar
Posts: 1,463 | Thanked: 81 times | Joined on Oct 2005 @ UK
#13
Originally Posted by Dusty
It works fine. I use it on my 770. You just have to reboot for the .profile to take effect. I can start an xterm, type 'vim', and there it is.
Odd. What OS version have you got?
 
Posts: 29 | Thanked: 5 times | Joined on Sep 2005
#14
Originally Posted by Dusty
It works fine. I use it on my 770. You just have to reboot for the .profile to take effect. I can start an xterm, type 'vim', and there it is.
Thanks for mentioning this! I had been using the 'sh --login' method to use /home/user/.profile. I did not realized that this would work after a reboot. It now finds vim in my path...

Unfortunately, my aliases are not available unless I use the 'sh --login' method. Is there something I need to do differently to make these available? Example:
alias ll='ls -l'
 
Posts: 78 | Thanked: 9 times | Joined on Dec 2005 @ Devon, UK
#15
I've created an entry in the wiki on using xterm that tries to cover what needs to be done to change the .profile. As you'll see in my examples I favour keeping things simple.
 
Posts: 78 | Thanked: 9 times | Joined on Dec 2005 @ Devon, UK
#16
Originally Posted by Neil McAllister
Hey, speaking of VIM... I got it installed, but I couldn't get the carriage return to work. Instead, it inserted a capital "M" and maybe a couple of other garbage characters. I couldn't find a way to remap it with stty. It made it pretty hard to edit any files longer than one line. Anyone have better luck? I installed vim using the gainroot method.
It's probably just a bad habit many of us have picked up. Use o rather than i and you won't have this problem.

Maybe someone could add this to the wiki, perhaps with a link to a vi/vim cheat sheet - there are loads out there.
 
aflegg's Avatar
Posts: 1,463 | Thanked: 81 times | Joined on Oct 2005 @ UK
#17
I've updated the wiki and the vim port page with the "proper" vim-level fix for the cursor keys/enter problem:

Put the following in /home/user/.vimrc:

Code:
set nocompatible
That removes some of vim's backwards-compatibility with the original vi which is causing the problem.

HTH,

Andrew

Last edited by aflegg; 2005-12-30 at 22:29. Reason: .vimrc != .profile (Doh...)
 
Posts: 78 | Thanked: 9 times | Joined on Dec 2005 @ Devon, UK
#18
I've put it in .vimrc and it did the trick.
 
Posts: 49 | Thanked: 11 times | Joined on Nov 2005 @ Philly
#19
Yet another method:

ssh into your 770 and cut and paste these lines to permanently modify your .profile:

echo 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/var/lib/install/usr/lib' >> /home/user/.profile
echo 'export PATH=$PATH:/var/lib/install/usr/bin:/var/lib/install/usr/sbin' >> /home/user/.profile
echo 'set nocompatible' >> /home/user/.vimrc
 
Posts: 191 | Thanked: 9 times | Joined on Nov 2005
#20
Maybe this is a stupid question but I managed to get Vim working whenever I run Xterminal. That's all good but if I then use sudo gainroot to get root access it no longer works. Where do I need to add those variables so Vim still works? Yes, I am a Linux newbie
 
Reply

Thread Tools

 
Forum Jump


All times are GMT. The time now is 18:28.