Skip to content

eviljosh/blacklist-pre-commit-hook

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

blacklist-pre-commit-hook

A pre-commit hook for blacklisting certain functions.

The blacklist hook will check for function calls to functions that are big no-nos, like eval, and will issue a warning if it finds any. By default, it will only check for eval, but you can customize the blacklisted name list by passing the --blacklisted-names argument on the command line.

Installation

To install, just add the hook to your .pre-commit-config.yaml:

repos:
-   repo: https://github.com/skorokithakis/blacklist-pre-commit-hook
    rev: master
    hooks:
    - id: blacklist
      args: ["--blacklisted-names=eval,print,int"]

That should be all!

About

A pre-commit hook for blacklisting certain functions

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 100.0%