summaryrefslogtreecommitdiff
path: root/doc/ale-cloudformation.txt
blob: 9724403b87173eafd8a2a4bab0ed686d4f9ef1df (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
===============================================================================
ALE CloudFormation Integration                      *ale-cloudformation-options*


===============================================================================
cfn-python-lint                             *ale-cloudformation-cfn-python-lint*

cfn-python-lint is a linter for AWS CloudFormation template file.

Website: https://github.com/awslabs/cfn-python-lint

Installation
-------------------------------------------------------------------------------


Install cfn-python-lint using either pip or brew: >

`pip install cfn-lint`. If pip is not available, run
`python setup.py clean --all` then `python setup.py install`.

 Homebrew (macOS):

`brew install cfn-lint`

<
Configuration
-------------------------------------------------------------------------------

To get cloudformation linter to work on only CloudFormation files  we must set
the buffer |filetype| to yaml.cloudformation.
This causes ALE to lint the file with linters configured for cloudformation and
yaml files.

Just put:

>

 au BufRead,BufNewFile *.template.yaml set filetype=yaml.cloudformation

<

on `ftdetect/cloudformation.vim`

This will get both cloudformation and yaml linters to work on any file with `.template.yaml` ext.
===============================================================================
  vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl: