-
Notifications
You must be signed in to change notification settings - Fork 2
/
elvis.config
47 lines (46 loc) · 1.87 KB
/
elvis.config
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
47
[
{
elvis,
[
{config,
[#{dirs => ["src"],
filter => "*.erl",
ruleset => erl_files,
rules => [{elvis_text_style, line_length, #{limit => 120, skip_comments => whole_line}},
%% Ranch 利用のため Transport:send/2 的なのが必要なので ...
{elvis_style, invalid_dynamic_call, disable},
%% snake_case じゃない場合は本来 '' で囲うべき
{elvis_style, atom_naming_convention, #{regex => "^([a-z][a-zA-Z0-9_]*_?)*(_SUITE)?$", enclosed_atoms => ".*"}},
{elvis_style, module_naming_convention, #{regex => "^([a-z][a-z0-9]*)(_[a-z0-9]+)*(_SUITE)?$"}},
{elvis_style, variable_naming_convention, #{regex => "^(_?[A-Z][0-9a-zA-Z_]*)$"}},
{elvis_style, nesting_level, disable},
{elvis_style, god_modules, disable},
{elvis_style, state_record_and_type, disable},
{elvis_style, no_block_expressions, disable},
{elvis_style, export_used_types, disable},
{elvis_style, private_data_types, disable},
%% 要検討
{elvis_style, no_single_clause_case, disable},
%% 要検討
{elvis_style, max_function_arity, disable},
%% 要検討
{elvis_style, operator_spaces, disable},
%% 要検討
{elvis_style, no_spec_with_records, disable},
%% 要検討
{elvis_style, dont_repeat_yourself, disable}]
},
#{dirs => ["."],
filter => "rebar.config",
ruleset => rebar_config,
rules => [{elvis_project, protocol_for_deps}]
},
#{dirs => ["."],
filter => "elvis.config",
ruleset => elvis_config
}
]
}
]
}
].