Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/annotate.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ module Annotate
OTHER_OPTIONS = [
:ignore_columns, :skip_on_db_migrate, :wrapper_open, :wrapper_close,
:wrapper, :routes, :hide_limit_column_types, :hide_default_column_types,
:ignore_routes, :active_admin
:ignore_routes, :active_admin, :models
].freeze
PATH_OPTIONS = [
:require, :model_dir, :root_dir
Expand Down Expand Up @@ -114,7 +114,7 @@ def self.include_routes?
end

def self.include_models?
ENV['routes'] !~ TRUE_RE
ENV['models'] =~ TRUE_RE
end

def self.loaded_tasks=(val)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ if Rails.env.development?
# You can override any of these by setting an environment variable of the
# same name.
Annotate.set_defaults(
'models' => 'true',
'routes' => 'false',
'position_in_routes' => 'before',
'position_in_class' => 'before',
Expand Down