Skip to main content

cron-block-generation-gotchas

Guide for writing or debugging code that programmatically generates cron blocks (crontab entries). Use when: (1) a cron job runs fine by hand but silently never fires from cron, (2) writing an `enable`/`install`-style command that appends entries to a user's crontab, (3) cron jobs referring to paths under `~/Documents/...` or `~/Library/...` that contain spaces, (4) cron jobs invoking tools installed to `~/.local/bin`, `~/.cargo/bin`, `~/go/bin`, or a uv/pipx/npm user-install dir, (5) debugging "works in my shell, broken from cron" with no error output. Covers the two interacting gotchas — unquoted-space shell splitting and cron's stripped $PATH — plus how to reproduce cron's environment locally with `env -i` and how to generate a correct block with `shlex.quote()` and `shutil.which()`.

Jump to install

Source facts

Repository
cajias/claude-skills
Last source activity
July 20, 2026 at 07:29
Detected SKILL.md language
English
Stars
0
Forks
0

Install options

The review-first prompt is selected by default. You can switch to a direct command or download a local copy.

Review the source files

Read SKILL.md and any companion files shown by SkillsMP before deciding whether to install.