Git hook management
Closed this issue · 0 comments
azukaar commented
Add git hooks for precommit / prepush.
You can either use them thought gupm.json
{
"git": {
"hooks": {
"prepush": "g test $ChangedOrAddedFiles"
}
}
}
or with a script git.hooks.prepush.gs
or git/hooks/prepush.gs
.
-
hook should be checked and registered on each command (ex: g make check if hooks are registered)
-
alias should received $AllChanges, $ChangedOrAddedFiles, $ChangedFilesOnly, $AddedFiles, and $Deletedfiles as comma separated list
-
Script should receive GitChanges
{
"filename": "A / D / M" (Added, Deleted or Modified)
}