Skip to content

Cleanup/refactor #33

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 24, 2021
Merged

Cleanup/refactor #33

merged 1 commit into from
Jan 24, 2021

Conversation

bunnymatic
Copy link
Member

@bunnymatic bunnymatic commented Jan 23, 2021

Problem

Running rubocop indentified a lot of little issues for cleanup.
In doing this cleanup, there was some refactoring done that changes the
overall API for a few things. There will be deprecation warnings for the functions that have been moved/removed.

Changes

  • MojoMagick::get_fonts renamed to MojoMagick::available_fonts
  • Move execute! and execute and raw_command methods into MojoMagick::Commands
  • Move MojoMagick::Util::Parser to MojoMagick::Util::FontParser
  • Don't mixin ImageMagick::Fonts and let available_fonts provide the font list (this effectively removes MojoMagic::get_fonts. You can get the same functionality from MojoMagick::available_fonts)
  • Add deprecation warnings for missing methods
  • rubocop cleanup
  • make test methods shorter and better named
  • Sequester deprecated methods for easy removal later

@bunnymatic bunnymatic force-pushed the chores/cleanup-and-refactor branch 3 times, most recently from 268a694 to 00b62b4 Compare January 24, 2021 00:25
Problem
--------

Running `rubocop` indentified a lot of little issues for cleanup.
In doing this cleanup, there was some refactoring done that changes the
overall API.  Deprecation warnings have been added.

Solution
--------

* Add `Commands` class to pull some command running helpers out of the
  main module
* Don't mix in ImageMagick::Fonts (which removes `MojoMagick.get_fonts`
  method)
* Add deprecation warnings for missing methods
* rubocop cleanup
* make test methods shorter and better named
* Move from `Parser` to `FontParser` and add deprecations
* Sequester deprecated methods for easy removal later
* Add rubocop check to circle
* Update readme to reflect moves
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant