Skip to content

Commit 2403a84

Browse files
committed
Fix manifest parsing
Since helm 2.5.0 the '# Source:' stanze appears multiple times per template (for each yaml doc)
1 parent 4c0d315 commit 2403a84

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

manifest/parse.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,12 @@ func Parse(manifest string) map[string]string {
4343

4444
for scanner.Scan() {
4545
source, content := splitSpec(scanner.Text())
46-
result[source] = content
46+
//Since helm 2.5.0 the '# Source:' stanze appears multiple times per template (for each yaml doc)
47+
if _, ok := result[source]; ok {
48+
result[source] = result[source] + "\n" + content
49+
} else {
50+
result[source] = content
51+
}
4752
}
4853
return result
4954

0 commit comments

Comments
 (0)