Skip to content

Commit

Permalink
Discover: Use Konflux config from latest release branch (#266)
Browse files Browse the repository at this point in the history
* Discover: Use Konflux config from latest release branch

* Enable Konflux by default
  • Loading branch information
creydr authored Sep 12, 2024
1 parent f4f38d7 commit 8fda86e
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pkg/discover/discover.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,13 @@ func discover(ctx context.Context, path string) error {
if latestConfigured == availableBranches[i] {
for ; i < len(availableBranches); i++ {
if _, ok := inConfig.Config.Branches[availableBranches[i]]; !ok {
inConfig.Config.Branches[availableBranches[i]] = inConfig.Config.Branches[latest]
branchConfig := inConfig.Config.Branches[latest]
// enable Konflux for all new branches
branchConfig.Konflux = &prowgen.Konflux{
Enabled: true,
}

inConfig.Config.Branches[availableBranches[i]] = branchConfig
}
}
}
Expand Down

0 comments on commit 8fda86e

Please sign in to comment.