Skip to content

Commit

Permalink
[AIRFLOW-XXX] Update list of pre-commits (apache#6603)
Browse files Browse the repository at this point in the history
  • Loading branch information
potiuk authored Nov 18, 2019
1 parent 0acb034 commit 657dd28
Showing 1 changed file with 38 additions and 29 deletions.
67 changes: 38 additions & 29 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,6 @@ these guidelines:
- Adhere to guidelines for commit messages described in this `article <http://chris.beams.io/posts/git-commit/>`__.
This makes the lives of those who come after you a lot easier.



Development Environments
========================

Expand Down Expand Up @@ -410,47 +408,58 @@ inform you that you should rebuild the image.
Supported Pre-commit Hooks
--------------------------

In Airflow, we have the following checks:

=================================== =======================================================
**Hooks** **Description**
=================================== =======================================================
``check-apache-license`` Checks compatibility with Apache License requirements.
----------------------------------- -------------------------------------------------------
In Airflow, we have the following checks (The checks with stare in Breeze require `BREEZE.rst <BREEZE.rst>`__
image built locally):

=================================== ================================================================ ============
**Hooks** **Description** **Breeze**
=================================== ================================================================ ============
``airflow-settings`` Check if airflow import settings are used well.
----------------------------------- ---------------------------------------------------------------- ------------
``build`` Builds image for check-apache-licence, mypy, pylint, flake8. *
----------------------------------- ---------------------------------------------------------------- ------------
``check-apache-license`` Checks compatibility with Apache License requirements. *
----------------------------------- ---------------------------------------------------------------- ------------
``check-executables-have-shebangs`` Checks that executables have shebang.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``check-hooks-apply`` Checks which hooks are applicable to the repository.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``check-merge-conflict`` Checks if a merge conflict is committed.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``check-xml`` Checks XML files with xmllint.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``detect-private-key`` Detects if private key is added to the repository.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``doctoc`` Refreshes the table of contents for md files.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``end-of-file-fixer`` Makes sure that there is an empty line at the end.
----------------------------------- -------------------------------------------------------
``flake8`` Runs flake8.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``flake8`` Runs flake8. *
----------------------------------- ---------------------------------------------------------------- ------------
``forbid-tabs`` Fails if tabs are used in the project.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``insert-license`` Adds licenses for most file types.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``isort`` Sorts imports in python files.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``lint-dockerfile`` Lints a dockerfile.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``mixed-line-ending`` Detects if mixed line ending is used (\r vs. \r\n).
----------------------------------- -------------------------------------------------------
``mypy`` Runs mypy.
----------------------------------- -------------------------------------------------------
``pylint`` Runs pylint.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``mypy`` Runs mypy. *
----------------------------------- ---------------------------------------------------------------- ------------
``pylint`` Runs pylint. *
----------------------------------- ---------------------------------------------------------------- ------------
``python-no-log-warn`` Checks if there are no deprecate log warn.
----------------------------------- ---------------------------------------------------------------- ------------
``rst-backticks`` Checks if RST files use double backticks for code.
----------------------------------- ---------------------------------------------------------------- ------------
``shellcheck`` Checks shell files with shellcheck.
----------------------------------- -------------------------------------------------------
----------------------------------- ---------------------------------------------------------------- ------------
``update-breeze-file`` Update output of breeze command in BREEZE.rst.
----------------------------------- ---------------------------------------------------------------- ------------
``yamllint`` Checks yaml files with yamllint.
=================================== =======================================================
=================================== ================================================================ ============


Using Pre-commit Hooks
Expand Down

0 comments on commit 657dd28

Please sign in to comment.