N1QL is a SQL-like declarative language for manipulating JSON documents in Couchbase Server databases.
Vim syntax highlights N1QL statements, keywords, operators, types, comments, and special values. Vim ignores syntactical elements specific to SQL or its many dialects, like COLUMN or CHAR, that don't exist in N1QL.
- N1QL syntax file(s) for Vim 7.4 and later
$HOME/.vimmust exist for local installation
Recommended:
Have Git available for automatic installation / updates to the $HOME/.vim
using the n1ql4vim command, included with this distribution.
This syntax file is pending approval from the Vim team for inclusion in Vim 8.x and subsequent versions.
- Exit Vim, MacVim, gVim - all Vim instances associated with your user
- Execute from the console:
curl -s https://raw.githubusercontent.com/pr3d4t0r/n1ql-vim-syntax/master/n1ql4vim | sh - Open
vim sample.n1qlto validate
- Exit Vim, MacVim, gVim - all Vim instances associated with your user
- Download the
n1ql4vimbash script - Run
sh ./n1ql4vimscript - Open
vim sample.n1qlto validate
- Exit Vim, MacVim, gVim - all Vim instances associated with your user
- Clone the N1QL syntax repository:
git clone https://github.com/pr3d4t0r/n1ql-vim-syntax.git n1ql-vim - Copy the syntax file to the local environment:
cp n1ql-vim/syntax/n1ql.vim ~/.vim/syntax - Then the file detection file:
cp n1ql-vim/ftdetect/n1ql.vim ~/.vim/ftdetect - And the documentation:
cp n1ql-vim/doc/n1ql.vim ~/.vim/doc - Open
vim sample.n1qlto validate
Support: Eugene Ciurana, <n1ql AT cime.net>, https://ciurana.eu/pgp or https://keybase.io/pr3d4t0r
Updates will be available through this repository and submitted for review to the Vim team in accordance to https://github.com/vim/vim/blob/master/contributing.md
Vim is Charityware. n1ql.vim syntax is Charityware.
© Copyright 2017 by Eugene Ciurana / pr3d4t0r. Licensed under the
standard VIM LICENSE - Vim command :help uganda.txt for details.