|
4 months ago | |
---|---|---|
scripts | 4 months ago | |
tests | 4 months ago | |
.drone.yml | 4 months ago | |
.pre-commit-config.yaml | 4 months ago | |
Dockerfile | 4 months ago | |
Dockerfile.personal | 4 months ago | |
LICENSE | 4 months ago | |
Makefile | 4 months ago | |
Readme.md | 4 months ago |
A pre-commit plugin, for the drone.io project, which allows you to run pre-commit checks as part of your build steps.
An example configuration would be as follows:
steps:
- name: run checks
image: iamthefij/drone-pre-commit:latest
Or, if you have additional dependencies to install
steps:
- name: run ruby dependent checks
image: iamthefij/drone-pre-commit:latest
commands:
- apt-get update
- apt-get install -y --no-install-recommends ruby
# You must run your own pre-commit command at the end
- pre-commit run --all-files
A second image is also built for my personal use, but it may be useful to you as well. This image includes the following dependencies:
So far this is basic and unopinionated. Either this will become very personal as I tack on dependencies for the hooks I often use, or it'll become complicated as I add args for everything and build out many tags. I think I'll probbably try to provide some reasonable base image that can then be extended in a new image or as part of one's build pipeline.