Skip to content

Commit 4d4da7c

Browse files
docs: document oasdiff.yaml support in free actions
The free actions (diff, breaking, changelog) are CLI wrappers; the underlying CLI already looks up oasdiff.yaml from cwd, and GitHub Actions sets the runner cwd to $GITHUB_WORKSPACE. So drop oasdiff.yaml at the repo root and the actions pick it up automatically. Adds a "Configuring with oasdiff.yaml" section under Free actions with a runnable example, the precedence rule (action inputs override YAML), and the boolean-only-enable-via-input limitation as a footnote.
1 parent 26ccb33 commit 4d4da7c

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,25 @@ This compares your spec on the PR branch against the base branch and fails the w
3434
3535
The following actions run the oasdiff CLI directly in your GitHub runner — no account or token required.
3636
37+
### Configuring with `oasdiff.yaml`
38+
39+
All free actions inherit the CLI's config-file support. Drop an `oasdiff.yaml` at your repo root and the actions pick it up automatically — no extra wiring needed:
40+
41+
```yaml
42+
# oasdiff.yaml at your repo root
43+
exclude-elements:
44+
- endpoints
45+
flatten-allof: true
46+
deprecation-days-stable: 180
47+
fail-on: ERR
48+
```
49+
50+
Any flag the oasdiff CLI supports works in the config file — see [CONFIG-FILES.md](https://github.com/oasdiff/oasdiff/blob/main/docs/CONFIG-FILES.md) for the full reference and supported file formats (`oasdiff.{json,yaml,yml,toml,hcl}`).
51+
52+
Action `inputs:` take precedence over config-file values, so you can use the file for shared defaults across workflows and override per-workflow via inputs.
53+
54+
> **Limitation**: boolean flags can only be enabled through an action input. If your `oasdiff.yaml` sets `composed: true` and you want to disable it for a specific workflow run, edit the YAML — passing `composed: 'false'` in the action input has no effect.
55+
3756
### Check for breaking changes
3857

3958
Detects breaking changes and writes inline GitHub annotations to the Actions summary. Fails the workflow when changes at or above the `fail-on` severity are found.

0 commit comments

Comments
 (0)