Skip to content

Add pre-commit hook to check for API keys #54

@madelinehjenkins

Description

@madelinehjenkins

Rather than manually ensuring that API keys have not been committed, we could do this programmatically via pre-commit hooks. However, due to the diversity in API key format, there does not appear to be an off-the-shelf solution.

Creating new hooks is possible, but in order to make this work with the pre-commit package we would need to make a new git repo for this detect-api-key hook (source). This could be useful to teams beyond ConvAI.

Generally speaking, it's possible to create pre-commit hooks by simply creating a shell script, but in order to integrate with pre-commit it seems like creating a repo that is an installable package or exposes an executable is necessary.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions