LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 03-25-2005, 05:34 PM   #1
lowpro2k3
Member
 
Registered: Oct 2003
Location: Canada
Distribution: Slackware
Posts: 340

Rep: Reputation: 30
Question for programmers who use Vi(m)


Do any of you work remotely on machines, possibly using putty on windows? I do all the time, and I find when I'm programming, I dont like one of the colors in Vi(m). Its the dark/bright blue color, usually used for comments.

I mainly SSH into a linux server or workstation from a windows workstation at school (through putty). I have an account that i use, and I'd like to automatically change that color in Vim when I log in. I cant read comments at all in code, I swear I have to squint to read them. I need my comments!
 
Old 03-25-2005, 06:02 PM   #2
jtshaw
Senior Member
 
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Blog Entries: 1

Rep: Reputation: 67
I know exactly what your going through It is hard to read that dark blue.

I have this dealing with syntax highlighting in my .vimrc file:

Code:
" some colors:  "white on black"
hi normal   ctermfg=white  ctermbg=black guifg=white  guibg=black
hi COMMENT ctermfg=cyan ctermbg=black
" Syntax Hilighting
 
Old 03-25-2005, 06:33 PM   #3
lowpro2k3
Member
 
Registered: Oct 2003
Location: Canada
Distribution: Slackware
Posts: 340

Original Poster
Rep: Reputation: 30
hmm... I dont have my own .vimrc file in my /home/user directory, I assume theres like a global vimrc file on the server? If I write my own and stick it in my /home directory, will it override settings from the global one?

I knew I wasn't alone with this problem
 
Old 03-25-2005, 06:56 PM   #4
jtshaw
Senior Member
 
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Blog Entries: 1

Rep: Reputation: 67
There is usually a global file in /etc. Creating your own will override that file.

I personally don't use a lot of settings, my entire file looks like this:

Code:
set cindent
set shiftwidth=8
set tabstop=8
set expandtab
set ruler
syntax on
" some colors:  "white on black"
hi normal   ctermfg=white  ctermbg=black guifg=white  guibg=black
hi nontext  ctermfg=blue   ctermbg=black guifg=blue   guibg=black
hi COMMENT ctermfg=cyan ctermbg=black
" Syntax Hilighting
set nowrap

" enables real tabs for Makefiles only
augroup Makefile
au!
au BufReadPre Makefile set noexpandtab
augroup END

" vim -b : edit binary using xxd-format!
augroup Binary
au!
au BufReadPre  *.bin let &bin=1
au BufReadPost *.bin if &bin | %!xxd
au BufReadPost *.bin set ft=xxd | endif
au BufWritePre *.bin if &bin | %!xxd -r
au BufWritePre *.bin endif
au BufWritePost *.bin if &bin | %!xxd
au BufWritePost *.bin set nomod | endif
augroup END
If you are going to do any tab expansion you must make sure you turn it off for Makefiles or make will puke.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
JTextArea Question for Java Programmers Diederick Programming 1 09-16-2005 08:25 PM
Question for KDE programmers irfanhab Programming 2 08-23-2004 02:12 PM
Question to programmers of Linux Falelorn Programming 8 06-29-2004 06:30 PM
For the QT Programmers kusio Programming 3 04-16-2003 03:00 PM
Question on programmERS, not programING MasterC Programming 5 09-01-2002 04:13 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 10:47 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration