PHPackages                             valorin/cronsync - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [CLI &amp; Console](/categories/cli)
4. /
5. valorin/cronsync

AbandonedLibrary[CLI &amp; Console](/categories/cli)

valorin/cronsync
================

CronSync is a way to define your artisan command cron schedule within your code (and therefore in version control), by updating the crontab as part of your deploy process.

v1.0.3(11y ago)1471MITPHPPHP &gt;=5.4.0

Since Aug 16Pushed 11y ago1 watchersCompare

[ Source](https://github.com/valorin/cronsync)[ Packagist](https://packagist.org/packages/valorin/cronsync)[ RSS](/packages/valorin-cronsync/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (2)Versions (5)Used By (0)

CronSync
========

[](#cronsync)

Inspired by [Dispatcher](https://github.com/indatus/dispatcher), CronSync is a way to define your artisan command cron schedule within your code (and therefore in version control), by updating the crontab as part of your deploy process, without needing to run a separate process every minute to check for any cron tasks.

Running `php artisan cronsync` after pushing out new code will ensure the current user's crontab is configured to match the cron definitions automatically.

Installation
------------

[](#installation)

Add the package to your application with composer:

```
composer require "valorin/cronsync:~1.0"

```

Add the Service Provider to the `providers` list in `./app/config/app.php`:

```
'providers' => array(
    ...
    'Valorin\CronSync\ServiceProvider',
),

```

Usage
-----

[](#usage)

To define a cron schedule in an artisan command, first add the `CronCommandInterface` onto the command:

```
use Valorin\CronSync\CronCommandInterface;
...
class ClassName extends Command implements CronCommandInterface

```

Then implement the `schedule()` command in the class to return the cron schedule expression:

```
/**
 * Returns the cron schedule to use
 *
 * @return string|string[]
 */
public function schedule()
{
    // Every hour at 42 minutes past the hour
    return '42 * * * *';
}

```

To support parameters on the artisan command, return an array:

```
    return ['*/5 * * * *', '--option --option2="value" argument1'];

```

Then run the `dry-run` command to check that the cron will be configured correctly:

```
php artisan cronsync --dry-run

```

If it all looks good, you can drop the `--dry-run` off the end:

```
php artisan cronsync

```

**IMPORTANT:** CronSync uses `base_path()` to identify existing cron entries that need to be removed before it adds it's own. If you have custom cron entries which are **not**linked to artisan commands but do include the `base_path()`, they will be removed. Either implement them via artisan commands, or add them into the `custom_commands` config option.

Configuration
-------------

[](#configuration)

To change the default configuration, run:

```
./artisan config:publish "valorin/cronsync"

```

And then edit the configuration file at:

```
./app/config/packages/valorin/cronsync/config.php

```

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

4

Last Release

4340d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/6c2eb86dddee75463a43c6457f38413b61cc0009232881df800a3842e2d89f7b?d=identicon)[valorin](/maintainers/valorin)

---

Top Contributors

[![valorin](https://avatars.githubusercontent.com/u/897369?v=4)](https://github.com/valorin "valorin (5 commits)")

---

Tags

laravelartisancron

### Embed Badge

![Health badge](/badges/valorin-cronsync/health.svg)

```
[![Health](https://phpackages.com/badges/valorin-cronsync/health.svg)](https://phpackages.com/packages/valorin-cronsync)
```

###  Alternatives

[laravel/sail

Docker files for running a basic Laravel application.

1.9k205.7M1.3k](/packages/laravel-sail)[laravel/ai

The official AI SDK for Laravel.

1.0k3.2M194](/packages/laravel-ai)[laravel/mcp

Rapidly build MCP servers for your Laravel applications.

77022.3M151](/packages/laravel-mcp)[propaganistas/laravel-disposable-email

Disposable email validator

6023.0M7](/packages/propaganistas-laravel-disposable-email)[tallstackui/tallstackui

TallStackUI is a powerful suite of Blade components that elevate your workflow of Livewire applications.

725173.2k14](/packages/tallstackui-tallstackui)[laravel/surveyor

Static analysis tool for Laravel applications.

86121.4k13](/packages/laravel-surveyor)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
