Closed OndrosI closed 1 year ago
Hello, i have this json
{ "repositories": [ { "name": "some-name", "type": "vcs", "url": "git@xxx.git" } ] }
and i am trying to create this
{ "repositories": [ { "name": "some-name", "type": "vcs", "url": "git@xxx.git" }, { "name": "new-value", "type": "vcs", "url": "git@new-value.git" } ] }
but i dont know how. Is there possibility add multiple values into object?
like this:
- name: append key/values json_patch: src: /file.json operations: - op: add path: '/repositories/-' value: name: "new-value" type: "vcs" url: "git@new-value.git" pretty: yes create: yes
You can have multiple operations, unfortunately the object properties would have to be in separate operations.
Hello, i have this json
and i am trying to create this
but i dont know how. Is there possibility add multiple values into object?
like this: