github.com/joomcode/cue@v0.4.4-0.20221111115225-539fe3512047/tools/trim/testdata/kube1.txtar (about) 1 -- in.cue -- 2 service: [ID=string]: { 3 ports: [...{ 4 protocol: *"TCP" | "UDP" 5 extra: 3 6 }] 7 } 8 9 service: a: { 10 ports: [{ 11 name: "a" 12 protocol: "TCP" 13 key: "bar" 14 }] 15 } 16 17 service: a: { 18 ports: [{ 19 protocol: "TCP" 20 key: "bar" 21 }] 22 } 23 24 service: a: { 25 ports: [{ 26 extra: 3 27 }] 28 } 29 -- out/trim -- 30 == in.cue 31 service: [ID=string]: { 32 ports: [...{ 33 protocol: *"TCP" | "UDP" 34 extra: 3 35 }] 36 } 37 38 service: a: { 39 ports: [{ 40 name: "a" 41 key: "bar" 42 }] 43 } 44 45 service: a: { 46 ports: [{ 47 key: "bar" 48 }] 49 } 50 51 service: a: { 52 ports: [{ 53 }] 54 }