Syntax highlighting in the "vi".

Can the editor "vi" highlight syntax?:
- Shell
- C / Cpp
- Pyhton

I know of the existence of the editor "Vim", but would like to work on "vi".
 
Some background info: vi and vim are often thought to be pretty much the same thing, but they really are not. Vi is the barebones version of the editor, vim basically is vi with all sorts of nifty stuff added to it. Syntax highlighting is one of those things that you get with vim but not with vi.

Fonz

Edited to add: vi is part of the base system and is almost certainly available on any UNIX system. Vim is an application that needs to be installed.
 
vi editor installed on my system by default.
I thought not to impose too much.
vim a lot of sets of dependencies. (during installation)

And editor of "ee" is also not able to highlight?

Ok. I will install vim.

Thanks all.
 
doorways said:
And editor of "ee" is also not able to highlight?

ee() is meant to be as small as possible. I'm sure it wont have syntax highlight. If you prefer a editor like ee you may want to look at nano or pico. vim is what most vi users use when the need for syntax highlighting is needed.

when you get vim installed you may need to run:

[CMD=":"]syn on[/CMD] or set syntax on in your .vimrc
 
there is also midnight commander integrated editor, can be used stand alone misc/mc a norton commander clone, very close to far manager if you already used it on win cmd line, same commands and interface (at most).
 
Well, since the holy war has started, I'm going to completely ignore the original post and mention a common alternative to vi(m), editors/emacs. This page might be useful: http://en.wikipedia.org/wiki/Editor_war, although slightly outdated.

A warning though... Being caught using emacs by your BSD friends will feel like being caught with a dirty magazine. You'll feel ashamed at first, but after awhile you'll stop caring what they think.
 
mingrone said:
Well, since the holy war has started, I'm going to completely ignore the original post and mention a common alternative to vi(m), editors/emacs. This page might be useful: http://en.wikipedia.org/wiki/Editor_war, although slightly outdated.
Make sure to note the "editors" part of editors/emacs, it may be as astonishing for you to find it there as it was for me. I guess they let similarly tightly focused "do one thing and do it well" editors like libreoffice/openoffice in there too.
A warning though... Being caught using emacs by your BSD friends will feel like being caught with a dirty magazine. You'll feel ashamed at first, but after awhile you'll stop caring what they think.
Most people would avoid getting caught reading dirty magazines. It takes a Radically Majorly Special person to be able to shrug off those sort of outdated social mores and just let it all hang out like that, so to speak. More power to you. ;)

Edit: Apologies if I struck a little below the belt there. I don't care one way or another which editor a person chooses, and AFAIK emacs is as valid a choice as vim. I actually started out using emacs (an emacs user helped set up my config file). Ironically, somehow the config file got deleted and I started using vim some time after that, pretty much exactly as had happened to Tim O'Reilly. Excerpt:
When vi loyalist O'Reilly wrote in Ask Tim that he first shifted from EMACS to vi only after his customized EMACS profile was trashed, it was one of those subtle jabs vi users like to use against EMACS.
 
O, Thank you all!
I used vi editor – it is very good editor for me.
Emacs or other editors – I am ignor.

Vim it is a expansion vi – I be use vim editor.
I like vi - so, I like vim.

Originally Posted by SirDice.
Install editors/vim-lite. It has less dependencies.
Thanks.
 
vermaden said:
I remember that there is EMACS under AMIGA Workbench 2.0, but I cant tell for Commodore 64 since I did not own it.

That doesn't surprise me. The Amiga's have plenty of memory to run EMACS. Even vim is available for them (although it is an older version).
 
SirDice said:
Install editors/vim-lite. It has less dependencies.

This actually give the op the answer. I actually didn't catch it but this is correct. editors/vim-lite is the cli only variant and the one I install and it depends on nothing but itself and patch-level. I have actually had to install this on a user only level install by hand. simple, depends on stuff in base and that's it, install.

carlton_draught said:
Vim is what should be used when serious work is to be done. For editing config files, vi is a reasonable substitute. /holy_warrior

;)

oops. here we go :e

mingrone said:
Well, since the holy war has started...

In attempt to be editor agnostic there is vile which is vi basic usage inside emacs. I imagine emacs is nice. I have actually though about using it to learn lisp. Though I imagine there are other ways to learn functional programming than installing an editor that uses the language for extensions and endowment.

Any you guys spend any significant time to try using ed() for a week or two without your `preferred editor`? It is the "original standard unix text editor".

I personally did but lost my skills after the effort. Might be worth the effort if you have some time to switch. Then again learning dvorak would also be nice if time truly was of the essence.

I do like the fact that vi() in some form or another is on most machines that I am on. I believe the gentoo live cd only has ed and nano. It's obnoxious because it's only 80mb so what would another couple bytes hurt anyone. also nvi is so small it would be negligible. but as forest gump would say "linux is as linux does."

/rant
 
Ok guys, unless anyone wants to go right back to extol the virtues of clay tablets and cuneiform script I believe this thread was solved a little while ago. ;)
 
Originally Posted by DutchDaemon
Ok guys, unless anyone wants to go right back to extol the virtues of clay tablets and cuneiform script I believe this thread was solved a little while ago.

What do you suggest?
If I like vi.
 
doorways said:
What do you suggest?
If I like vi.
I'm not sure. However on a related note, do you ever get a feeling for what a programmer must be like when you are intimately familiar with their program? Yes? That's why whenever I use vi or its descendants, I feel a profound sense of Joy. And the corollary; whenever I try and use another editor it is invariably a Joyless undertaking.
 
doorways said:
What do you suggest?
It's probably a warning that this thread is getting off-topic. The current vi(m)-emacs debate doesn't have a whole lot to do with your original question any more.

Fonz
 
Back
Top