Skip to content

Git hooks for contributors #80

@Mandera

Description

@Mandera

Since the .git folder isn't versioned for security reasons to execute arbitrary code we have an issue; pre-commit and pre-push hooks won't be there when forked or cloned.

Options

  • Rely on generate.py to create all hooks for us - already implemented
    • Might get tricky to merge with additional checks - The pre-commit package has this nice config file. Not sure how that works under the hood, might also be easy
  • Rely on pre-commit package and remove git hook definitions from Packager
    • Implement the pre-commit install command somewhere, inside generate_localfiles or make a new method probably coupled to
      def create_blank_locally(self, install=True):
    • Could add the generate_localfiles step in .pre-commit-config.yaml as a pre-commit repo perhaps?

I don't want developers to have to write pre-commit install. Everything should go through generate.py - I like it especially because it's very transparent for devs to look through the python code before running the file

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    No status

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions