Commit 642d06df authored by nimrod's avatar nimrod
Browse files

pre-commit.

- Adding checks.
- Add to CI.
- Address issues.
parent 262f5a05
Loading
Loading
Loading
Loading

.envrc

100755 → 100644
+0 −0

File mode changed from 100755 to 100644.

+6 −1
Original line number Diff line number Diff line
@@ -2,6 +2,10 @@
variables:
  GIT_SUBMODULE_STRATEGY: recursive

include:
  - project: shore/ci-templates
    file: templates/pre-commit.yml

build:
  tags: ["host01.shore.co.il"]
  script:
@@ -15,4 +19,5 @@ build:
      --volume "/var/www/www.shore.co.il/blog:/builds/nimrod/blog/output"
      --workdir "$PWD"
      adarnimrod/ci-images:python3
      /bin/sh -xc "pipenv --python=python3 install && pipenv run clean && pipenv run build"
      /bin/sh -xc
      "pipenv --python=python3 install && pipenv run clean && pipenv run build"
+89 −0
Original line number Diff line number Diff line
---
repos:
  - repo: https://github.com/pre-commit/pre-commit-hooks
    rev: v3.4.0
    hooks:
      - id: check-executables-have-shebangs
      - id: check-merge-conflict
      - id: check-toml
        files: Pipfile
      - id: trailing-whitespace

  - repo: https://github.com/Yelp/detect-secrets
    rev: v0.14.3
    hooks:
      - id: detect-secrets
        exclude: Pipfile\.lock

  - repo: https://github.com/adrienverge/yamllint
    rev: v1.25.0
    hooks:
      - id: yamllint

  - repo: https://github.com/amperser/proselint/
    rev: 0.10.2
    hooks:
      - id: proselint
        types: [plain-text]
        exclude: LICENSE

  - repo: https://github.com/ambv/black
    rev: 20.8b1
    hooks:
      - id: black
        args:
          - |
              --line-length=79

  - repo: https://github.com/Lucas-C/pre-commit-hooks-markup
    rev: v1.0.1
    hooks:
      - id: rst-linter
        exclude: spam\.rst

  - repo: https://github.com/myint/rstcheck.git
    rev: master
    hooks:
      - id: rstcheck

  - repo: https://github.com/PyCQA/prospector
    rev: 1.3.1
    hooks:
      - id: prospector
        args:
          - |-
            --max-line-length=79
          - |-
            --with-tool=pyroma
          - |-
            --with-tool=bandit
          - |-
            --without-tool=pep257
          - |-
            --doc-warnings
          - |-
            --test-warnings
          - |-
            --full-pep8
          - |-
            --strictness=high
          - |-
            --no-autodetect
        additional_dependencies:
          - bandit
          - pyroma

  - repo: https://gitlab.com/pycqa/flake8.git
    rev: 3.8.4
    hooks:
      - id: flake8
        args:
          - |-
            --doctests
        additional_dependencies:
          - flake8-bugbear

  - repo: https://github.com/executablebooks/mdformat.git
    rev: 0.5.3
    hooks:
      - id: mdformat
+5 −5
Original line number Diff line number Diff line
@@ -40,11 +40,11 @@ pipenv run clean

This software and content are licensed under the
[Creative Commons - Attribution-NonCommercial-NoDerivatives 4.0 International license](https://creativecommons.org/licenses/by/4.0/)
(see `LICENSE.txt).
(see `LICENSE.txt`).

## Author Information

Nimrod Adar, [contact me](mailto:nimrod@shore.co.il) or visit my [website](
https://www.shore.co.il/). Patches are welcome via [`git send-email`](
http://git-scm.com/book/en/v2/Git-Commands-Email). The repository is located
at: <https://git.shore.co.il/explore>.
Nimrod Adar, [contact me](mailto:nimrod@shore.co.il) or visit my
[website](https://www.shore.co.il/). Patches are welcome via
[`git send-email`](http://git-scm.com/book/en/v2/Git-Commands-Email). The repository
is located at: <https://git.shore.co.il/expore/>.
+2 −2
Original line number Diff line number Diff line
bundle_certs
bundle certs
############

:date: 2016-03-02
Loading