From a6612b0bdeea73c6290dd5f79b33dd646d8a5da1 Mon Sep 17 00:00:00 2001 From: Alan Knowles Date: Wed, 7 Nov 2018 09:54:15 +0800 Subject: [PATCH] Attribute changed MTrack/SCM/Git/CommitHookBridge.php --- MTrack/SCM/Git/CommitHookBridge.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/MTrack/SCM/Git/CommitHookBridge.php b/MTrack/SCM/Git/CommitHookBridge.php index ecdb9c2b..b16178c2 100644 --- a/MTrack/SCM/Git/CommitHookBridge.php +++ b/MTrack/SCM/Git/CommitHookBridge.php @@ -28,6 +28,10 @@ class MTrack_SCM_Git_CommitHookBridge extends IMTrackCommitHookBridge list($old, $new, $ref) = explode(' ', trim($line), 3); $this->commits[] = $new; + if (preg_match('/^0+$/',$old)) { + continue; // it's a new branch - ignore.. + } + $fp = $this->repo->git( 'log', '--no-color', '--name-status', '--date=rfc', "$old..$new"); //$ref, used to be in here?? - but it breaks stuff... -- 2.39.2