mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-12 01:14:22 +00:00
fix kyaml issue where dropping Style created issues
dropping the node style creates a compatibility issue where quotes around "on" are dropped because yaml.v3 interprets it as a string. other yaml parsers interpret on as a bool value, and parse it as a bool rather than string. fix: retain the original style so it is kept as quoted. - fmt: don't drop the styles - merge2: keep the style when merging elements - setting a field: if changing the value of a scalar field, retain its style by default
This commit is contained in:
@@ -23,8 +23,7 @@ kind: Deployment
|
||||
items:
|
||||
- name: foo
|
||||
image: foo:v1
|
||||
command:
|
||||
- run.sh
|
||||
command: ['run.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -47,8 +46,7 @@ kind: Deployment
|
||||
items:
|
||||
- name: foo
|
||||
image: foo:v1
|
||||
command:
|
||||
- run.sh
|
||||
command: ['run.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -62,15 +60,14 @@ items:
|
||||
`,
|
||||
`
|
||||
kind: Deployment
|
||||
items: {}
|
||||
items: []
|
||||
`,
|
||||
`
|
||||
kind: Deployment
|
||||
items:
|
||||
- name: foo
|
||||
image: foo:v1
|
||||
command:
|
||||
- run.sh
|
||||
command: ['run.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -90,8 +87,7 @@ kind: Deployment
|
||||
items:
|
||||
- name: foo
|
||||
image: foo:v1
|
||||
command:
|
||||
- run.sh
|
||||
command: ['run.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -118,8 +114,7 @@ items:
|
||||
image: foo:v1
|
||||
- name: bar
|
||||
image: bar:v1
|
||||
command:
|
||||
- run2.sh
|
||||
command: ['run2.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -146,8 +141,7 @@ items:
|
||||
image: foo:v1
|
||||
- name: bar
|
||||
image: bar:v1
|
||||
command:
|
||||
- run2.sh
|
||||
command: ['run2.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -174,8 +168,7 @@ items:
|
||||
image: foo:v1
|
||||
- name: bar
|
||||
image: bar:v1
|
||||
command:
|
||||
- run2.sh
|
||||
command: ['run2.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -205,8 +198,7 @@ items:
|
||||
image: foo:v1
|
||||
- name: bar
|
||||
image: bar:v1
|
||||
command:
|
||||
- run2.sh
|
||||
command: ['run2.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -225,8 +217,7 @@ items:
|
||||
image: foo:v1
|
||||
- name: bar
|
||||
image: bar:v1
|
||||
command:
|
||||
- run2.sh
|
||||
command: ['run2.sh']
|
||||
`,
|
||||
`
|
||||
kind: Deployment
|
||||
@@ -235,8 +226,7 @@ items:
|
||||
image: foo:v1
|
||||
- name: bar
|
||||
image: bar:v1
|
||||
command:
|
||||
- run2.sh
|
||||
command: ['run2.sh']
|
||||
`,
|
||||
},
|
||||
|
||||
@@ -255,8 +245,7 @@ items:
|
||||
image: foo:v1
|
||||
- name: bar
|
||||
image: bar:v1
|
||||
command:
|
||||
- run2.sh
|
||||
command: ['run2.sh']
|
||||
`,
|
||||
`
|
||||
kind: Deployment
|
||||
|
||||
Reference in New Issue
Block a user