Skip to content

Checks the commit using the pre-commit git hook for the existence of certain words and stops the commit if they are found

License

Notifications You must be signed in to change notification settings

utip/Git-Pre-Commit-Hook-for-certain-words

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

GIT - Pre-Commit check for certain words

Table of Contents

  1. Description
  2. Setup
  3. Usage
  4. Development
  5. Contributors

Description

GIT pre-commit hook for checking the existence of certain words/phrases/functions in the code to be committed.

Setup

To install hook, copy pre-commit file to your project .git/hooks/pre-commit:

$ cp pre-commit .git/hooks/pre-commit;
$ chmod +x .git/hooks/pre-commit;

Usage

The hook comes with the die, print_r and dump functions as the strings to be checked prior to the commit. You can add more strings to be checked if you wish by modifying the checks array

Development

uTip's repositories are open projects, and community contributions are essential for keeping them great.

Fork this repo on GitHub

Contributors

The list of contributors can be found at: https://github.com/utipteam/Git-Pre-Commit-Hook-for-certain-words/graphs/contributors

About

Checks the commit using the pre-commit git hook for the existence of certain words and stops the commit if they are found

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%