Skip to content

juanfe/bubble-hook

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

bubble-hook

Codesniffer to prevent undesired debug bubble in code of Ruby, Python or JS.

Author: Juan Fernando Jaramillo Botero juanf.jaramillo@opdevel.com Website: http://github.com/juanfe/bubble-hooks

REQUIREMENTS

  • Bash

FEATURES

  • Check occurrence of 'binding.py' in files withe extension ".rb" or ".erb".
  • Check occurrence of 'console.log' in files withe extension ".js" or ".coffee".
  • Check occurrence of 'import pdb' or 'import ipdb' in files withe extension "*.py".

USAGE

  • Put the script "pre-commit" into your .git/hooks directory
  • OR: add the script to your pre-commit "chain" (you probably know what to do then)
  • Ensure that the script is executable.
  • You can turn off the sniffer from command line by:

    git config hooks.allowbubble true

  • You can turn on the sniffer again from command line by:

    git config hooks.allowbubble false

REFERENCE:

[1] http://codeinthehole.com/writing/tips-for-using-a-git-pre-commit-hook/ [2] https://github.com/s0enke/git-hooks [3] .git/hooks/pre-commit.sample

About

Code sniffer to prevent debug lines in ruby, python, and js.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published