don't enable pre-commit hooks on collibra repos

This commit is contained in:
MorganGeek 2020-07-06 16:43:26 +02:00
parent 372c047d1e
commit 7d707dad27

View File

@ -268,7 +268,7 @@ function vimat {
} }
function copyhooks { function copyhooks {
cp -f ~/.git-template/.pre-commit-config.yaml ./ cp -f ~/.git-template/.pre-commit-config.yaml ./
pre-commit install --install-hooks --overwrite pre-commit install --install-hooks --overwrite --allow-missing-config
pre-commit run -a pre-commit run -a
} }
function httperr { function httperr {
@ -330,7 +330,9 @@ function vaultgetsecret {
function setorigin { function setorigin {
gra origin "$1" 2>/dev/null gra origin "$1" 2>/dev/null
grset origin "$1" grset origin "$1"
copyhooks if [[ $string =~ "collibra" ]]; then
copyhooks
fi
} }
function gitpushallremote { function gitpushallremote {
grv grv
@ -346,7 +348,9 @@ function clone {
if gcls "$1"; then if gcls "$1"; then
if [[ -n "$folder" ]]; then if [[ -n "$folder" ]]; then
cd "$folder" || exit cd "$folder" || exit
copyhooks if [[ $string =~ "collibra" ]]; then
copyhooks
fi
else else
error "unable to change current directory to : $folder" error "unable to change current directory to : $folder"
fi fi