Set a strict CSP on all /admin/* responses: default-src 'self', script/style 'unsafe-inline' (needed for the inline editor JS and layout CSS), img-src 'self' data:, frame-ancestors 'none'. Public API routes are unaffected. Bump ClassLength limit to 420 to accommodate the new helper.
43 lines
702 B
YAML
43 lines
702 B
YAML
AllCops:
|
|
TargetRubyVersion: 3.3
|
|
NewCops: enable
|
|
SuggestExtensions: false
|
|
|
|
Style/StringLiterals:
|
|
EnforcedStyle: double_quotes
|
|
|
|
Style/StringLiteralsInInterpolation:
|
|
EnforcedStyle: double_quotes
|
|
|
|
Style/Documentation:
|
|
Exclude:
|
|
- "test/**/*"
|
|
- "exe/**/*"
|
|
|
|
Layout/LineLength:
|
|
Max: 100
|
|
|
|
Metrics/AbcSize:
|
|
Max: 30
|
|
Exclude:
|
|
- "lib/volumen/admin_routes.rb"
|
|
- "lib/volumen/api_routes.rb"
|
|
|
|
Metrics/MethodLength:
|
|
Max: 25
|
|
Exclude:
|
|
- "lib/volumen/admin_routes.rb"
|
|
- "lib/volumen/api_routes.rb"
|
|
|
|
Metrics/ClassLength:
|
|
Max: 420
|
|
|
|
Metrics/ModuleLength:
|
|
Exclude:
|
|
- "lib/volumen/admin_routes.rb"
|
|
|
|
Metrics/BlockLength:
|
|
Exclude:
|
|
- "test/**/*"
|
|
- "volumen.gemspec"
|