forked from AntidoteDB/antidote
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrebar.config
142 lines (131 loc) · 4.8 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
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
{deps, [
{lager, "3.2.1"},
%%{riak_core, {git, "https://github.com/project-fifo/riak_core", {branch, "fifo-0.7.1"}}},
{riak_core, "2.2.8", {pkg, riak_core_ng}},
%% TODO: riak_pb branch "antidote_crdt"
{riak_pb, {git, "https://github.com/syncfree/riak_pb", {tag, "v0.4.1"}}},
{riak_api, {git, "https://github.com/basho/riak_api", {tag, "2.0.2"}}},
{erlzmq, {git, "https://github.com/tcrain/erlzmq2", {ref, "f40b84ed2947a2bb0dfdbf2f0e0d006beec54b0b"}}},
%% antidote_pb is client interface. Needed only for riak_tests.
{antidote_pb, {git, "https://github.com/syncfree/antidote_pb", {tag, "v0.1.0"}}},
{antidote_crdt, ".*", {git, "https://github.com/syncfree/antidote_crdt", {tag, "0.0.6"}}},
{rand_compat, {git, "https://github.com/lasp-lang/rand_compat.git", {ref, "b2cf40b6ef14a5d7fbc67276e9164de7cc7c7906"}}}
]}.
{erl_opts, [debug_info, warnings_as_errors, {parse_transform, lager_transform},{i,"include"}]}.
{cover_enabled, true}.
{eunit_opts, [verbose, {report, {eunit_surefire, [{dir,"logs/"}]}}]}.
{dialyzer, [{warnings, [
%unmatched_returns,
%unknown
%overspecs,
no_undefined_callbacks
]}]}.
{overrides,
[
%% R18
{override, chash,
[{erl_opts, [debug_info, {platform_define, "^[0-9]+", namespaced_types}]}]},
{override, webmachine,
[{erl_opts, []}]},
{override, edown,
[{erl_opts, [debug_info]}]},
{override, riak_core,
[{erl_opts, [{parse_transform, lager_transform},
debug_info, {platform_define, "^[0-9]+", namespaced_types},
{platform_define, "^R15", "old_hash"}]}]},
{override, riak_ensemble,
[{erl_opts, [debug_info,
warn_untyped_record,
{parse_transform, lager_transform}]},
{plugins, [pc]},
{provider_hooks,
[{post,
[{compile, {pc, compile}},
{clean, {pc, clean}}]}]}]},
%% Normal
{override, setup, [{post_hooks, []}]},
{override, eleveldb,
[{pre_hooks, [{compile, "c_src/build_deps.sh get-deps"},
{compile, "c_src/build_deps.sh"}]},
{post_hooks, [{clean, "c_src/build_deps.sh clean"}]},
{plugins, [pc]},
{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, "0.0.1"}, [antidote]},
{dev_mode, false},
{include_erts, true},
{sys_config, "config/sys.config"},
{vm_args, "config/vm.args"},
{overlay, [
{mkdir, "data/ring"},
{mkdir, "log/sasl"},
{copy, "bin/env", "bin/env"},
{template, "rel/files/antidote-admin", "bin/antidote-admin"},
{template, "_build/default/lib/cuttlefish/priv/erlang_vm.schema", "lib/11-erlang_vm.schema"},
{template, "_build/default/lib/riak_core/priv/riak_core.schema", "lib/12-riak_core.schema"},
{template, "_build/default/lib/riak_sysmon/priv/riak_sysmon.schema", "lib/15-riak_sysmon.schema"},
{template, "_build/default/lib/eleveldb/priv/eleveldb.schema", "lib/21-leveldb.schema"}
]},
{overlay_vars, "config/vars.config"},
{extended_start_script, true}]}.
% lint tool for style checking
{profiles,[
{lint, [
{plugins, [{rebar3_lint, {git, "https://github.com/project-fifo/rebar3_lint.git", {tag, "0.1.2"}}}]}
]}
]}.
% 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 => 25,
ignore => []}},
{elvis_style, used_ignored_variable},
{elvis_style, no_behavior_info},
{
elvis_style,
module_naming_convention,
#{regex => "^[a-z]([a-z0-9]*_?)*(_SUITE)?$",
ignore => []}
},
% Can be added back if antidote_crdt_bcounter:localPermissions is renamed
%{
% 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 => []}}]
}
]
}.