Skip to content

Commit 1dd8024

Browse files
committed
docs(cli): use ndjson code fence for TTY-refusal example (torrust#1798)
Use `ndjson` as the code fence language instead of `json` to prevent the IDE's automatic JSON formatter from reformatting the single-line example into a multi-line block on save.
1 parent fa9eb8a commit 1dd8024

1 file changed

Lines changed: 5 additions & 8 deletions

File tree

docs/adrs/20260519000000_define_global_cli_output_contract.md

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -78,14 +78,11 @@ Rationale: when stdout is a TTY, result JSON would be mixed with the shell promp
7878
pipelines silently. Refusing makes the contract mechanically enforceable and the error
7979
immediately visible. Users can suppress the check with `| cat` or `| jq`.
8080

81-
Example stderr record on TTY refusal (pretty-printed for readability; the actual wire format is
82-
a single JSON line per the NDJSON contract):
83-
84-
```json
85-
{
86-
"kind": "tty_refusal",
87-
"message": "stdout is a TTY; pipe the output to consume result data"
88-
}
81+
Example stderr record on TTY refusal (one JSON object on a single line, as required by the
82+
NDJSON contract):
83+
84+
```ndjson
85+
{"kind":"tty_refusal","message":"stdout is a TTY; pipe the output to consume result data"}
8986
```
9087

9188
### 5. User-facing verbosity

0 commit comments

Comments
 (0)