Annotate v2.5.0 Release Notes
-
- ๐ Works better with Rails 3
- ๐ Bugfix: schema kept prepending additional newlines
- โก๏ธ Updates to make annotate smarter about when to touch a model
- Recognize column+type, and don't change a file unless the column+type combination of the new schema are different than that of the old (i.e., don't regenerate if columns happen to be in a different order. That's just how life is sometimes.)
- Grab old specification even if it has
\r\n
as line endings rather than pure\n
s - โ Various warning and specification fixes
- ๐ Fix "no such file to load -- annotate/annotate_models (MissingSourceFile)" error (require statements in tasks now use full path to lib files)
- warn about macros, to mitigate when we're included during a production run, not just a rakefile run -- possibly at the expense of too much noise
- โ Adding rake as a runtime dependency
- If the schema is already in the model file, it will be replaced into the same location. If it didn't previously exist, it'll be placed according to the "position", as before.
- ๐ Allow task loading from Rakefile for gems (plugin installation already auto-detects).
- Add skip_on_db_migrate option as well for people that don't want it
- ๐ Fix options parsing to convert strings to proper booleans
- โ Add support for Fabrication fabricators
- Leave magic encoding comment intact
- ๐ Fix issue #14 - RuntimeError: Already memoized
- โ Count a model as 'annotated' if any of its tests/fixtures are annotated
- ๐ Support FactoryGirl
- ๐ Support :change migrations (Rails 3.1)
- ๐ Allow models with non-standard capitalization
- Widen type column so we can handle longtexts with chopping things off.
- Skip trying to get list of models from commandline when running via Rake
(was preventing the use of multiple rake tasks in one command if one of them was
db:migrate
). - โ Add ability to skip annotations for a model by adding
# -*- SkipSchemaAnnotations
anywhere in the file. - Don't show column limits for integer and boolean types.
- โ Add sorting for columns and indexes.
(Helpful for out-of-order migration execution. Use
--sort
if you want this.) - โ Annotate unit tests in subfolders.
- โ Add generator to install rakefile that automatically annotates on
db:migrate
. - Correct Gemfile to clarify which environments need which gems.
- โ Add an .rvmrc to facilitate clean development.
- ๐จ Refactor out ActiveRecord monkey-patch to permit extending without side-effects.
- ๐ Use ObjectSpace to locate models to facilitate handling of models with non-standard capitalization. Note that this still requires that the inflector be configured to understand the special case.
- โ Shore up test cases a bit.
- ๐ Merge against many of the older branches on Github whose functionality is already reflected to reduce confusion about what is and is not implemented here.
- Accept String or Symbol for :position (et al) options.
- โ Add RDoc output formatting as an option.
- โ Add Markdown output formatting as an option.
- โ Add option to force annotation regeneration.
- โ Add new configuration option for controlling where info is placed in fixtures/factories.
- ๐ Fix for models without tables.
- ๐ Fix gemspec generation now that Jeweler looks at Gemfile.
- ๐ Fix warning:
NOTE: Gem::Specification#default_executable= is deprecated with no replacement. It will be removed on or after 2011-10-01.
- ๐ Fix handling of files with no trailing newline when putting annotations at the end of the file.
- Now works on tables with no primary key.
--format=markdown
option--trace
option to help debug "Unable to annotate" errors- "Table name" annotation (if table name is different from model name)
- ๐ "Human name" annotation (enabling translation to non-English locales)
- ๐ Fix JRuby ObjectSpace compatibility bug (https://github.com/ctran/annotate_models/pull/85)
- ๐ Fix FactoryGirl compatibility bug (https://github.com/ctran/annotate_models/pull/82)