-
Add option for additional file patterns (#633) · f95913baRyan authored
This PR adds an option named `additional_file_patterns`. You can specify custom path patterns (including globs) that the gem will use to annotate. For example, I used it like this on a project: ```ruby Annotate.set_defaults( 'additional_file_patterns' => [ File.join(Rails.application.root, 'app/lib/forms/%PLURALIZED_MODEL_NAME%/**/*.rb'), File.join(Rails.application.root, 'spec/lib/forms/%PLURALIZED_MODEL_NAME%/**/*.rb') ], ... ) ``` This makes it possible to have files nested under a directory which corresponds to the model. I believe this fixes #594.
f95913ba
×