PHP syntax highlighting through SSH from Mac OS X
-
28-04-2021 - |
Lösung
You don't need these plugins.
Just type :syntax on
in normal mode or add syntax on
to ~/.vimrc
on the server.
Assuming, of course, that you run a reasonably recent version of Vim on a UNIX-y server.
Andere Tipps
There's no need for those plug-ins, simply put the following in your .vimrc
:
syntax on
To debug further, you need to ensure you have the following set
once you open a PHP file:
syntax=php
filetype=php
You can check these like so:
:verbose set syntax? filetype?
You should see something like this:
syntax=php
Last set from /usr/local/share/vim/vim73/syntax/syntax.vim
filetype=php
Last set from /usr/local/share/vim/vim73/filetype.vim
If syntax highlighting isn't working for other file-types, check the values of:
:echo $TERM
:echo $TERMCAP
:echo &t_Co
To ensure you're using a terminal type that allows colour.
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow