cli
cli copied to clipboard
feat: suppress spinner in watch command with --silent flag
Summary
Fixes #5301
This issue was opened a long time ago, so I don't really know if my fix still applies. However, I decided to work on this and send this PR.
This PR suppresses the animated spinner in netlify watch when the --silent flag is used, preventing continuous terminal activity notifications in some terminal multiplexers like tmux, screen, etc.
However, I have some questions about this feature:
- Should
console.time('Deploy time')/console.timeEnd('Deploy time')also respect the--silentflag? - There's an issue comment that mentions: "We do have a --silent flag (and --json might work here too)". Buuut the
watchcommand currently doesn't have a--jsonoption implemented. Should I add it as part of this PR?
LMK if you need anything else. I'm open to feedback if the approach or requirements have changed. ๐
For us to review and ship your PR efficiently, please perform the following steps:
- [x] Open a bug/issue before writing your code ๐งโ๐ป. This ensures we can discuss the changes and get feedback from everyone that should be involved. If you`re fixing a typo or something that`s on fire ๐ฅ (e.g. incident related), you can skip this step.
- [x] Read the contribution guidelines ๐. This ensures your code follows our style guide and passes our tests.
- [ ] Update or add tests (if any source code was changed or added) ๐งช
- [ ] Update or add documentation (if features were changed or added) ๐
- [ ] Make sure the status checks below are successful โ