Screen blanks when exiting vi and more


 
Thread Tools Search this Thread
Operating Systems AIX Screen blanks when exiting vi and more
# 1  
Old 02-11-2013
Screen blanks when exiting vi and more

I have just installed AIX 7.1 on a new system, and find that it displays the same annoying behaviour the you find in Linux:

In an xterm, when you quit vim or less, the file listed in the terminal window is blanked out and replaced with whatever was there before.

In vim there is a couple of settings in the config file (.vimrc) and less can be controlled with an environment variable. However, according to the output from truss, vi in AIX does not look for .vimrc or anything similar, so how can I stop this behaviour?
# 2  
Old 02-11-2013
This is only a partial solution but you might be interested in this thread.

I am still looking for a solution for vim, if not for AIX then for Linux as i find that behavior equally annoying.

I hope this helps.

bakunin
# 3  
Old 02-11-2013
Thanks! I know how to do in Linux:

for vim, add the following to your ~/.vimrc:

Code:
set t_ti= t_te=

and for less, the following env var:

Code:
LESS=X

- similar to what you describe for more
This User Gave Thanks to jandersen For This Post:
# 4  
Old 02-11-2013
vi looks for .exrc
# 5  
Old 02-11-2013
Quote:
Originally Posted by jandersen
for vim, add the following to your ~/.vimrc:

Code:
set t_ti= t_te=

Phantastic! Many thanks for this, it will become perhaps the first line in my "~/.exrc".

I have noticed, though, that the overwhelming majority of lines in my vim-configuration deal with switching off all the annoying default of this "emacs in disguise". If i ever want to play video games i'll buy a C64, my editor only needs to edit files, mumble, grumble, ...

bakunin
# 6  
Old 02-12-2013
You're welcome :-)

One of the very first things I do on a new installation is to simply remove everything in vimrc, set it to compatible (because I work on many different UNIXes) and turn off the $&£&^£%^£ screen blanking. This is my usual system wide vimrc:

Code:
set t_ti= t_te=
set compatible
syntax off

Sometimes it seems the screen blanking settings in the system wide vimrc don't work - but they seem to always work in ~/.vimrc.
This User Gave Thanks to jandersen For This Post:
# 7  
Old 02-12-2013
OK. I mentioned .exrc and tried the set commands you are mentioning for vim, but I do not seem to get the expected results with "plain" vi (MORE works, but when in /etc/environment the line should be
Code:
MORE=-W notite

i.e., no dblQuote "
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Leading blanks

Hi Ich have a list as follows 73 5 100 45 81 4 and I would like to have an output (on screen) like that 73 5 100 45 81 4 (6 Replies)
Discussion started by: lazybaer
6 Replies

2. UNIX for Dummies Questions & Answers

Accidentally made a screen within a screen - how to move it up one level?

I made a screen within a screen. Is there a way to move the inner screen up one level so that it is at the same level as the first screen running from the shell? (2 Replies)
Discussion started by: phpchick
2 Replies

3. Shell Programming and Scripting

Removing blanks, spaces

I have pipe separated file with lots of blank spaces. After using sed -e 's/ *| */|/g' this command ,its giving me output as TT0000013101640| HCAMBLAMCNB010|Jul 3 2012 11:14AM| HARYANA| Bangali Mohalla | TCL-UBR|9368040005|9355264655|9218509220|NULL ... (5 Replies)
Discussion started by: sususa
5 Replies

4. Red Hat

command line tool to disable screen lock and/or screen saver

Hi, I have a simple question : how to disable screen lock and/or sreen saver with command line with RHEL5.4 ? (1 Reply)
Discussion started by: albator1932
1 Replies

5. Shell Programming and Scripting

Replace blanks with | (pipe)

Hello, I'm trying to replace the first x number of spaces in a line with a |. Right now I'm using a very inefficient syntax to accomplish the task and was looking to simplify it. I have several cases were the pipes need to replace just the first space on the line, which I did a simple... (11 Replies)
Discussion started by: bd_joy
11 Replies

6. OS X (Apple)

Virtual screen accessed by Screen Sharing

Hi, I'm trying to create a virtual screen, (maybe xvfb? or any other virtual screen buffer) and be able to use Screen Sharing to connect to it. The setup is that I have a Mac Mini connected to the TV. But when my girlfriend is using Front Row, I can't use Screen Sharing at the same time from... (0 Replies)
Discussion started by: linge
0 Replies

7. Programming

Blanks vs: Nulls

I'm relatively new to Pro*C programming. In the following example: char name; EXEC SQL SELECT 'John Doe' INTO :name FROM DUAL; "John Doe" is in positions 0-7, blanks in 8-19, and a null in 20. I would really prefer the null to be in position 8 and I don't care what's after that. I wrote a... (1 Reply)
Discussion started by: ebock
1 Replies

8. UNIX for Advanced & Expert Users

numbering blanks

hello i'm trying to figure out how to number a blank line. For instance this : sed '/./=' file | sed '/./N; s/\n/ /' gives me 1 aaaa 2 bbbbbb 4 cccccc 5 ffkkkfff 6 ffsdfdfs I would like something like this: 1 aaaaa 2 3 bbbbbb 4 5 cccccc And so... (6 Replies)
Discussion started by: wisher115
6 Replies

9. Shell Programming and Scripting

blanks in file name

I have a file with a list of filenames. I want to work loopwise through the file and operate on each of the listed files. Normally I'd do something like: for file in `cat $mydir/file-list` do echo $file >> $mydir/my.log cp $mydir/$file $newdir done the problem is that my... (1 Reply)
Discussion started by: LisaS
1 Replies

10. Shell Programming and Scripting

blanks in an awk comand

Hi, Im trying to write something that will report if a filesytem is over 80% but the problem is the output reports on a dir that is a 9%. any ideas? this is what I have ************************************************* if then param=90 else param=$1 fi df -kl | grep... (1 Reply)
Discussion started by: collie
1 Replies
Login or Register to Ask a Question