Skip to content

Commit

Permalink
add stable sort to helm dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
michaeljguarino committed Oct 28, 2023
1 parent 16230fc commit 5d83757
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/scaffold/helm.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (
"fmt"
"os"
"path/filepath"
"sort"
"strings"
ttpl "text/template"

Expand Down Expand Up @@ -61,6 +62,9 @@ func (s *Scaffold) chartDependencies(w *wkspace.Workspace) []dependency {
fmt.Sprintf("%s.enabled", chartInstallation.Chart.Name),
}
}
sort.SliceStable(dependencies, func(i, j int) bool {
return dependencies[i].Name < dependencies[j].Name
})
return dependencies
}

Expand Down

0 comments on commit 5d83757

Please sign in to comment.