Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore: Create pre-commit-hook #35

Merged
merged 4 commits into from
Jun 8, 2022

Conversation

Shivani-chourasiya
Copy link
Contributor

@Shivani-chourasiya Shivani-chourasiya commented Jun 2, 2022

Fixed #28

Changes proposed

Added .pre-commit-hooks.yaml file with the required keys to configure pre-commit-hook.

How to test?

Add the j2lint pre-commit hook inside your repository in .pre-commit-config.yaml.
Example-

 - repo: https://github.com/aristanetworks/j2lint.git
   rev: <tag/branch/sha>
   hooks:
   - id: j2lint

Run command: pre-commit run --all-files

Reference

https://pre-commit.com/

Copy link
Collaborator

@gmuloc gmuloc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested it on my local AVD repo by adding

  - repo: https://github.com/aristanetworks/j2lint.git
    rev: pull/35/head
    hooks:
      - id: j2lint

in my .pre-commit-config.yaml and it worked like a charm!

Thanks

.pre-commit-hooks.yaml Outdated Show resolved Hide resolved
Shivani-chourasiya and others added 2 commits June 2, 2022 19:00
Co-authored-by: Guillaume Mulocher <gmulocher@arista.com>
@Shivani-chourasiya Shivani-chourasiya marked this pull request as ready for review June 3, 2022 06:36
Copy link
Collaborator

@gmuloc gmuloc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@gmuloc gmuloc changed the title Create pre-commit-hook Chore: Create pre-commit-hook Jun 8, 2022
@gmuloc gmuloc merged commit 619b7c8 into aristanetworks:devel Jun 8, 2022
@Shivani-chourasiya Shivani-chourasiya removed their assignment Sep 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Create a pre-commit hook
4 participants