lib/the_schema_is/cops.rb
# We need this method to tell Rubocop that EVEN if app/models/user.rb haven't changed, and
# .rubocop.yml haven't changed, we STILL may need to rerun the cop if schema.rb have changed.
We need this method to tell Rubocop that EVEN if app/models/user.rb haven't changed, and
.rubocop.yml haven't changed, we STILL may need to rerun the cop if schema.rb have changed.
We need this method to tell Rubocop that EVEN if app / models / user . rb haven ' t changed and . rubocop . yml haven ' t changed we STILL may need to rerun the cop if schema . rb have changed .
def external_dependency_checksum
      return unless schema_path
      Digest::SHA1.hexdigest(File.read(schema_path))
    end
def external_dependency_checksum return unless schema_path Digest :: SHA1 . hexdigest ( File . read ( schema_path ) ) end
We need this method to tell Rubocop that EVEN if app/models/user.rb haven't changed, and
.rubocop.yml haven't changed, we STILL may need to rerun the cop if schema.rb have changed.
We need this method to tell Rubocop that EVEN if app / models / user . rb haven ' t changed and . rubocop . yml haven ' t changed we STILL may need to rerun the cop if schema . rb have changed .