symfony-scheduler — Claude Code skill: what it does, how to install
Configures recurring tasks with the Symfony Scheduler component without system crontab entries. Useful for scheduled report generation, database cleanups, and Messenger syncs.
MIT ★ 234 updated 2026-10-05
npx skills add dev-toolings/superpowers-symfony --skill symfony-scheduler -a claude-codeWhat symfony-scheduler does
The skill guides Claude Code when building recurring workloads on top of symfony/scheduler, native to Symfony 7.x. The agent generates ScheduleProviderInterface classes marked with #[AsSchedule], sets up every() intervals or cron() expressions with explicit timezones, and connects them to #[AsMessageHandler] handlers.
Execution guards are part of the output. The skill attaches stateful() and lock() calls to the schedule and prepares the messenger:consume scheduler_default command for Supervisor. Running multiple worker processes without a lock causes duplicate runs. Handlers also need to remain idempotent in case a task repeats.
What it helps with
- run scheduled tasks without configuring system crontab entries
- split background jobs across separate schedules using
#[AsSchedule] - block duplicate executions of heavy jobs with locks and state tracking
- write Supervisor consumer configurations with
--time-limitrecycling
Example prompts for the agent
- Configure a Symfony Scheduler provider to clean old logs every six hours.
- Set up a scheduled report job with a lock factory to prevent overlapping executions.
- Generate a Supervisor worker config for
scheduler_defaultwith a time limit flag.
How to install symfony-scheduler
1Skills CLI (Vercel)
npx skills add dev-toolings/superpowers-symfony --skill symfony-scheduler -a claude-code2Manually: put the files in place
~/.claude/skills/symfony-scheduler/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/symfony-scheduler/
1Skills CLI (Vercel)
npx skills add dev-toolings/superpowers-symfony --skill symfony-scheduler -a codex2Manually: put the files in place
.agents/skills/symfony-scheduler/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add dev-toolings/superpowers-symfony --skill symfony-scheduler -a cursor2Manually: put the files in place
.cursor/skills/symfony-scheduler/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install dev-toolings/superpowers-symfony content/skills/symfony-scheduler2Manually: put the files in place
.github/skills/symfony-scheduler/SKILL.md1Skills CLI (Vercel)
npx skills add dev-toolings/superpowers-symfony --skill symfony-scheduler -a gemini-cli2Platform CLI
gemini skills install https://github.com/dev-toolings/superpowers-symfony --path content/skills/symfony-schedulerManually: put the files in place
.devin/skills/symfony-scheduler/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about symfony-scheduler
How do I install symfony-scheduler in Claude Code?
Run npx skills add dev-toolings/superpowers-symfony --skill symfony-scheduler -a claude-code in your terminal.
What does symfony-scheduler do?
It guides Claude Code in defining recurring PHP jobs using Symfony Scheduler, setting up every or cron triggers, and routing messages through Symfony Messenger.
How does it prevent overlapping task executions?
It applies a lock via lock() on the Schedule instance and specifies numprocs=1 for the consumer worker in Supervisor.
Source text
SKILL.md · MIT
---
name: symfony-scheduler
description: Schedule recurring tasks with the Symfony Scheduler component (native since 7.x); define schedules, triggers, and integrate with Messenger
capabilities: [read, search, edit, shell]
tags: [messenger]
# projected by `bun run build` — do not edit by hand
allowed-tools:
- Read
- Glob
- Grep
- Write
- Edit
- Bash
---
# Symfony Scheduler (Symfony)
## Use when
- Running recurring work (reports, cleanups, syncs) without system cron entries.
- Choosing between `RecurringMessage::every()`, `RecurringMessage::cron()`, and a custom `TriggerInterface`.
- Splitting jobs into several named schedules with `#[AsSchedule]`.
- Preventing overlap or lost runs of heavy scheduled tasks.
## Default workflow
1. Install `symfony/scheduler`, then write the message and its `#[AsMessageHandler]` handler.
2. Create a `#[AsSchedule('default')]` class implementing `ScheduleProviderInterface` and add `RecurringMessage` entries.
3. Pick the trigger: `every('5 minutes')` or `cron('0 */6 * * *')`, with an explicit timezone for cron.
4. Add `stateful($cache)` and `lock($lockFactory->createLock('scheduler'))` on the `Schedule` for heavy tasks.
5. Run it with `messenger:consume scheduler_default` under Supervisor, one process per schedule.
6. Log with `PreRunEvent` and `PostRunEvent`, and test the provider through `getRecurringMessages()` and `getNextRunDate()`.
## Guardrails
- Run a single consumer per schedule (`numprocs=1`) and add a lock, or the same task fires twice.
- Be explicit about timezones on every cron trigger.
- Scheduled handlers must be idempotent, since a run can be repeated.
- Use `--time-limit` with Supervisor `autorestart` so the long-lived worker recycles itself.
## Progressive disclosure
- Use this file for execution posture and risk controls.
- Open references when deep implementation details are needed.
## Output contract
- The schedule provider(s) with their triggers and timezone.
- The worker command and the Supervisor entry.
- The overlap policy (stateful, lock) and the monitoring hooks.
## References
- `reference.md`
© dev-toolings · MIT · dev-toolings/superpowers-symfony