Skip to content

Commit

Permalink
Add documentation for pre-commit
Browse files Browse the repository at this point in the history
  • Loading branch information
SauravMaheshkar committed Dec 14, 2021
1 parent 51534d3 commit a2424d9
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions docs/source/development_guide/coding.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,27 @@
Coding Conventions
==================

Pre-Commit
-----------

.. _`Pre-Commit`: https://pre-commit.com/

We use `pre-commit`_ to ensure that we're always keeping up with the best
practices when it comes to linting, standard code conventions and type
annotations. Although it may seem time consuming at first as to why is one
supposed to run all these tests and checks but it helps in identifying simple
issues before submission to code review. We've already specified a configuration
file with a list of hooks that will get executed before every commit.

First you'll need to setup the git hook scripts by installing them.

.. code-block:: bash
pre-commit install
That's it !! now pre-commit will run everytime on the changed files every time
you commit any changes.

Code Formatting
---------------

Expand Down

0 comments on commit a2424d9

Please sign in to comment.