Commit a2bafee
committed
Don't include number of CPUs in generated docs
Firstly, it causes the "check for uncommitted diffs" CI step to
mysteriously fail in GitHub due to mismatch in the generated docs.
Here's an example of the diff in docs/modules/ROOT/pages/ec_opa_test.adoc:
--p, --parallel:: the number of tests that can run in parallel, defaulting to the number of CPUs (explicitly set with 0). Benchmarks are always run sequentially. (Default: 16)
+-p, --parallel:: the number of tests that can run in parallel, defaulting to the number of CPUs (explicitly set with 0). Benchmarks are always run sequentially. (Default: 4)
Secondly, having the number of CPUs hard-coded in static docs does
not make much sense.
Notes:
- Originally I implemented this workaround in the template internal/documentation/asciidoc/cli/cli.tmp
which worked fine, but made the template quite messy.
- See relevant opa code here:
https://github.com/open-policy-agent/opa/blob/d0c0ae9730b1ecb06a29c341c707c265138f0494/cmd/test.go#L569C69-L569C76
- This is was tough one to debug!
Ref: https://issues.redhat.com/browse/EC-11301 parent 0c34e60 commit a2bafee
2 files changed
Lines changed: 14 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
94 | | - | |
| 94 | + | |
95 | 95 | | |
96 | 96 | | |
97 | 97 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
133 | 133 | | |
134 | 134 | | |
135 | 135 | | |
136 | | - | |
| 136 | + | |
137 | 137 | | |
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
141 | 141 | | |
142 | 142 | | |
143 | | - | |
| 143 | + | |
144 | 144 | | |
145 | 145 | | |
146 | 146 | | |
| |||
149 | 149 | | |
150 | 150 | | |
151 | 151 | | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
0 commit comments