Add salt config layer.
This commit is contained in:
parent
23f99259f7
commit
2389fea56c
24
contrib/config/salt/README.md
Normal file
24
contrib/config/salt/README.md
Normal file
|
@ -0,0 +1,24 @@
|
|||
# Saltstack contribution layer for Spacemacs
|
||||
|
||||
![logo](img/saltstack.png)
|
||||
|
||||
<!-- markdown-toc start - Don't edit this section. Run M-x markdown-toc/generate-toc again -->
|
||||
**Table of Contents**
|
||||
|
||||
- [Saltstack contribution layer for Spacemacs](#saltstack-contribution-layer-for-spacemacs)
|
||||
- [Description](#description)
|
||||
- [Install](#install)
|
||||
|
||||
<!-- markdown-toc end -->
|
||||
|
||||
## Description
|
||||
|
||||
This layer provides syntax highlighting for Saltstack files.
|
||||
|
||||
## Install
|
||||
|
||||
To use this contribution add it to your `~/.spacemacs`
|
||||
|
||||
```elisp
|
||||
(setq-default dotspacemacs-configuration-layers '(salt))
|
||||
```
|
BIN
contrib/config/salt/img/saltstack.png
Normal file
BIN
contrib/config/salt/img/saltstack.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 28 KiB |
23
contrib/config/salt/packages.el
Normal file
23
contrib/config/salt/packages.el
Normal file
|
@ -0,0 +1,23 @@
|
|||
;;; packages.el --- Salt Layer extensions File for Spacemacs
|
||||
;;
|
||||
;; Copyright (c) 2012-2014 Sylvain Benner
|
||||
;; Copyright (c) 2015 phils@stackoverflow & Ben Hayden
|
||||
;;
|
||||
;; Author: Ben Hayden <hayden767@gmail.com>
|
||||
;; Pulled from Stackoverflow: http://stackoverflow.com/a/27737759/76267
|
||||
;; URL: https://github.com/syl20bnr/spacemacs
|
||||
;;
|
||||
;; This file is not part of GNU Emacs.
|
||||
;;
|
||||
;;; License: GPLv3
|
||||
(setq salt-packages '(yaml-mode))
|
||||
|
||||
(defun salt/init-yaml-mode ()
|
||||
(use-package yaml-mode
|
||||
:defer t
|
||||
:init (progn
|
||||
(define-derived-mode saltstack-mode yaml-mode "Saltstack"
|
||||
"Minimal Saltstack mode, based on `yaml-mode'."
|
||||
(setq tab-width 2
|
||||
indent-tabs-mode nil))
|
||||
(add-to-list 'auto-mode-alist '("\\.sls\\'" . saltstack-mode)))))
|
Loading…
Reference in a new issue