cron-management
Tools for registering, listing, and managing persistent cron tasks for AI agents.
Install
mkdir -p .claude/skills/cron-management && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/16153" && unzip -o skill.zip -d .claude/skills/cron-management && rm skill.zipInstalls to .claude/skills/cron-management
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Manage scheduled tasks (crons). Use when: setting up crons on session start, creating new recurring tasks, or troubleshooting scheduled tasks.Key capabilities
- →List all registered crons with next_fire_at
- →Add new crons with interval or cron expression
- →Remove existing crons by name
- →Update cron schedules, prompts, or enabled status
- →Check cron execution history
- →Troubleshoot cron firing and agent reaction issues
How it works
This skill manages scheduled tasks by interacting with the cortextOS daemon to add, remove, update, and list crons, which are stored externally and survive agent restarts.
Inputs & outputs
When to use cron-management
- →Schedule a daily morning briefing email
- →Set up a recurring data cleanup task
- →Register a heartbeat check
- →Remove a stale scheduled job
About this skill
Cron Management
Your scheduled tasks are daemon-managed external crons. They are stored in
${CTX_ROOT}/state/{agent}/crons.json and scheduled by the cortextOS daemon.
Crons survive agent restarts, context compactions, and daemon restarts automatically —
you do NOT need to recreate them on session start.
On Session Start
Check that your crons are registered. You do not need to recreate them.
# List all crons with next_fire_at
cortextos bus list-crons $CTX_AGENT_NAME
If a cron is missing (not in the list), add it:
cortextos bus add-cron $CTX_AGENT_NAME <name> <interval|cron-expr> "<prompt>"
# Examples:
cortextos bus add-cron $CTX_AGENT_NAME heartbeat 4h "Run heartbeat protocol"
cortextos bus add-cron $CTX_AGENT_NAME morning-briefing "0 9 * * *" "Send morning briefing"
Adding a New Cron
# Interval shorthand (s/m/h/d/w)
cortextos bus add-cron $CTX_AGENT_NAME <name> <interval> "<prompt>"
# 5-field cron expression (minute hour dom month dow)
cortextos bus add-cron $CTX_AGENT_NAME <name> "<cron-expr>" "<prompt>"
The cron is written to crons.json atomically and the scheduler is reloaded.
No /loop call needed — the daemon fires crons directly into your PTY.
manualFireDisabled: If you want a cron to only fire on schedule (not manually
test-fired from the dashboard), set manualFireDisabled: true in the definition.
Contact the operator or use the dashboard edit form to set this flag.
Removing a Cron
cortextos bus remove-cron $CTX_AGENT_NAME <name>
Updating a Cron
Use the dashboard (/workflows/[agent]/[name]) or the bus command (if available):
cortextos bus update-cron $CTX_AGENT_NAME <name> --schedule <new-schedule>
cortextos bus update-cron $CTX_AGENT_NAME <name> --prompt "<new-prompt>"
cortextos bus update-cron $CTX_AGENT_NAME <name> --enabled false
Checking Execution History
# Recent execution log (fired / retried / failed entries)
cortextos bus get-cron-log $CTX_AGENT_NAME
# Filtered to a specific cron
cortextos bus get-cron-log $CTX_AGENT_NAME --cron <name>
Cron Expiry
External crons do not expire. They fire on schedule until disabled or removed.
The old 3-day /loop expiry no longer applies.
Troubleshooting
Cron not firing:
cortextos bus list-crons $CTX_AGENT_NAME— confirm it is registered and has anext_fire_atcortextos bus get-cron-log $CTX_AGENT_NAME— check forstatus: retriedorstatus: failedentries- If PTY injection is failing, check the daemon log:
~/.cortextos/$CTX_INSTANCE_ID/logs/$CTX_AGENT_NAME/
Cron fires but agent does not react:
- The daemon injects
[CRON: <name>] <prompt>into your PTY. If you see this in your conversation history but did not act, it was an older session. - Check daemon log; PTY injection retries 3 times (1s/4s/16s backoff).
crons.json corrupted:
readCronsautomatically falls back tocrons.json.bakon parse failure.- If both files are bad, add crons back via
cortextos bus add-cron. - See
CRONS_MIGRATION_GUIDE.mdfor full recovery procedures.
Crons disappeared after daemon reload (reload-to-empty):
- The daemon's
lastGoodScheduleprotection keeps crons firing in memory during transient corruption. - Check stderr logs for
WARNING: reload produced empty scheduleto confirm this triggered. - Repair
crons.jsonand the scheduler will pick up the fix on the next reload.
Migration from config.json (legacy)
If your agent was set up before the external-crons migration, your crons lived in
config.json. The daemon auto-migrates them to crons.json on first boot.
A .crons-migrated marker file prevents re-runs. See CRONS_MIGRATION_GUIDE.md
for details and manual migration instructions.
When not to use it
- →When crons need to be recreated on session start
- →When crons are expected to expire automatically
- →When the user needs to manually edit `crons.json` directly
Limitations
- →Crons do not expire automatically
- →Manual editing of `crons.json` is not the primary method of management
- →PTY injection issues may require checking daemon logs
How it compares
This skill provides a persistent, daemon-managed system for scheduled tasks, eliminating the need to recreate crons on session start and offering reliable management tools, unlike temporary in-session scheduling.
Compared to similar skills
cron-management side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| cron-management (this skill) | 0 | 3mo | Review | Intermediate |
| setup | 12 | 1mo | No flags | Beginner |
| tmux | 20 | 3mo | Review | Intermediate |
| macos-cleaner | 16 | 2mo | Review | Beginner |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
setup
barefootford
Sets up a Mac for ButterCut. Installs all required dependencies (Homebrew, Ruby, Python, FFmpeg, WhisperX). Use when user says "install buttercut", "set up my mac", "get started", "first time setup", "install dependencies" or "check my installation".
tmux
openclaw
Remote-control tmux sessions for interactive CLIs by sending keystrokes and scraping pane output.
macos-cleaner
daymade
Analyze and reclaim macOS disk space through intelligent cleanup recommendations. This skill should be used when users report disk space issues, need to clean up their Mac, or want to understand what's consuming storage. Focus on safe, interactive analysis with user confirmation before any deletions.
ms365-tenant-manager
alirezarezvani
Microsoft 365 tenant administration for Global Administrators. Automate M365 tenant setup, Office 365 admin tasks, Azure AD user management, Exchange Online configuration, Teams administration, and security policies. Generate PowerShell scripts for bulk operations, Conditional Access policies, license management, and compliance reporting. Use for M365 tenant manager, Office 365 admin, Azure AD users, Global Administrator, tenant configuration, or Microsoft 365 automation.
agent-workflow-automation
ruvnet
Agent skill for workflow-automation - invoke with $agent-workflow-automation
tmux-terminal
mikeyobrien
Interactive terminal control via tmux for TUI apps, prompts, and long-running CLI workflows.