crondir
Manage your user crontab with snippets in a cron.d directory in your home.
Simplifies the automated management of cron tasks in the user space. Snippets are concatenated from your cron.d into the crontab.
- Store and manage crontab snippets in separate files
- Does not interfere with existing crontab entries
- Backs up crontab each time it builds
- Everything configurable
Usage
A crontab snippet is a file containing lines to go in a crontab.
To install:
pip install crondir
Add a cron snippet:
crondir add path/to/snippet_name
Remove a cron snippet:
crondir remove snippet_name
List installed cron snippets:
crondir list
Build the crontab from current definitions:
crondir build
Or you may find it easier to skip the install step and run it using uv.
uvx crondir add path/to/snippet_name
uvx crondir remove path/to/snippet_name
uvx crondir list
uvx crondir build
By default, crondir stores crontab snippets in ~/.cron.d/, and creates backups
in ~/.cron.d/backups/.
For full command line options, see command documentation
Example
Lets say we're deploying a project with hourly and daily cron tasks, and will be running
it from a deploy user. Our project is at /home/deploy/project/
Create a snippet file in our project, cron_tasks, containing the lines to add to the
crontab:
0 * * * * /home/deploy/project/bin/hourly_refresh.sh
1 0 * * * /home/deploy/project/bin/daily_refresh.sh
To add this snippet, run:
cd ~
uvx crondir add project/cron_task project_tasks
uvx crondir build
This will:
- create the dir
~/.cron.d/ - copy
project/cron_taskinto~/.cron.d/as~/.cron.d/project_tasks - rebuild the crontab to include the lines from
~/.cron.d/project_tasks
If we want to remove the snippet, we can run:
cd ~
uvx crondir remove project_tasks
uvx crondir build
This will
- remove the file
~/.cron.d/project_tasks - concatenate all the files in
~/.cron.d - add them to the crontab under any existing unmanaged entries
Metadata
Release files for crondir 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| crondir-0.3.0.tar.gz | 8.1 kB | With provenance | Details for crondir-0.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| crondir-0.3.0-py3-none-any.whl | Python 3 | none | any | Details for crondir-0.3.0-py3-none-any.whl |
Total release size: 15.6 kB
Release files / crondir-0.3.0.tar.gz
| Download URL | crondir-0.3.0.tar.gz |
|---|---|
| Size | 8.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
66c9f8a3ff5e5f8ece3e219e0d0f252e0bbff94788b36f4031ac08f6df3b2026
|
|
BLAKE2b-256 checksum How to use checksums |
9ea2acd0e8178371b0cd81f259896760333bd6c3da537bb5928380eb5dd5a20c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 4, 2025.
Transparency logRelease files / crondir-0.3.0-py3-none-any.whl
| Download URL | crondir-0.3.0-py3-none-any.whl |
|---|---|
| Size | 7.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
21ce1849b554f0453d25eea8d1061ae4184cc5dae6dfb76917043f41148d40a2
|
|
BLAKE2b-256 checksum How to use checksums |
d5f1752722e2244e6fbb6c225db3aaa9a94262faf99c0b23ec7c1d93717bd77a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 4, 2025.
Transparency logSecurity for crondir 0.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for crondir-0.3.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 4, 2025.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.