Skip to content
Snippets Groups Projects
Commit 47879268 authored by nimrod's avatar nimrod
Browse files

Many updates.

- README.
- pre-commit.
- GitLab CI.
parent a2a6107b
Branches
No related tags found
No related merge requests found
Pipeline #427 passed
---
include:
- project: shore/ci-templates
file: templates/pre-commit.yml
- project: shore/ci-templates
file: templates/pre-commit-repo.yml
# vim:ff=unix ts=2 sw=2 ai expandtab
--- ---
repos: repos:
- repo: https://github.com/pre-commit/pre-commit-hooks - repo: https://github.com/pre-commit/pre-commit-hooks.git
rev: v2.2.3 rev: v3.4.0
hooks: hooks:
- id: check-added-large-files - id: check-added-large-files
- id: check-executables-have-shebangs - id: check-executables-have-shebangs
- id: check-merge-conflict - id: check-merge-conflict
- id: detect-private-key - id: check-symlinks
- id: trailing-whitespace - id: trailing-whitespace
- repo: https://github.com/Yelp/detect-secrets
rev: v0.14.3
hooks:
- id: detect-secrets
- repo: https://github.com/adrienverge/yamllint - repo: https://github.com/adrienverge/yamllint
rev: v1.16.0 rev: v1.25.0
hooks: hooks:
- id: yamllint - id: yamllint
- repo: https://github.com/amperser/proselint
- repo: https://github.com/amperser/proselint/
rev: 0.10.2 rev: 0.10.2
hooks: hooks:
- id: proselint - id: proselint
types: [plain-text] types: [plain-text]
exclude: LICENSE exclude: LICENSE
- repo: https://www.shore.co.il/git/shell-pre-commit/
- repo: https://github.com/executablebooks/mdformat.git
rev: 0.5.3
hooks:
- id: mdformat
- repo: https://git.shore.co.il/nimrod/shell-pre-commit.git
rev: v0.6.0 rev: v0.6.0
hooks: hooks:
- id: shell-lint - id: shell-lint
- repo: https://github.com/shellcheck-py/shellcheck-py.git
rev: v0.7.1.1
hooks:
- id: shellcheck - id: shellcheck
- repo: https://github.com/pre-commit/pre-commit.git
rev: v2.9.3
hooks:
- id: validate_manifest
- repo: local - repo: local
hooks: hooks:
- id: hadolint - id: hadolint
...@@ -33,11 +55,3 @@ repos: ...@@ -33,11 +55,3 @@ repos:
language: script language: script
entry: pre-commit-docker-wrapper entry: pre-commit-docker-wrapper
args: [hadolint] args: [hadolint]
- id: dockerfile-lint
name: dockerfile-lint
description: A rule based 'linter' for Dockerfiles
minimum_pre_commit_version: '0.18.0'
types: [dockerfile]
language: script
entry: pre-commit-docker-wrapper
args: [hadolint]
...@@ -17,5 +17,3 @@ RUN apk add --update --no-cache --repository http://dl-cdn.alpinelinux.org/alpin ...@@ -17,5 +17,3 @@ RUN apk add --update --no-cache --repository http://dl-cdn.alpinelinux.org/alpin
hadolint --version hadolint --version
COPY docker-compose-config dockerfile-lint /usr/local/bin/ COPY docker-compose-config dockerfile-lint /usr/local/bin/
USER nobody USER nobody
LABEL Name docker-pre-commit
LABEL Version 0.3.0
# Docker pre-commmit # Docker pre-commmit
[![pipeline status](https://git.shore.co.il/nimrod/docker-pre-commit/badges/master/pipeline.svg)](https://git.shore.co.il/nimrod/docker-pre-commit/-/commits/master)
> Pre-commit hooks for Docker and docker-compose. > Pre-commit hooks for Docker and docker-compose.
## Requirements ## Requirements
...@@ -7,13 +9,6 @@ ...@@ -7,13 +9,6 @@
- [Docker](https://www.docker.com/). - [Docker](https://www.docker.com/).
- [pre-commit](https://pre-commit.com/) 0.18.0 or later. - [pre-commit](https://pre-commit.com/) 0.18.0 or later.
## Hooks
- `hadolint` - The [hadolint](https://github.com/hadolint/hadolint) Dockerfile
linter.
- `docker-compose` - Validate the Docker Compose file using `docker-compose
config`.
## Usage example ## Usage example
```yaml ```yaml
...@@ -31,7 +26,7 @@ This software is licensed under the MIT license (see `LICENSE.txt`). ...@@ -31,7 +26,7 @@ This software is licensed under the MIT license (see `LICENSE.txt`).
## Author Information ## Author Information
Nimrod Adar, [contact me](mailto:nimrod@shore.co.il) or visit my [website]( Nimrod Adar, [contact me](mailto:nimrod@shore.co.il) or visit my
https://www.shore.co.il/). Patches are welcome via [`git send-email`]( [website](https://www.shore.co.il/). Patches are welcome via
http://git-scm.com/book/en/v2/Git-Commands-Email). The repository is located [`git send-email`](http://git-scm.com/book/en/v2/Git-Commands-Email). The repository
at: <https://git.shore.co.il/nimrod/>. is located at: <https://git.shore.co.il/expore/>.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment