Skip to content

Commit 42ba504

Browse files
corrieleecharmahilloalexstonejnebekerjcavena
committed
Excluding new Rails/Env cop
Added team's reasoning in file comment. Co-authored-by: Aaron Hill <armahillo@gmail.com> Co-authored-by: Alex Stone <astone@radiusnetworks.com> Co-authored-by: James Nebeker <jnebeker@radiusnetworks.com> Co-authored-by: JC Avena <jcavena@gmail.com> Co-authored-by: Ben Gross <bgross@radiusnetworks.com>
1 parent f0f2bb7 commit 42ba504

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

common_rubocop_rails.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,11 @@ Rails/CreateTableWithTimestamps:
123123
Rails/DefaultScope:
124124
Enabled: true
125125

126+
# This cop checks for usage of Rails.env.foo? and prefers it to be replaced with Feature Flags. Since our team
127+
# uses Rails.env.foo rarely in configuration files, this isn't a problem we need to have a cop in place for.
128+
Rails/Env:
129+
Enabled: false
130+
126131
# We were originally going to disable this, but after much discussion agreed that enabling
127132
# this cop with AllowReads: true should be relatively painless.
128133
Rails/EnvironmentVariableAccess:

0 commit comments

Comments
 (0)