File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -1118,7 +1118,12 @@ func (r *gitRepository) loadTasks(ctx context.Context, startCommit *object.Commi
11181118
11191119 var tasks []v1alpha1.Task
11201120
1121+ done := false
11211122 visitCommit := func (commit * object.Commit ) error {
1123+ if done {
1124+ return nil
1125+ }
1126+
11221127 gitAnnotations , err := ExtractGitAnnotations (commit )
11231128 if err != nil {
11241129 return err
@@ -1143,6 +1148,7 @@ func (r *gitRepository) loadTasks(ctx context.Context, startCommit *object.Commi
11431148 if gitAnnotation .Task != nil && (gitAnnotation .Task .Type == v1alpha1 .TaskTypeClone || gitAnnotation .Task .Type == v1alpha1 .TaskTypeInit ) {
11441149 // we have reached the beginning of this package revision and don't need to
11451150 // continue further
1151+ done = true
11461152 break
11471153 }
11481154 }
You can’t perform that action at this time.
0 commit comments