Skip to content
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

Running one offs in development is synchronous by default #6

Merged
merged 1 commit into from
Apr 11, 2020

Conversation

hasghari
Copy link
Contributor

No description provided.

@codeclimate
Copy link

codeclimate bot commented Apr 11, 2020

Code Climate has analyzed commit ae55787 and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 100.0% (0.0% change).

View more on Code Climate.

require 'one_off/migrator'
OneOff::Migrator.run
args.with_defaults(async: !Rails.env.development?)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@paul-mannino In development the one offs will be run inline by default.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice... glad you beat me to the punch because this is more elegant than what I had in mind.

@hasghari hasghari merged commit 6bf77ce into master Apr 11, 2020
@hasghari hasghari deleted the hasghari/optional-async branch April 11, 2020 15:34
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.

2 participants