gabyx / Githooks

🦎 Githooks: per-repo and shared Git hooks with version control and auto update. [✩Star] if you're using it!
MIT License
102 stars 4 forks source link

feat: Add runtime logging with env. variable `GITHOOKS_LOG_LEVEL` :anchor: #148

Closed gabyx closed 3 months ago

gabyx commented 3 months ago
coveralls commented 3 months ago

Coverage Status

coverage: 80.192% (-0.08%) from 80.276% when pulling 8ba28e0a329548154d6dd62c4954bf51a089f7a8 on feature/runtime-logging into 570edd73bf69bdd9dbb173f3399a61461c4b318c on main.

gabyx commented 3 months ago

@mruz : this is your feature. A value GITHOOKS_LOG_LEVEL=disable somewhere will disable the log during runner execution and anybody can then set it to GITHOOKS_LOG_LEVEL= or GITHOOKS_LOG_LEVEL=info to enable more logs.

The default behavior is info. I did not put that into a Git config variable because the Git config is parsed after the log is created and it makes things a bit more complicated.

gabyx commented 3 months ago

@mruz : can yo review this PR thanks.