Skip to content
README.rst 937 B
Newer Older
nimrod's avatar
nimrod committed
Ansible pre-commit hook
#######################

Ansible `pre-commit <http://pre-commit.com/>`_ hook. The hook runs
:code:`ansible --syntax-check` against playbooks declared.
nimrod's avatar
nimrod committed

nimrod's avatar
nimrod committed
Dependencies
------------

- Ansible.
- Pre-commit.

Installation
------------
nimrod's avatar
nimrod committed

Add the following to your :code:`.pre-commit-config.yaml`:

nimrod's avatar
nimrod committed
.. code:: yaml
nimrod's avatar
nimrod committed

    - repo: https://www.shore.co.il/git/ansible-pre-commit/
nimrod's avatar
nimrod committed
      hooks:
      - id: ansible-pre-commit
        files: playbook.yml
nimrod's avatar
nimrod committed
And run :code:`pre-commit autoupdate` to update the hooks.

nimrod's avatar
nimrod committed
This software is licensed under the MIT license (see the :code:`LICENSE.txt`
file).

Author Information
------------------

Nimrod Adar, `contact me <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://www.shore.co.il/git/.