forked from AntidoteDB/antidote
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrebar2.config
183 lines (163 loc) · 5.59 KB
/
rebar2.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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
{deps, [
%% overwrite lager dependency since current version disables logger messages (see https://github.com/erlang-lager/lager/issues/492)
{lager, {git, "https://github.com/erlang-lager/lager", {ref, "411edc71ee9823f6ab9c6f617daccce3c6798a29"}}},
%% riak framework
{riak_core, "3.1.1", {pkg,riak_core_ng}},
% ranch socket acceptor pool for managing protocol buffer sockets
{ranch, "1.7.1"},
%% efficient inter-dc messaging
{erlzmq, {git, "https://github.com/zeromq/erlzmq2", {ref, "573d583"}}},
%% antidote utilities
antidote_crdt,
antidote_pb_codec,
antidotec_pb,
vectorclock,
%% antidote stats module; expose metrics for prometheus as HTTP-API
{antidote_stats, {git, "https://github.com/AntidoteDB/antidote_stats", {tag, "v13"}}}
]}.
{erl_opts, [
debug_info,
warnings_as_errors,
nowarn_export_all,
{i, "include"}
]}.
{dialyzer, [{warnings, [
error_handling,
race_conditions,
%underspecs,
unmatched_returns
%unknown
%overspecs,
%specdiffs
]}]}.
{edoc_opts, [
{preprocess, true},
{todo, true},
{includes, ["include/"]},
{dir, "edoc"}
]}.
{overrides, [
{override, riak_ensemble,
[{erl_opts, [
debug_info,
warn_untyped_record,
{platform_define, "^[0-9]+", namespaced_types},
{parse_transform, lager_transform}
]},
{plugins, [pc]},
{provider_hooks, [{post, [{compile, {pc, compile}}, {clean, {pc, clean}}]}]}
]},
{override, riak_core,
[{erl_opts, [{parse_transform, lager_transform}, debug_info, warn_untyped_record,
{plugins, [pc]},
{platform_define, "18", old_rand},
{platform_define, "17", old_rand},
{platform_define, "^R15", old_hash},
{provider_hooks, [{post, [{compile, {pc, compile}}, {clean, {pc, clean}}]}]}
]}]},
%% disable setup post hooks
{override, setup, [{post_hooks, []}]},
{override, eleveldb, [
{plugins, [pc]},
{pre_hooks, [
{compile, "find . -type f | xargs perl -pi -e 's/-mmacosx-version-min=10.8//g;' "},
{compile, "c_src/build_deps.sh get-deps"},
{compile, "c_src/build_deps.sh"}
]},
{post_hooks, [
{clean, "c_src/build_deps.sh clean"}
]},
{provider_hooks, [
{post, [
{compile, {pc, compile}},
{clean, {pc, clean}}
]}
]}
]},
{override, erlzmq,
[{pre_hooks, [{compile, "make -C c_src"},
{clean, "make -C c_src clean"}]},
{plugins, [pc]},
{provider_hooks,
[{post,
[{compile, {pc, compile}},
{clean, {pc, clean}}
]}
]}
]}
]}.
{relx, [{release, {antidote, "2.2.2"}, [antidote]},
{dev_mode, false},
% do not expect Erlang runtime at deployment site
{include_erts, true},
% application environment
{sys_config_src, "config2/sys.config.src"},
% vm arguments passed when starting the Erlang VM
{vm_args_src, "config2/vm.args.src"},
{overlay, [
% copy nested configuration file(s)
{copy, "config2/network.config", "releases/{{release_version}}/network.config"},
% legacy riak_core schema expected at that location at runtime
{copy, "config2/legacy/riak_core.schema", "lib/12-riak_core.schema"},
% redirect lager output to logger
{copy, "config2/lager.config", "releases/{{release_version}}/lager.config"}
]},
% create start script with additional features
{extended_start_script, true}
]}.
{profiles,[
{lint, [
{plugins, [{rebar3_lint, {git, "https://github.com/project-fifo/rebar3_lint.git", {tag, "v0.1.10"}}}]}
]},
{test, [
{erl_opts, [warnings_as_errors, debug_info, no_inline_list_funcs]},
{plugins, [{coveralls, {git, "https://github.com/markusn/coveralls-erl", {branch, "master"}}}]}]}
]}.
% configuration of style rules
{elvis,
[#{dirs => ["src", "test"],
filter => "*.erl",
rules => [
{elvis_style, no_tabs},
{elvis_style, no_trailing_whitespace},
{elvis_style, macro_names, #{ignore => []}},
{elvis_style, operator_spaces, #{rules => [{right, ","},
{right, "--"},
{left, "--"},
{right, "++"},
{left, "++"}]}},
{elvis_style, god_modules,
#{limit => 40,
ignore => []}},
{elvis_style, used_ignored_variable},
{elvis_style, no_behavior_info},
{
elvis_style,
module_naming_convention,
#{regex => "^[a-z]([a-z0-9]*_?)*(_SUITE)?$",
ignore => []}
},
% {
% elvis_style,
% function_naming_convention,
% #{regex => "^([a-z][a-z0-9]*_?)*$"}
% },
{elvis_style, state_record_and_type},
{elvis_style, no_spec_with_records}
]
},
#{dirs => ["."],
filter => "Makefile",
rules => [{elvis_project, no_deps_master_erlang_mk, #{ignore => []}},
{elvis_project, protocol_for_deps_erlang_mk, #{ignore => []}}]
},
#{dirs => ["."],
filter => "rebar.config",
rules => [{elvis_project, no_deps_master_rebar, #{ignore => []}}]
}
]
}.
{cover_enabled, true}.
{cover_export_enabled, true}.
{coveralls_coverdata, "_build/test/cover/*.coverdata"}.
{coveralls_service_name, "travis-ci"}.