Showing 840 of 840 total issues
Freeze mutable objects assigned to constants. Open
VERSION = '1.6.0'
- Read upRead up
- Exclude checks
This cop checks whether some constant value isn't a mutable literal (e.g. array or hash).
Example:
# bad
CONST = [1, 2, 3]
# good
CONST = [1, 2, 3].freeze
Trailing whitespace detected. Open
- Exclude checks
Align the parameters of a method call if they span more than one line. Open
project,
- Read upRead up
- Exclude checks
Here we check if the parameters on a multi-line method call or definition are aligned.
Example: EnforcedStyle: withfirstparameter (default)
# good
foo :bar,
:baz
# bad
foo :bar,
:baz
Example: EnforcedStyle: withfixedindentation
# good
foo :bar,
:baz
# bad
foo :bar,
:baz
Align the parameters of a method call if they span more than one line. Open
template,
- Read upRead up
- Exclude checks
Here we check if the parameters on a multi-line method call or definition are aligned.
Example: EnforcedStyle: withfirstparameter (default)
# good
foo :bar,
:baz
# bad
foo :bar,
:baz
Example: EnforcedStyle: withfixedindentation
# good
foo :bar,
:baz
# bad
foo :bar,
:baz
Align the parameters of a method call if they span more than one line. Open
project,
- Read upRead up
- Exclude checks
Here we check if the parameters on a multi-line method call or definition are aligned.
Example: EnforcedStyle: withfirstparameter (default)
# good
foo :bar,
:baz
# bad
foo :bar,
:baz
Example: EnforcedStyle: withfixedindentation
# good
foo :bar,
:baz
# bad
foo :bar,
:baz
Use 2 (not 1) spaces for indentation. Open
class ModuleGenerator
- Read upRead up
- Exclude checks
This cops checks for indentation that doesn't use the specified number of spaces.
See also the IndentationConsistency cop which is the companion to this one.
Example:
# bad
class A
def test
puts 'hello'
end
end
# good
class A
def test
puts 'hello'
end
end
Example: IgnoredPatterns: ['^\s*module']
# bad
module A
class B
def test
puts 'hello'
end
end
end
# good
module A
class B
def test
puts 'hello'
end
end
end
Align the parameters of a method call if they span more than one line. Open
code_module,
- Read upRead up
- Exclude checks
Here we check if the parameters on a multi-line method call or definition are aligned.
Example: EnforcedStyle: withfirstparameter (default)
# good
foo :bar,
:baz
# bad
foo :bar,
:baz
Example: EnforcedStyle: withfixedindentation
# good
foo :bar,
:baz
# bad
foo :bar,
:baz
Tab detected. Open
code_module,
- Exclude checks
Tab detected. Open
# Creating code files
- Exclude checks
Freeze mutable objects assigned to constants. Open
RELEASE_LINK = "https://github.com/rambler-digital-solutions/Generamba/releases/tag/#{VERSION}"
- Read upRead up
- Exclude checks
This cop checks whether some constant value isn't a mutable literal (e.g. array or hash).
Example:
# bad
CONST = [1, 2, 3]
# good
CONST = [1, 2, 3].freeze
Tab detected. Open
group_path,
- Exclude checks
Tab detected. Open
code_module.project_file_root)
- Exclude checks
Use 2 (not 1) spaces for indentation. Open
def generate_module(name, code_module, template)
- Read upRead up
- Exclude checks
This cops checks for indentation that doesn't use the specified number of spaces.
See also the IndentationConsistency cop which is the companion to this one.
Example:
# bad
class A
def test
puts 'hello'
end
end
# good
class A
def test
puts 'hello'
end
end
Example: IgnoredPatterns: ['^\s*module']
# bad
module A
class B
def test
puts 'hello'
end
end
end
# good
module A
class B
def test
puts 'hello'
end
end
end
Line is too long. [103/80] Open
puts "Project group path: #{code_module.project_group_path}".green if code_module.project_group_path
- Exclude checks
Tab detected. Open
template,
- Exclude checks
Tab detected. Open
end
- Exclude checks
Line is too long. [95/80] Open
FileUtils.mkdir_p File.dirname(file_path) if !code_module.create_logical_groups
- Exclude checks
Tab detected. Open
project,
- Exclude checks
Final newline missing. Open
end
- Exclude checks
Tab detected. Open
# Creating test files
- Exclude checks