Commit 74f6277
cli: in batch mode, print empty line if get fails
Currently get commands return nothing to stdout on error in batch mode.
In practice, this makes them hard to use in scripts. If the caller
sends 4 gets and we only return 3 lines, the caller can not easily
determine which one did not work.
This changes the get command behavior in batch mode to always print
a new line, even on error. This allows the caller to determine which
get did not work. e.x. if the 3rd line is blank then the 3rd get
did not work.
Signed-off-by: Matthew Cather <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>1 parent ccc1719 commit 74f6277
1 file changed
Lines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
476 | 476 | | |
477 | 477 | | |
478 | 478 | | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
479 | 482 | | |
480 | 483 | | |
481 | 484 | | |
| |||
488 | 491 | | |
489 | 492 | | |
490 | 493 | | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
491 | 497 | | |
492 | 498 | | |
493 | 499 | | |
| |||
0 commit comments