home / skills / aidotnet / moyucode / cron-scheduler
This skill parses, validates, and explains cron expressions, computes next run times, and helps generate or troubleshoot scheduling.
npx playbooks add skill aidotnet/moyucode --skill cron-schedulerReview the files below or copy the command above to add this skill to your agents.
---
name: cron-scheduler
description: 解析、验证和解释cron表达式,计算下次运行时间。
metadata:
short-description: Cron表达式助手
source:
repository: https://github.com/kiorber/croniter
license: MIT
---
# Cron Scheduler Tool
## Description
Parse, validate, and explain cron expressions. Calculate next run times and generate cron syntax.
## Trigger
- `/cron` command
- User needs cron expression help
- User wants to schedule tasks
## Usage
```bash
# Explain cron expression
python scripts/cron_scheduler.py "0 9 * * 1-5"
# Get next N run times
python scripts/cron_scheduler.py "*/15 * * * *" --next 5
# Generate cron from description
python scripts/cron_scheduler.py --generate "every day at 9am"
# Validate expression
python scripts/cron_scheduler.py "0 0 * * *" --validate
```
## Tags
`cron`, `scheduler`, `automation`, `time`, `jobs`
## Compatibility
- Codex: ✅
- Claude Code: ✅
This skill parses, validates, and explains cron expressions and calculates next run times. It helps users build correct cron syntax from plain-language schedules and troubleshoot ambiguous or invalid expressions. The tool is focused on practical scheduling tasks for automation and job runners.
The skill accepts cron expressions or plain-language schedule descriptions, then parses the expression into its component fields (minute, hour, day, month, weekday). It validates field ranges and syntax, returns human-readable explanations, and can compute the next N execution timestamps. It also supports generating commonly used cron expressions from concise natural-language inputs.
Can the skill handle non-standard cron fields like year or @yearly shortcuts?
It handles standard five-field cron expressions and common shortcuts; support for extended fields may vary—specify the exact format to confirm.
Does it account for daylight saving time?
You should specify the timezone when requesting next run times; DST effects depend on the timezone and are applied if provided.
Can it generate cron expressions from complex natural-language schedules?
It handles common, concise descriptions (daily, hourly, specific time windows). Very complex schedules may need manual refinement after generation.