2013-11-16 14:45:48 -05:00
|
|
|
# VIM-LESS
|
2012-08-16 23:41:25 -04:00
|
|
|
|
|
|
|
This vim bundle adds syntax highlighting, indenting and autocompletion for the dynamic stylesheet language [LESS](http://lesscss.org).
|
|
|
|
|
2013-05-04 16:32:47 -04:00
|
|
|
This bundle is compatible with [vim-css-color](https://github.com/skammer/vim-css-color),
|
|
|
|
[vim-css3-syntax](https://github.com/hail2u/vim-css3-syntax) and possibly other plugins that place code
|
2012-08-16 23:41:25 -04:00
|
|
|
in `after/syntax/css.vim` or `after/syntax/css/*.vim`.
|
|
|
|
|
|
|
|
![vim-less with vim-css-color and vim-css3-syntax (colorscheme solarized)](https://github.com/lenniboy/vim-less/raw/master/screenshot.png)
|
|
|
|
|
2013-11-16 14:45:48 -05:00
|
|
|
|
|
|
|
## Installing and Using
|
2012-08-16 23:41:25 -04:00
|
|
|
|
|
|
|
- Install [pathogen](http://www.vim.org/scripts/script.php?script_id=2332) into `~/.vim/autoload/` and add the
|
|
|
|
following line to your `~/.vimrc`:
|
|
|
|
|
|
|
|
call pathogen#infect()
|
|
|
|
|
|
|
|
- Make a clone of the `vim-less` repository:
|
|
|
|
|
|
|
|
$ mkdir -p ~/.vim/bundle
|
|
|
|
$ cd ~/.vim/bundle
|
|
|
|
$ git clone https://github.com/groenewege/vim-less
|
|
|
|
|
2013-05-04 16:32:47 -04:00
|
|
|
- OR use [vundle](https://github.com/gmarik/vundle), adding this line to your `~/.vimrc`:
|
|
|
|
|
2015-07-13 06:22:46 -04:00
|
|
|
Plugin 'groenewege/vim-less'
|
|
|
|
|
|
|
|
|
|
|
|
- OR use [neobundle](https://github.com/Shougo/neobundle.vim), adding this line to your `~/.vimrc`:
|
|
|
|
|
|
|
|
NeoBundle 'groenewege/vim-less'
|
|
|
|
|
2013-05-04 16:32:47 -04:00
|
|
|
|
2012-08-16 23:41:25 -04:00
|
|
|
- OR use git submodules:
|
|
|
|
|
|
|
|
$ git submodule add https://github.com/groenewege/vim-less.git bundle/vim-less
|
|
|
|
$ git submodule init
|
|
|
|
|
2013-11-16 14:45:48 -05:00
|
|
|
|
2012-08-16 23:41:25 -04:00
|
|
|
### Map
|
|
|
|
.less to .css , lessc is required.
|
|
|
|
|
2013-12-28 13:23:13 -05:00
|
|
|
nnoremap <Leader>m :w <BAR> !lessc % > %:t:r.css<CR><space>
|
2012-08-16 23:41:25 -04:00
|
|
|
|
2013-11-16 14:45:48 -05:00
|
|
|
|
|
|
|
## Credits
|
2012-08-16 23:41:25 -04:00
|
|
|
|
2013-05-04 16:32:47 -04:00
|
|
|
Inspiration from [vim-haml](https://github.com/tpope/vim-haml),
|
2012-08-16 23:41:25 -04:00
|
|
|
[scss-syntax.vim](https://github.com/cakebaker/scss-syntax.vim) and
|
|
|
|
[vim-less](https://github.com/lunaru/vim-less)
|
2013-05-04 16:32:47 -04:00
|
|
|
|
|
|
|
## License ##
|
|
|
|
|
|
|
|
MIT : [groenewege.mit-license.org](http://groenewege.mit-license.org/)
|