Skip validation when pushing new branches (#16064)
The Puppet code validation Git hook was exiting with an error when
receiving new branches because in those cases $oldrev equals 0{40}.
I experimented with a solution grepping the output of:
git ls-tree --full-tree -r --name-only HEAD
But I thought the output was too extensive so for now I just skip
validation when pushing a new branch. We will always eventually hit the
pre-receive hook when pushing to master, anyway.
Loading
Please sign in to comment