Skip to content

Commit d8991cc

Browse files
authored
Merge pull request #3812 from hey-api/copilot/fix-biome-lint-apply-flag
2 parents e44e334 + 084de63 commit d8991cc

3 files changed

Lines changed: 21 additions & 1 deletion

File tree

.changeset/popular-years-tickle.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@hey-api/openapi-ts": patch
3+
---
4+
5+
**config**: fix: remove `--apply` flag from Biome post-processor commands

docs/openapi-ts/configuration/output.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,16 @@ You can use built-in presets for common tools:
259259

260260
::: code-group
261261

262+
```js [biome:check]
263+
export default {
264+
input: 'hey-api/backend', // sign up at app.heyapi.dev
265+
output: {
266+
path: 'src/client',
267+
postProcess: ['biome:check'], // [!code ++]
268+
},
269+
};
270+
```
271+
262272
```js [biome:format]
263273
export default {
264274
input: 'hey-api/backend', // sign up at app.heyapi.dev

packages/openapi-ts/src/config/output/postprocess.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,18 @@ export type Formatters = 'biome' | 'prettier';
1111
export type Linters = 'biome' | 'eslint' | 'oxlint';
1212

1313
export const postProcessors = {
14+
'biome:check': {
15+
args: ['check', '--write', '{{path}}'],
16+
command: 'biome',
17+
name: 'Biome (Check)',
18+
},
1419
'biome:format': {
1520
args: ['format', '--write', '{{path}}'],
1621
command: 'biome',
1722
name: 'Biome (Format)',
1823
},
1924
'biome:lint': {
20-
args: ['lint', '--apply', '{{path}}'],
25+
args: ['lint', '--write', '{{path}}'],
2126
command: 'biome',
2227
name: 'Biome (Lint)',
2328
},

0 commit comments

Comments
 (0)