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

[5.5] Add an everyFifteenMinutes function to the ManagesFrequencies trait t… #21092

Merged
merged 4 commits into from
Sep 8, 2017

Conversation

mmccaff
Copy link
Contributor

@mmccaff mmccaff commented Sep 8, 2017

I often want to schedule things to run four times an hour (every 15 minutes).

I know that using ->cron('*/15 * * * * *') is an option, but would rather use an everyFifteenMinutes function, like the existing everyMinute, everyFiveMinutes, everyTenMinutes, everyThirtyMinutes, etc.

I saw a few people ask for this, so thought it'd be a nice simple PR to add to the framework.

@mmccaff mmccaff changed the title Add an everyFifteenMinutes function to the ManagesFrequencies trait t… [5.5] Add an everyFifteenMinutes function to the ManagesFrequencies trait t… Sep 8, 2017
@taylorotwell taylorotwell merged commit 37170a3 into laravel:5.5 Sep 8, 2017
@paulofreitas
Copy link
Contributor

I'm not against this but I think we're going in the wrong way... What was really missing here was a new every() method like this implementation. This would have covered all those specific cases. 👍

@ezaca
Copy link

ezaca commented Sep 9, 2017

Way too specific! Shouldn't use PHP relative formats through the class DateInterval for that?

E.g.: ->everyInterval('15 minutes')

vaughany added a commit to vaughany/docs that referenced this pull request Sep 16, 2017
Documenting this recent commit: laravel/framework#21092
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.

4 participants