exclude_paths: - db/migrate/* include_paths: - '*.rjs' - '*.rhtml' # THIS IS INCOMPLETE (you can help by expanding it) # rails is _really complicated_ and has a lot of magic which calls methods for you. # some is currently impossible to handle (with_options). # Some is just corners of rails I haven't hit yet. # TODO: split this up by the actual gems rules: - skip: true names: - ClassMethods # ActiveSupport::Concern - process_action # ActiveSupport::LogSubscriber - validate_each # ActiveModel::EachValidator - format_message # ActiveSupport::Logger - ssl_configured? # ApplicationController - skip: true names: has_suffix: Helper path: /app/helpers - names: - after_initialize - after_find - after_touch - before_validation - after_validation - before_save - around_save - after_save - before_create - around_create - after_create - before_update - around_update - after_update - before_destroy - around_destroy - after_destroy - after_commit - after_rollback - after_create_commit - after_update_commit - after_destroy_commit - after_save_commit calls: arguments: - 1 - if - unless - name: - after_action - append_after_action - append_around_action - append_before_action - around_action - before_action - prepend_after_action - prepend_around_action - prepend_before_action - skip_before_action - skip_after_action - skip_around_action - validates_associated calls: - arguments: - '*' - if - unless - name: validates calls: - arguments: - '*' - 'in' - inclusion - scope - if - unless - keys: '*' camelize: true add_suffix: Validator - names: - validate - validate_associated calls: - arguments: ['*', if, unless] - name: - check_box - date_select - datetime_select - file_field - hidden_field - label - radio_button - select - time_select - time_zone_select - color_field - date_field - datetime_field - datetime_local_field - email_field - month_field - number_field - password_field - phone_field - range_field - search_field - telephone_field - text_area - text_field - time_field - url_field - week_field calls: - arguments: [1,2] # 1: with a receiver, 2: with no receiver - arguments: [1,2] add_suffix: '=' - name: fields_for calls: argument: 1 add_suffix: _attributes - name: options_from_collection_for_select calls: - arguments: [2,3] - name: - collection_select - collection_check_boxes - collection_radio_buttons calls: - argument: 2 add_suffix: '=' - arguments: [4,5] - name: grouped_collection_select calls: - argument: 2 add_suffix: '=' - arguments: [4,5,6,7] - name: option_groups_from_collection_for_select calls: - arguments: [1,2,3,4] - name: scope path: /app/models defines: argument: 1 # ar - name: scope path: /config/routes* calls: argument: module # routes camelize: true - name: namespace calls: - argument: 1 camelize: true - name: - attribute - alias_attribute path: app/models/* defines: argument: 1 linked_transforms: - original - add_suffix: '?' - add_suffix: '=' - name: alias_attribute calls: - argument: 2 - argument: 2 add_suffix: '?' - argument: 2 add_suffix: '=' - name: - has_one - belongs_to calls: argument: 1 camelize: true unless: has_argument: class_name - name: - has_many - has_and_belongs_to_many calls: argument: 1 camelize: true singularize: true unless: has_argument: class_name - name: - has_many - has_one - has_and_belongs_to_many calls: argument: as - name: - has_one - has_many - belongs_to - has_and_belongs_to_many defines: - argument: 1 linked_transforms: - original - add_suffix: '=' calls: - argument: - through - class_name - inverse_of - argument: 1 if: has_argument: dependent - argument: 1 if: has_argument: inverse_of - name: - rescue_from calls: - argument: with - name: - match - delete - get - patch - post - put calls: - arguments: [1, action] - argument: '**' delete_before: '#' - argument: '**' delete_after: '#' camelize: true add_suffix: Controller - name: delegate defines: - argument: '*' if: has_argument: keyword: prefix value: true add_prefix: from_argument: to joiner: '_' - argument: '*' if: has_argument: keyword: prefix value: type: [String, Symbol] add_prefix: from_argument: prefix joiner: '_' calls: - argument: to - argument: '*' if: has_argument: prefix - name: - resource - resources calls: - argument: only - argument: controller camelize: true add_suffix: Controller - name: - resources - controller - namespace calls: - argument: 1 camelize: true add_suffix: Controller - name: accepts_nested_attributes_for defines: argument: '*' linked_transforms: - add_suffix: _attributes - add_suffix: _attributes= calls: argument: reject_if - name: resource calls: - argument: 1 camelize: true pluralize: true add_suffix: Controller - name: - new - create - create! - update - update! - assign_attributes calls: keys: '*' add_suffix: '=' - name: permit calls: arguments: ['*', '**'] keys: '*' add_suffix: "=" - name: layout calls: argument: 1 - name: - includes - preload - eager_load - joins - left_joins - left_outer_joins calls: arguments: ['*', '**'] keys: '*' - name: - string - text - integer - bigint - float - decimal - numeric - datetime - time - date - binary - boolean path: /db/schema.rb calls: argument: 1 transforms: - original - add_suffix: '=' - add_suffix: '?' - name: - cattr_accessor - mattr_accessor defines: - argument: '*' transforms: - original - add_suffix: '=' calls: - argument: '*' add_prefix: '@' - name: - cattr_reader - mattr_reader defines: - argument: '*' calls: - argument: '*' add_prefix: '@' - name: - cattr_writer - mattr_writer defines: - argument: '*' add_suffix: '=' - name: - thread_cattr_accessor - thread_mattr_accessor defines: argument: '*' transforms: - original - add_suffix: '=' - name: - thread_cattr_reader - thread_mattr_reader defines: argument: '*' - name: - thread_cattr_writer - thread_mattr_writer defines: argument: '*' add_suffix: '=' - name: delegate_missing_to calls: argument: 1