Color code my vi


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Color code my vi
# 1  
Old 11-10-2008
Question Color code my vi

i am running under ssh
i want to know how to make vi color code my bash scripting

like how do i setup vim in ssh
# 2  
Old 11-10-2008
in your .vimrc have
Code:
set nocompatible
syntax on

if that still doesn't produce coloured output, ensure that the filetyoe is being correctly recognised
Code:
:set filetype?

will show you what vim thinks the filetype is
Code:
:set filetype=sh

will set it to be a shell script.
Vim should then automatically load the syntax files for colouring and indentation.
Also ensure that the TERM type is set in the shell that ssh gives you to be one of the colour enabled ones.
If you continue to have vim specific problems the good people over at the vim list will be only to happy to help (vim-use@vim.org)
 
Login or Register to Ask a Question

Previous Thread | Next Thread

2 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Handle color code

p1=text1 p2=text2(in red color) when i am trying to replace $p1 with $p2, content of the file from text2 become red. so when i open that file using vi its showing color code before tex2. please suggest me how to omit that color code and make content of that file in default color? (1 Reply)
Discussion started by: Biplab
1 Replies

2. UNIX for Dummies Questions & Answers

How to change the background color in the init 3 mode(not line color)

Hello, I am using RHEL 6.1 on VMware I am searching for a way to change background color (not line by line color wich one can using tput command) basically changing the color of the whole screen to white instead of the default black and changing font color to black and alos would like to... (2 Replies)
Discussion started by: Dexobox
2 Replies
Login or Register to Ask a Question