-
Notifications
You must be signed in to change notification settings - Fork 85
Adapt to elvis_core 5.x
#602
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
723c08e
Adapt to elvis_core 5.x
paulo-ferraz-oliveira 1918cad
Turn it around (warnings_as_errors, on by default)
paulo-ferraz-oliveira ec9b930
Fix spec
paulo-ferraz-oliveira 1ddd0e8
Fix for compiler warnings
paulo-ferraz-oliveira 3e920d7
Bump to elvis_core 5.0.0
paulo-ferraz-oliveira 3d7650c
Act on newer constraints
paulo-ferraz-oliveira 98f79ff
Remove useless mechanism (moved to elvis_core)
paulo-ferraz-oliveira 54d6e0a
Simplify it
paulo-ferraz-oliveira f0b6839
Adapt to newer elvis_core, which also simplifies it for us
paulo-ferraz-oliveira 9841ba3
Be consistent with elvis_core
paulo-ferraz-oliveira 50bf382
Be consistent internally
paulo-ferraz-oliveira bbb82da
Fix per visual inspection
paulo-ferraz-oliveira cb4bf88
Ease review
paulo-ferraz-oliveira 4d8d51f
Accept review suggestion
paulo-ferraz-oliveira 8ceff13
Accept review suggestion
paulo-ferraz-oliveira 17a8772
Prepare for 5.0.0+
paulo-ferraz-oliveira a897822
Forgot to run erlfmt? yes!
paulo-ferraz-oliveira 62b05ec
Fix per testing
paulo-ferraz-oliveira d1675a1
Fix per dialyzer
paulo-ferraz-oliveira 5e9eb02
Use release 5.0.1 of elvis_core
elbrujohalcon File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,14 +1,8 @@ | ||
| [ | ||
| { | ||
| elvis, | ||
| [ | ||
| {config, [ | ||
| #{ | ||
| dirs => ["../../test/examples"], | ||
| filter => "user_defined_rules.erl", | ||
| rules => [{user_defined_rules, rule}] | ||
| } | ||
| ]} | ||
| ] | ||
| } | ||
| {config, [ | ||
| #{ | ||
| files => ["../../test/examples/user_defined_rules.erl"], | ||
| rules => [{user_defined_rules, rule}] | ||
| } | ||
| ]} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,19 +1,12 @@ | ||
| [ | ||
| { | ||
| elvis, | ||
| [ | ||
| {config, [ | ||
| #{ | ||
| dirs => ["../../src"], | ||
| filter => "*.erl", | ||
| ruleset => erl_files | ||
| }, | ||
| #{ | ||
| dirs => ["../.."], | ||
| filter => "rebar.config", | ||
| ruleset => rebar_config | ||
| } | ||
| ]} | ||
| ] | ||
| } | ||
| {config, [ | ||
| #{ | ||
| files => ["../../src/*.erl"], | ||
| ruleset => erl_files | ||
| }, | ||
| #{ | ||
| files => ["../../rebar.config"], | ||
| ruleset => rebar_config | ||
| } | ||
| ]} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,14 +1,8 @@ | ||
| [ | ||
| { | ||
| elvis, | ||
| [ | ||
| {config, [ | ||
| #{ | ||
| dirs => ["src"], | ||
| filter => "*.erl", | ||
| ruleset => erl_files | ||
| } | ||
| ]} | ||
| ] | ||
| } | ||
| {config, [ | ||
| #{ | ||
| files => ["src/*.erl"], | ||
| ruleset => erl_files | ||
| } | ||
| ]} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| [ | ||
| {config, [ | ||
| #{ | ||
| files => ["../../test/examples/**.erl"], | ||
| ruleset => erl_files | ||
| } | ||
| ]}, | ||
| {output_format, plain} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,49 +1,44 @@ | ||
| [ | ||
| { | ||
| elvis, | ||
| [ | ||
| {config, [ | ||
| #{ | ||
| dirs => ["../../test/examples"], | ||
| filter => "*.erl", | ||
| rules => [ | ||
| {elvis_style, line_length, [80]}, | ||
| {elvis_style, no_tabs, []}, | ||
| {elvis_style, macro_names, []}, | ||
| {elvis_style, operator_spaces, [ | ||
| {right, ","}, | ||
| {right, "++"}, | ||
| {left, "++"} | ||
| ]}, | ||
| {elvis_style, nesting_level, [3]}, | ||
| {elvis_style, god_modules, [25]}, | ||
| {elvis_style, no_if_expression, []}, | ||
| {elvis_style, invalid_dynamic_call, [elvis]}, | ||
| {elvis_style, used_ignored_variable, []}, | ||
| {elvis_style, no_behavior_info, []}, | ||
| { | ||
| elvis_style, | ||
| module_naming_convention, | ||
| ["^([a-z][a-z0-9]*_?)*(_SUITE)?$", []] | ||
| }, | ||
| {elvis_style, state_record_and_type, []}, | ||
| {elvis_style, no_spec_with_records, []} | ||
| ] | ||
| {config, [ | ||
| #{ | ||
| dirs => ["../../test/examples"], | ||
| filter => "*.erl", | ||
| rules => [ | ||
| {elvis_style, line_length, [80]}, | ||
| {elvis_style, no_tabs, []}, | ||
| {elvis_style, macro_names, []}, | ||
| {elvis_style, operator_spaces, [ | ||
| {right, ","}, | ||
| {right, "++"}, | ||
| {left, "++"} | ||
| ]}, | ||
| {elvis_style, nesting_level, [3]}, | ||
| {elvis_style, god_modules, [25]}, | ||
| {elvis_style, no_if_expression, []}, | ||
| {elvis_style, invalid_dynamic_call, [elvis]}, | ||
| {elvis_style, used_ignored_variable, []}, | ||
| {elvis_style, no_behavior_info, []}, | ||
| { | ||
| elvis_style, | ||
| module_naming_convention, | ||
| ["^([a-z][a-z0-9]*_?)*(_SUITE)?$", []] | ||
| }, | ||
| #{ | ||
| dirs => ["."], | ||
| filter => "rebar.config", | ||
| rules => [ | ||
| {elvis_project, no_deps_master_rebar, []}, | ||
| {elvis_project, protocol_for_deps_rebar, []} | ||
| ] | ||
| }, | ||
| #{ | ||
| dirs => ["."], | ||
| filter => "elvis.config", | ||
| rules => [{elvis_project, old_configuration_format, []}] | ||
| } | ||
| ]} | ||
| ] | ||
| } | ||
| {elvis_style, state_record_and_type, []}, | ||
| {elvis_style, no_spec_with_records, []} | ||
| ] | ||
| }, | ||
| #{ | ||
| dirs => ["."], | ||
| filter => "rebar.config", | ||
| rules => [ | ||
| {elvis_project, no_deps_master_rebar, []}, | ||
| {elvis_project, protocol_for_deps_rebar, []} | ||
| ] | ||
| }, | ||
| #{ | ||
| dirs => ["."], | ||
| filter => "elvis.config", | ||
| rules => [{elvis_project, old_configuration_format, []}] | ||
| } | ||
| ]} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,33 +1,28 @@ | ||
| [ | ||
| { | ||
| elvis, | ||
| [ | ||
| {config, #{ | ||
| src_dirs => ["../../src"], | ||
| rules => [ | ||
| {elvis_style, line_length, [80]}, | ||
| {elvis_style, no_tabs, []}, | ||
| {elvis_style, macro_names, []}, | ||
| {elvis_style, operator_spaces, [ | ||
| {right, ","}, | ||
| {right, "++"}, | ||
| {left, "++"} | ||
| ]}, | ||
| {elvis_style, nesting_level, [3]}, | ||
| {elvis_style, god_modules, [25]}, | ||
| {elvis_style, no_if_expression, []}, | ||
| {elvis_style, invalid_dynamic_call, [elvis]}, | ||
| {elvis_style, used_ignored_variable, []}, | ||
| {elvis_style, no_behavior_info, []}, | ||
| { | ||
| elvis_style, | ||
| module_naming_convention, | ||
| ["^([a-z][a-z0-9]*_?)*(_SUITE)?$", []] | ||
| }, | ||
| {elvis_style, state_record_and_type, []}, | ||
| {elvis_style, no_spec_with_records, []} | ||
| ] | ||
| }} | ||
| {config, #{ | ||
| src_dirs => ["../../src"], | ||
| rules => [ | ||
| {elvis_style, line_length, [80]}, | ||
| {elvis_style, no_tabs, []}, | ||
| {elvis_style, macro_names, []}, | ||
| {elvis_style, operator_spaces, [ | ||
| {right, ","}, | ||
| {right, "++"}, | ||
| {left, "++"} | ||
| ]}, | ||
| {elvis_style, nesting_level, [3]}, | ||
| {elvis_style, god_modules, [25]}, | ||
| {elvis_style, no_if_expression, []}, | ||
| {elvis_style, invalid_dynamic_call, [elvis]}, | ||
| {elvis_style, used_ignored_variable, []}, | ||
| {elvis_style, no_behavior_info, []}, | ||
| { | ||
| elvis_style, | ||
| module_naming_convention, | ||
| ["^([a-z][a-z0-9]*_?)*(_SUITE)?$", []] | ||
| }, | ||
| {elvis_style, state_record_and_type, []}, | ||
| {elvis_style, no_spec_with_records, []} | ||
| ] | ||
| } | ||
| }} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,33 +1,28 @@ | ||
| [ | ||
| { | ||
| elvis, | ||
| [ | ||
| {config, #{ | ||
| src_dirs => ["src"], | ||
| rules => [ | ||
| {elvis_style, line_length, [80]}, | ||
| {elvis_style, no_tabs, []}, | ||
| {elvis_style, macro_names, []}, | ||
| {elvis_style, operator_spaces, [ | ||
| {right, ","}, | ||
| {right, "++"}, | ||
| {left, "++"} | ||
| ]}, | ||
| {elvis_style, nesting_level, [3]}, | ||
| {elvis_style, god_modules, [25]}, | ||
| {elvis_style, no_if_expression, []}, | ||
| {elvis_style, invalid_dynamic_call, [elvis]}, | ||
| {elvis_style, used_ignored_variable, []}, | ||
| {elvis_style, no_behavior_info, []}, | ||
| { | ||
| elvis_style, | ||
| module_naming_convention, | ||
| ["^([a-z][a-z0-9]*_?)*(_SUITE)?$", []] | ||
| }, | ||
| {elvis_style, state_record_and_type, []}, | ||
| {elvis_style, no_spec_with_records, []} | ||
| ] | ||
| }} | ||
| {config, #{ | ||
| src_dirs => ["src"], | ||
| rules => [ | ||
| {elvis_style, line_length, [80]}, | ||
| {elvis_style, no_tabs, []}, | ||
| {elvis_style, macro_names, []}, | ||
| {elvis_style, operator_spaces, [ | ||
| {right, ","}, | ||
| {right, "++"}, | ||
| {left, "++"} | ||
| ]}, | ||
| {elvis_style, nesting_level, [3]}, | ||
| {elvis_style, god_modules, [25]}, | ||
| {elvis_style, no_if_expression, []}, | ||
| {elvis_style, invalid_dynamic_call, [elvis]}, | ||
| {elvis_style, used_ignored_variable, []}, | ||
| {elvis_style, no_behavior_info, []}, | ||
| { | ||
| elvis_style, | ||
| module_naming_convention, | ||
| ["^([a-z][a-z0-9]*_?)*(_SUITE)?$", []] | ||
| }, | ||
| {elvis_style, state_record_and_type, []}, | ||
| {elvis_style, no_spec_with_records, []} | ||
| ] | ||
| } | ||
| }} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,15 +1,11 @@ | ||
| [ | ||
| { | ||
| elvis, | ||
| [ | ||
| {config, [ | ||
| #{ | ||
| dirs => ["../../test/examples"], | ||
| filter => "**.erl", | ||
| ruleset => erl_files | ||
| } | ||
| ]}, | ||
| {output_format, plain} | ||
| ] | ||
| } | ||
| {elvis, [ | ||
| {config, [ | ||
| #{ | ||
| files => ["../../test/examples/**.erl"], | ||
| ruleset => erl_files | ||
| } | ||
| ]}, | ||
| {output_format, plain} | ||
| ]} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,27 +1,22 @@ | ||
| [ | ||
| {elvis, [ | ||
| {config, [ | ||
| #{ | ||
| dirs => ["src"], | ||
| filter => "*.erl", | ||
| ruleset => erl_files_strict, | ||
| rules => [{elvis_style, max_function_length, #{max_length => 50}}] | ||
| }, | ||
| #{ | ||
| dirs => ["test"], | ||
| filter => "*.erl", | ||
| ruleset => erl_files_test | ||
| }, | ||
| #{ | ||
| dirs => ["."], | ||
| filter => "rebar.config", | ||
| ruleset => rebar_config | ||
| }, | ||
| #{ | ||
| dirs => ["."], | ||
| filter => ".gitignore", | ||
| ruleset => gitignore | ||
| } | ||
| ]} | ||
| {config, [ | ||
| #{ | ||
| files => ["src/**/*.erl"], | ||
| ruleset => erl_files_strict, | ||
| rules => [{elvis_style, max_function_length, #{max_length => 50}}] | ||
| }, | ||
| #{ | ||
| files => ["test/**/*.erl"], | ||
| ruleset => erl_files_test, | ||
| rules => [{elvis_style, no_debug_call, disable}] | ||
| }, | ||
| #{ | ||
| files => ["rebar.config"], | ||
| ruleset => rebar_config | ||
| }, | ||
| #{ | ||
| files => [".gitignore"], | ||
| ruleset => gitignore | ||
| } | ||
| ]} | ||
| ]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.