Skip to main content

A Cron Expression Parser

Project description

Cronpar - a tool for parsing cron expression

Requirements

To run this program, you need setup you local environment as following

  • A Python Environment with Python 3.8+ and pip (reckon use pyenv and create a virtualenv)
  • Poetry (Dependency management)
  • make (a dev tool)

Setup

Before you can run everything, please make sure you have setup a Python environment

if you are using make, you can setup the dev environmane by simply using

make init

this will install poetry and install all dependencies. If you don't want to use make, alternatively, just run the following commands

pip install poetry
poetry install

To prepare/build the cli tool for you to play with, run

make build

or, just run

pipx install .

Now, you should be able to run the program, for example

cronpar explain "*/15 0 1,15 * 1-5 /usr/bin/find"

Yesting & Contribution

There are some test cases generated during development, to run the tests, you can either run

make test

pr

poetry run pytest tests/ --cov --cov-fail-under 89

Please make sure you have tested all the changes you made properly, and all tests passed before you push

Also, it will be good to keep the code formatted, you can check this by running

make format
make lint

or

poetry run black --preview --line-length 120 cronpar
poetry run isort --line-length 120 cronpar
poetry run flakehell lint .

Notice

Please Note this program is still in development, it may be not very stable, but we will fix and add more features in the coming future.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cronpar-1.0.0.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cronpar-1.0.0-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file cronpar-1.0.0.tar.gz.

File metadata

  • Download URL: cronpar-1.0.0.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.1 CPython/3.9.18 Linux/5.15.0-1041-azure

File hashes

Hashes for cronpar-1.0.0.tar.gz
Algorithm Hash digest
SHA256 4eaf50475085847fb8c0b51feeaee43f43bdb6ebf8f599c2768245163acc1bf8
MD5 1ef41d8033075b092a6fe6172c7ef9f8
BLAKE2b-256 483ddea7c075468f7d0f2ee127e0ff0d8e41967ec91e5ff0a8804e75fb1365ad

See more details on using hashes here.

File details

Details for the file cronpar-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: cronpar-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.1 CPython/3.9.18 Linux/5.15.0-1041-azure

File hashes

Hashes for cronpar-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5bb580dea5006e806d2cd1b33b703ce6a107659148fd157b52fd095ec833d7f6
MD5 60cd755ff4d7de0839ddeba0c6c93ae6
BLAKE2b-256 7e9840e170a954c704e369eee66f75614ea0b6e282946f7c286b9fb7289e51f3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page