-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrebar.config
70 lines (62 loc) · 1.78 KB
/
rebar.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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
% ex:ts=2:sw=2:sts=2:et
% -*- tab-width: 2; c-basic-offset: 2; indent-tabs-mode: nil -*-
{erl_opts, [debug_info]}.
{deps, [
{gproc, "0.9.0"}
]}.
{relx, [
{release, {srcd, git}, [srcd, sasl]},
{sys_config_src, "config/sys.config.src"},
{dev_mode, false},
{include_erts, true}
]}.
{profiles, [
{prod, []},
{test, [
{relx, [
%{release, {srcd, {git, short}}, [srcd, sasl]},
{include_erts, false},
{sys_config_src, "config/test.config.src"}
]}
]}
]}.
{shell, [
{config, "config/sys.config.src"},
{apps, [srcd]}
]}.
{project_plugins, [
rebar3_lint
]}.
{elvis, [
#{dirs => ["src/**"],
filter => "*.erl",
ruleset => erl_files,
rules => [
{elvis_style, behaviour_spelling, #{spelling => behavior}},
{elvis_style, nesting_level, #{level => 3}},
{elvis_style, dont_repeat_yourself, #{min_complexity => 13}},
{elvis_style, no_common_caveats_call},
% Wtf? regexs of _naming_convention breaks at slightest touch.
% fails: "^[a-z][a-z0-9_]*(_SUITE)?$" for "atom [] on line -1"
{elvis_style, atom_naming_convention, #{
regex => "^([a-z][a-z0-9_]*_?)*(_SUITE)?$"
}},
{elvis_style, function_naming_convention, #{
regex => "^([a-z][a-z0-9_]*_?)*(_SUITE)?$"
}},
% TODO: let's maybe consider enabling this at some point?
{elvis_style, param_pattern_matching, disable},
{elvis_text_style, line_length, #{limit => 80, skip_comments => false}},
{elvis_text_style, no_tabs},
{elvis_text_style, no_trailing_whitespace}
]
},
#{dirs => ["."],
filter => "rebar.config",
ruleset => rebar_config,
rules => [
{elvis_project, no_branch_deps},
{elvis_project, protocol_for_deps, #{regex => "https://.*"}}
]
}
]}.