blob: 3a0be7d1b71d1c7bdf6d29da72f3a64b807b7deb [file] [log] [blame]
cue import -o - -f --list -l '"\(strings.ToLower(kind))": "\(name)":' --recursive ./import
cmp stdout expect-stdout
cue import -o - -f --list -l 'strings.ToLower(kind)' -l name --recursive ./import
cmp stdout expect-stdout
-- expect-stdout --
import json656e63 "encoding/json"
service: {
booster: [{
kind: "Service"
name: "booster"
}]
"supplement\nfoo": [{
kind: "Service"
name: """
supplement
foo
"""
json: json656e63.Marshal(_cue_json)
let _cue_json = [1, 2]
}]
}
deployment: booster: [{
kind: "Deployment"
name: "booster"
replicas: 1
}]
-- import/services.cue --
service: [{
kind: "Service"
name: "booster"
}, {
kind: "Service"
name: """
supplement
foo
"""
json: "[1, 2]"
}]
deployment: [{
kind: "Deployment"
name: "booster"
replicas: 1
}]
-- import/services.jsonl --
{
"kind": "Service",
"name": "booster"
}
{
"kind": "Deployment",
"name": "booster",
"replicas": 1
}
{
"kind": "Service",
"name": "supplement\nfoo",
"json": "[1, 2]"
}
-- cue.mod --