scheduler by jshchnz/claude-code-scheduler
npx skills add https://github.com/jshchnz/claude-code-scheduler --skill scheduler您可以帮助用户设置和管理定时 Claude Code 任务。您可以:
要创建定时任务:
/scheduler:schedule-add
要查看所有定时任务:
/scheduler:schedule-list
调度器支持一次性和重复任务:
用于在特定时间运行一次的任务:
一次性任务在执行后会自动清理。
用于按计划重复执行的任务:
0 9 * * 1-5除非出现 "every"、"daily"、"weekly" 或类似的重复性关键词,否则任务将被视为。
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
对于会进行更改的任务,worktree 模式会在隔离环境中运行它们:
You: 每天凌晨 2 点,重构已弃用的 API 调用并推送以供审核
Claude: 是否应在隔离的 git worktree 中运行?
→ 是,创建分支并推送更改
→ 否,在主工作目录中运行
You: 是
Claude: ✓ 任务已创建,启用了 worktree 隔离
分支前缀:claude-task/
远程仓库:origin
工作原理:
配置选项:
| 选项 | 默认值 | 描述 |
|---|---|---|
worktree.enabled | false | 启用 worktree 隔离 |
worktree.branchPrefix | "claude-task/" | 分支名前缀 |
worktree.remoteName | "origin" | 要推送到的远程仓库 |
如果推送失败,worktree 将被保留以供手动审查。
* * * * *
| | | | |
| | | | +-- 星期几 (0-6, 周日=0)
| | | +---- 月份 (1-12)
| | +------ 日期 (1-31)
| +-------- 小时 (0-23)
+---------- 分钟 (0-59)
常见模式:
| 模式 | 描述 |
|---|---|
0 9 * * * | 每天上午 9:00 |
0 9 * * 1-5 | 工作日上午 9:00 |
*/15 * * * * | 每 15 分钟 |
0 */2 * * * | 每 2 小时 |
0 9 1 * * | 每月 1 号上午 9:00 |
0 9 * * 1 | 每周一上午 9:00 |
完整语法请参阅 CRON_REFERENCE.md。
任务由您操作系统的原生调度器执行:
平台特定详情请参阅 PLATFORM_SETUP.md。
调度:0 9 * * 1-5 (工作日上午 9 点)
命令:/review-code --scope=yesterday
调度:0 10 * * 1 (每周一上午 10 点)
命令:检查过时的依赖项和安全漏洞
调度:0 */4 * * * (每 4 小时)
命令:运行测试套件并报告失败情况
任务未运行?
/scheduler:schedule-status 了解健康状况/scheduler:schedule-list/scheduler:schedule-logs <task-id>claude CLI 在 PATH 中常见问题:
要验证 cron 表达式:
python scripts/parse-cron.py "0 9 * * 1-5"
| 命令 | 描述 |
|---|---|
/scheduler:schedule-add | 创建新的定时任务 |
/scheduler:schedule-list | 查看所有定时任务 |
/scheduler:schedule-remove <id> | 移除定时任务 |
/scheduler:schedule-status | 检查调度器健康状况 |
/scheduler:schedule-run <id> | 手动运行任务 |
/scheduler:schedule-logs <id> | 查看执行日志 |
每周安装次数
274
代码仓库
GitHub 星标数
490
首次出现
2026年2月4日
安全审计
安装于
opencode267
gemini-cli264
codex263
github-copilot263
cursor263
kimi-cli256
You help users set up and manage scheduled Claude Code tasks. You can:
To create a scheduled task:
/scheduler:schedule-add
To view all scheduled tasks:
/scheduler:schedule-list
The scheduler supports both one-time and recurring tasks:
For tasks that run once at a specific time:
One-time tasks automatically clean up after execution.
For tasks that repeat on a schedule:
0 9 * * 1-5Detection rule: Unless "every", "daily", "weekly", or similar recurring keywords are present, the task is treated as one-time.
For tasks that make changes, worktree mode runs them in isolation:
You: Every night at 2am, refactor deprecated API calls and push for review
Claude: Should this run in an isolated git worktree?
→ Yes, create branch and push changes
→ No, run in main working directory
You: Yes
Claude: ✓ Task created with worktree isolation
Branch prefix: claude-task/
Remote: origin
How it works:
Configuration options:
| Option | Default | Description |
|---|---|---|
worktree.enabled | false | Enable worktree isolation |
worktree.branchPrefix | "claude-task/" | Branch name prefix |
worktree.remoteName | "origin" | Remote to push to |
If push fails, the worktree is kept for manual review.
* * * * *
| | | | |
| | | | +-- Day of week (0-6, Sun=0)
| | | +---- Month (1-12)
| | +------ Day of month (1-31)
| +-------- Hour (0-23)
+---------- Minute (0-59)
Common patterns:
| Pattern | Description |
|---|---|
0 9 * * * | Daily at 9:00 AM |
0 9 * * 1-5 | Weekdays at 9:00 AM |
*/15 * * * * | Every 15 minutes |
0 */2 * * * | Every 2 hours |
0 9 1 * * | First of month at 9:00 AM |
0 9 * * 1 | Every Monday at 9:00 AM |
For complete syntax, see CRON_REFERENCE.md.
Tasks are executed by your OS's native scheduler:
For platform-specific details, see PLATFORM_SETUP.md.
Schedule: 0 9 * * 1-5 (weekdays at 9am)
Command: /review-code --scope=yesterday
Schedule: 0 10 * * 1 (Mondays at 10am)
Command: Check for outdated dependencies and security vulnerabilities
Schedule: 0 */4 * * * (every 4 hours)
Command: Run test suite and report failures
Task not running?
/scheduler:schedule-status for health/scheduler:schedule-list/scheduler:schedule-logs <task-id>claude CLI is in PATH for schedulerCommon issues:
To validate a cron expression:
python scripts/parse-cron.py "0 9 * * 1-5"
| Command | Description |
|---|---|
/scheduler:schedule-add | Create a new scheduled task |
/scheduler:schedule-list | View all scheduled tasks |
/scheduler:schedule-remove <id> | Remove a scheduled task |
/scheduler:schedule-status | Check scheduler health |
/scheduler:schedule-run <id> | Manually run a task |
/scheduler:schedule-logs <id> |
Weekly Installs
274
Repository
GitHub Stars
490
First Seen
Feb 4, 2026
Security Audits
Gen Agent Trust HubWarnSocketPassSnykPass
Installed on
opencode267
gemini-cli264
codex263
github-copilot263
cursor263
kimi-cli256
Azure Data Explorer (Kusto) 查询技能:KQL数据分析、日志遥测与时间序列处理
102,600 周安装
| View execution logs |