Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quiet startup mode #248

Closed
mhsdef opened this issue Apr 25, 2024 · 2 comments · Fixed by #271
Closed

Quiet startup mode #248

mhsdef opened this issue Apr 25, 2024 · 2 comments · Fixed by #271
Assignees
Labels
Enhancement New feature or request wp-now

Comments

@mhsdef
Copy link

mhsdef commented Apr 25, 2024

It looks like wp-now always opens a browser unless in a Github codespace (openInDefaultBrowser).

Could we get a CLI flag to background wp-now after startup and skip opening the browser?

Eg, something like:

wp-now --quiet

Use case:
Scripted spin up of both wp-now as a backend and a separate verbose frontend such as vite dev server.

@adamziel adamziel added Enhancement New feature or request wp-now labels Apr 25, 2024
@eliot-akira
Copy link
Contributor

eliot-akira commented Apr 28, 2024

On a related note: I was looking for a way to silence any console output from wp-now. Currently, as far as I can tell, the only way to achieve it is by setting the environment variable NODE_ENV to test (checked on startup here). There is a function called disableOutput() but it's not exposed as a CLI option.

The new proposed option --quiet sounds like it's about logging level, as opposed to --verbose. Maybe it could be named something like --no-open, to clarify that it prevents automatically opening the browser on start.

@sejas
Copy link
Collaborator

sejas commented May 22, 2024

@mhsdef , @eliot-akira , now you can run npx @wp-now/wp-now@latest start --skip-browser

Thanks for suggesting this feature! 🙌

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement New feature or request wp-now
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants