-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Allow enabling direct debugging through the CLI. #4531
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
Conversation
|
The code that uses USE_DIRECT_DEBUGGING is app specific. While it is part of the current default template there is no guarantee that the apps code will include that code, or use it in the same way. I worry that adding an option like this would be confusing as there are plenty of cases where it wouldn't work. I also worry some about what it does to build caching. How will we know we need to rebuild the binaries. This isn't an option that is provided to the CLI for android or iOS either. |
packages/microsoft-reactnative-sampleapps/windows/SampleAppCPP/App.cpp
Outdated
Show resolved
Hide resolved
asklar
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls move into the instance settings instead if this is something that can be always enabled in debug builds
|
Thank you for your feedback @acoates-ms!
That is correct. Is there a way to set
As you mention, my understanding is that you would need to rebuild if you want to toggle the defaults. I was think of maybe using environment variables to switch this without needing to rebuild. What do you think? Are there any more fitting approaches?
Thanks for clarifying. Are you familiar with how would one go about using direct debugging in android or iOS? |
|
The story for direct debugging in Android / iOS is still being worked out. (Its not easy right now). But for now its similar to enabling various other dev features and involves a code change |
|
Hello @nasadigital! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
* Allow enabling of direct debugging through the CLI. * Use more accurate declartions. * Enable direct debugging through command line arguments instead of defines. * Addres PR feedback. * Use same delimiter as when running through the react native CLI. * Change delimiter back to whitespace. * Address PR feedback.
Addresses #4316.
Adds a parameter
--direct-debuggingto the CLI which enables direct debugging by default.When the parameter is parsed it supplies the property
UseDirectDebugging=trueto msbuild.The property defines the
USE_DIRECT_DEBUGGINGmacro for C++ or constant for C#.Microsoft Reviewers: Open in CodeFlow