Gregory Anders | 150b507 | 2024-09-04 22:19:45 +0200 | [diff] [blame] | 1 | " Vim indent file |
| 2 | " Language: HCL |
| 3 | " Maintainer: Gregory Anders |
| 4 | " Upstream: https://github.com/hashivim/vim-terraform |
Gregory Anders | c8b7e61 | 2025-05-25 17:01:45 +0200 | [diff] [blame] | 5 | " License: ISC |
Gregory Anders | 150b507 | 2024-09-04 22:19:45 +0200 | [diff] [blame] | 6 | " Last Change: 2024-09-03 |
Gregory Anders | c8b7e61 | 2025-05-25 17:01:45 +0200 | [diff] [blame] | 7 | " |
| 8 | " Copyright (c) 2014-2016 Mark Cornick <mark@markcornick.com> |
| 9 | " |
| 10 | " Permission to use, copy, modify, and/or distribute this software for any purpose |
| 11 | " with or without fee is hereby granted, provided that the above copyright notice |
| 12 | " and this permission notice appear in all copies. |
| 13 | " |
| 14 | " THE SOFTWARE IS PROVIDED 'AS IS' AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH |
| 15 | " REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND |
| 16 | " FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, |
| 17 | " INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS |
| 18 | " OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER |
| 19 | " TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF |
| 20 | " THIS SOFTWARE. |
Gregory Anders | 150b507 | 2024-09-04 22:19:45 +0200 | [diff] [blame] | 21 | |
| 22 | if exists('b:did_indent') |
| 23 | finish |
| 24 | endif |
| 25 | let b:did_indent = 1 |
| 26 | |
| 27 | setlocal autoindent shiftwidth=2 tabstop=2 softtabstop=2 expandtab |
| 28 | setlocal indentexpr=hcl#indentexpr(v:lnum) |
| 29 | setlocal indentkeys+=<:>,0=},0=) |
| 30 | |
| 31 | let b:undo_indent = 'setlocal ai< sw< ts< sts< et< inde< indk<' |