Vim syntax layer.

This commit is contained in:
ralesi 2015-09-08 00:35:26 -07:00 committed by syl20bnr
parent 4f810a3d0c
commit 14e7fb954c
2 changed files with 74 additions and 0 deletions

View file

@ -0,0 +1,18 @@
#+TITLE: Vim language contribution layer for Spacemacs
* Table of Contents :TOC@4:
- [[#description][Description]]
- [[#install][Install]]
* Description
This layer adds syntax highlighting support for vim filetypes, in addition to
the pentadactyl firefox extension.
* Install
To use this contribution layer add it to your =~/.spacemacs=
#+BEGIN_SRC emacs-lisp
(set-default dotspacemacs-configuration-layers '(vim))
#+END_SRC

View file

@ -0,0 +1,56 @@
;;; packages.el --- vim Layer packages File for Spacemacs
;;
;; Copyright (c) 2012-2014 Sylvain Benner
;; Copyright (c) 2014-2015 Sylvain Benner & Contributors
;;
;; Author: Sylvain Benner <sylvain.benner@gmail.com>
;; URL: https://github.com/syl20bnr/spacemacs
;;
;; This file is not part of GNU Emacs.
;;
;;; License: GPLv3
;; List of all packages to install and/or initialize. Built-in packages
;; which require an initialization must be listed explicitly in the list.
(setq vim-packages
'(
vimrc-mode
dactyl-mode
;; package vims go here
))
;; List of packages to exclude.
(setq vim-excluded-packages '())
;; For each package, define a function vim/init-<package-vim>
;;
;; (defun vim/init-my-package ()
;; "Initialize my package"
;; )
;;
;; Often the body of an initialize function uses `use-package'
;; For more info on `use-package', see readme:
;; https://github.com/jwiegley/use-package
(defun vim/init-vimrc-mode ()
"Initialize vimrc package"
(use-package vimrc-mode
:mode "\\.vim[rc]?\\'"
:mode "_vimrc\\'"
:defer t
:init
(progn
(add-hook 'vimrc-mode-hook '(lambda ()
(highlight-numbers-mode -1)
(rainbow-delimiters-mode-disable))))))
(defun vim/init-dactyl-mode ()
(use-package dactyl-mode
:mode "pentadactylrc\\'"
:mode "vimperatorrc\\'"
:mode "_pentadactylrc\\'"
:mode "_vimperatorrc\\'"
:mode "\\.penta\\'"
:mode "\\.vimp\\'"
:defer t
))