forked from lijiext/lammps
Merge pull request #1501 from uihsnv/vim_files
Simplify and update vim syntax highlighting files
This commit is contained in:
commit
bb0240d8eb
|
@ -7,10 +7,10 @@ end on *.lmp or start with in.* (see mysyntax.vim).
|
|||
By far not all commands are included
|
||||
in the syntax file (lammps.vim). You can easily add new ones.
|
||||
|
||||
=To enable the highlighting:
|
||||
=To enable the highlighting (compatible with old versions of VIM):
|
||||
============================
|
||||
(0) Create a ~/.vimrc
|
||||
You can have a look in /usr/local/share/vim/current/vimrc.example
|
||||
You can have a look in /usr/share/vim/vim*/vimrc_example.vim
|
||||
(1) Insert in ~/.vimrc
|
||||
let mysyntaxfile = "~/.vim/mysyntax.vim"
|
||||
just before
|
||||
|
@ -22,24 +22,22 @@ in the syntax file (lammps.vim). You can easily add new ones.
|
|||
|
||||
(0) Create/edit ~/.vimrc to contain:
|
||||
syntax on
|
||||
(1) Create directories ~/.vim and ~/.vim/syntax
|
||||
(1) Create directories ~/.vim/syntax and ~/.vim/ftdetect
|
||||
(2) Copy lammps.vim to ~/.vim/syntax/lammps.vim
|
||||
(3) Create/edit ~/.vim/filetype.vim to contain
|
||||
|
||||
" vim syntax highlight customizations
|
||||
if exists("did_load_filetypes")
|
||||
finish
|
||||
endif
|
||||
|
||||
augroup filetypedetect
|
||||
au! BufRead,BufNewFile in.* setfiletype lammps
|
||||
au! BufRead,BufNewFile *.lmp setfiletype lammps
|
||||
augroup END
|
||||
(4) the end
|
||||
(3) Copy filetype.vim to ~/.vim/ftdetect/lammps.vim
|
||||
|
||||
|
||||
Gerolf Ziegenhain <gerolf@ziegenhain.com> 2007
|
||||
|
||||
Distribution Packaging guidelines:
|
||||
==================================
|
||||
|
||||
(0) Copy lammps.vim to ${VIMFILES}/syntax/lammps.vim
|
||||
(1) Copy filetype.vim as ${VIMFILES}/ftdetect/lammps.vim
|
||||
|
||||
${VIMFILES} is typically /usr/share/vim/vimfiles
|
||||
Consult your packaging guidlines for exact location.
|
||||
|
||||
---------------
|
||||
|
||||
updated by Sam Bateman, 11/2010
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
augroup filetypedetect
|
||||
au! BufRead,BufNewFile in.* setfiletype lammps
|
||||
au! BufRead,BufNewFile *.lmp setfiletype lammps
|
||||
augroup END
|
|
@ -2,25 +2,26 @@
|
|||
" Language: Lammps Simulation Script File
|
||||
" Maintainer: Gerolf Ziegenhain <gerolf@ziegenhain.com>
|
||||
" Updates: Axel Kohlmeyer <akohlmey@gmail.com>, Sam Bateman <sam.bateman@nrlssc.navy.mil>, Daniel Möller Montull <d.moller.m@gmail.com>
|
||||
" Latest Revision: 2012-06-19
|
||||
" Latest Revision: 2019-06-11
|
||||
|
||||
syn clear
|
||||
|
||||
syn keyword lammpsOutput log write_restart restart dump undump thermo thermo_modify thermo_style print
|
||||
syn keyword lammpsRead include read read_restart read_data
|
||||
syn keyword lammpsOutput log write_data write_dump info shell write_restart restart dump undump thermo thermo_modify thermo_style print timer
|
||||
syn keyword lammpsRead include read_restart read_data read_dump molecule
|
||||
syn keyword lammpsLattice boundary units atom_style lattice region create_box create_atoms dielectric
|
||||
syn keyword lammpsLattice delete_atoms change_box dimension replicate
|
||||
syn keyword lammpsParticle pair_coeff pair_style pair_modify mass velocity angle_coeff angle_style
|
||||
syn keyword lammpsParticle atom_modify atom_style bond_coeff bond_style delete_bonds kspace_style
|
||||
syn keyword lammpsLattice delete_atoms displace_atoms change_box dimension replicate
|
||||
syn keyword lammpsParticle pair_coeff pair_style pair_modify pair_write mass velocity angle_coeff angle_style
|
||||
syn keyword lammpsParticle atom_modify atom_style bond_coeff bond_style bond_write create_bonds delete_bonds kspace_style
|
||||
syn keyword lammpsParticle kspace_modify dihedral_style dihedral_coeff improper_style improper_coeff
|
||||
syn keyword lammpsSetup min_style fix_modify run_style timestep neighbor neigh_modify fix unfix
|
||||
syn keyword lammpsSetup communicate newton nthreads processors reset_timestep
|
||||
syn keyword lammpsRun minimize run
|
||||
syn keyword lammpsDefine variable group compute
|
||||
syn keyword lammpsSetup min_style fix_modify run_style timestep neighbor neigh_modify fix unfix suffix special_bonds
|
||||
syn keyword lammpsSetup balance box clear comm_modify comm_style newton package processors reset_ids reset_timestep
|
||||
syn keyword lammpsRun minimize run rerun tad neb prd quit server temper temper/grem temper/npt
|
||||
syn keyword lammpsRun min/spin message hyper dynamical_matrix
|
||||
syn keyword lammpsDefine variable group compute python set uncompute kim_query
|
||||
|
||||
syn keyword lammpsRepeat jump next loop
|
||||
|
||||
syn keyword lammpsOperator equal add sub mult div
|
||||
syn keyword lammpsOperator equal add sub mult div
|
||||
|
||||
syn keyword lammpsConditional if then elif else
|
||||
|
||||
|
|
Loading…
Reference in New Issue