Skip to content

sco1/pre-commit-fail-randomly

Repository files navigation

pre-commit-fail-randomly

GitHub - License pre-commit.ci status Code style: black

Randomly fail a pre-commit run

Using pre-commit-fail-randomly with pre-commit

Add this to your .pre-commit-config.yaml

repos:
-   repo: https://github.com/sco1/pre-commit-fail-randomly
    rev: v0.1.0
    hooks:
    -   id: fail-randomly
        args: [--fail-chance=0.05]

Hooks

fail-randomly

Randomly fail your pre-commit pipeline. fail-chance may be optionally specified to change your failure chance (default: 0.05). Ideally this is a float between 0 and 1, inclusive, but you can do what you'd like and live with the consequences. If you specify a negative value then the universe has decided you get a 50/50 shot at failure.

About

Randomly fail a pre-commit run

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Languages