dotansimha / dotansimha/graphql-code-generator
Codegen CLI in watch mode doesn't respect "silent" configuration
- Dominant language
- TypeScript
- Stars
- 11.3k
- Forks
- 1.4k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 23
Description
### Which packages are impacted by your issue?
@graphql-codegen/cli
### Describe the bug
When running `@graphql-codegen/cli` with a configuration that specifies `silent: true` _and_ `watch: true`, the resulting watch process continuously emits logs to stdout such as:
```
Watching for changes in ~/path/to/some/file.graphql...
```
### Your Example Website or App
https://github.com/dotansimha/graphql-code-generator
### Steps to Reproduce the Bug or Issue
1. Follow the [Quick Start](https://github.com/dotansimha/graphql-code-generator) instructions with a repo containing a GraphQL file
2. Run `graphql-codegen --silent --watch`
3. Observe the logs emitted to stdout
### Expected behavior
As a user of `graphql-codegen` CLI, I expect to be able to suppress logs in some contexts by configuring the CLI to be silent.
### Screenshots or Videos
_No response_
### Platform
- OS: macOS
- NodeJS: 20.15.0
- `graphql` version: 16
- `@graphql-codegen/*` version(s): 4.0.1
### Codegen Config File
_No response_
### Additional context
_No response_
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.