Adrien Vergé
89b75b7c05
refactor: Remove UTF-8 headers in Python files
...
The `# -*- coding: utf-8 -*-` headers were useful for Python 2, and
aren't needed for Python 3 where UTF-8 is the default.
yamllint support of Python 2 was dropped in early 2021, see commit
a3fc64d "End support for Python 2".
Let's drop these headers.
2022-06-09 09:40:06 +02:00
Jérôme Alet
c268a82c5a
key-duplicates: Don't crash on redundant closing brackets or braces
...
Don't break on empty `context` stack when invalid YAML:
[ a, b, c ] ]
{a: 1, b: 2} }
2022-04-20 11:00:08 +02:00
Nick Burke
1b379628d7
key-duplicates: Handle merge keys (<<)
...
Merge keys are described here: http://yaml.org/type/merge.html
They shouldn't be considered as duplicated keys.
Fixes https://github.com/adrienverge/yamllint/issues/88
2018-02-28 23:12:43 +01:00
Adrien Vergé
8fca8a7a33
Config: Allow 'enable' keyword for rules
...
In the same manner as 'disable', 'enable' allows setting a rule on
without worrying about its options.
2016-03-06 08:00:25 +01:00
Adrien Vergé
f6bab05e8a
Rules: Add the 'key-duplicates' rule
2016-02-01 22:26:18 +01:00