Skip to content

Commit

Permalink
fix(cli): fix indentation in file-patch cli command (#972)
Browse files Browse the repository at this point in the history
  • Loading branch information
Tieske authored Jul 18, 2023
1 parent 3de0874 commit 5d19fe6
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 26 deletions.
28 changes: 14 additions & 14 deletions cmd/file_addplugins.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,20 +121,20 @@ The plugin files have the following format (JSON or YAML) and are applied in the
order they are given:
{ "_format_version": "1.0",
"add-plugins": [
{ "selectors": [
"$..services[*]"
],
"overwrite": false,
"plugins": [
{ "name": "my-plugin",
"config": {
"my-property": "value"
}
}
],
}
]
"add-plugins": [
{ "selectors": [
"$..services[*]"
],
"overwrite": false,
"plugins": [
{ "name": "my-plugin",
"config": {
"my-property": "value"
}
}
],
}
]
}
`,
RunE: executeAddPlugins,
Expand Down
24 changes: 12 additions & 12 deletions cmd/file_patch.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ func newPatchCmd() *cobra.Command {
The input file is read, the patches are applied, and if successful, written
to the output file. The patches can be specified by a '--selector' and one or more
'--value' tags, or via patch files.
When using '--selector' and '--values', the items are selected by the 'selector',
which is a JSONpath query. From the array of nodes found, only the objects are updated.
The 'values' are applied on each of the JSONObjects returned by the 'selector'.
Expand All @@ -135,17 +135,17 @@ Patch files have the following format (JSON or YAML) and can contain multiple
patches that are applied in order:
{ "_format_version": "1.0",
"patches": [
{ "selectors": [
"$..services[*]"
],
"values": {
"read_timeout": 10000,
"_comment": "comment injected by patching"
},
"remove": [ "_ignore" ]
}
]
"patches": [
{ "selectors": [
"$..services[*]"
],
"values": {
"read_timeout": 10000,
"_comment": "comment injected by patching"
},
"remove": [ "_ignore" ]
}
]
}
`,
RunE: executePatch,
Expand Down

0 comments on commit 5d19fe6

Please sign in to comment.