Is it possible to exit early without cancelling --watch #10983
Unanswered
is-jonreeves
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I noticed that when I intentionally exit a script using
process.exit()
it cancels out of bun's watch mode. If I provide a string (eg...process.exit('')
) to imply an error then it keeps watching (same as usingthrow new Error('')
).This isn't affecting me in real-world code. While I'm drafting/testing ideas in a file I was just attempting to use
process.exit()
as a marker to avoid commenting out work below the fold.I can see that this might be a purposeful behavior so was wondering if there is a more appropriate way to exit a script (perhaps I'm just missing a special exit code)?
Beta Was this translation helpful? Give feedback.
All reactions