chore: add and ignore ip.txt in ios#705
Conversation
|
@machour After reading related codes of RN, I think this file is generated automatically. RN will try to detect the ip and save into |
|
@chinesedfan yup, but this was never generated for me :/ writing it manually fix this hassle for me |
|
@machour Hmm, that's weird. I can run the app easily on my iPhone 6Plus. I just need:
|
can you give me a link to read? also, won't changing the bundle id generate modifications that shouldn't be commited? |
|
Sorry, the tutorial is not an official document and is written by Chinese. And yes, don't commit these modifications. I also left some messages for you in Gitter. Hope you can find the root reason. |
|
@chinesedfan I tried a lot of things over the past few days, the only thing that allows me to have a clean working copy (nothing to avoid commiting) is this PR. Any blockers on your side to merge this in? |
|
@machour I am not sure. Because I didn't face this problem. @gitpoint/maintainers What about you guys think? |
|
@chinesedfan, I meant, if you apply this PR locally and try to run the project as you usually do, does it still work for you? |
|
@machour No problem. I can both work normally. |
|
Really magic localhost for @machour. Except this, Let me merge it to save him. And revert in one day we found the real reason. |
|
Thank you!!!! 😭 ❤️ |
Description
This one have been making me crazy since day 1: I never was able to run the app on ios simulator without hardcoding my IP in
AppDelegate.mlike this:I discovered today that you can provide a file named
ip.txtin Xcode and put the IP there instead:https://github.com/facebook/react-native/blob/master/React/Base/RCTBundleURLProvider.m#L86
This PR add this empty file to Xcode and to gitignore at the same time, so you are free to put any IP there if needed.
I still need someone with a working setup without hardening the IP to give this a go.
(And
git statuswill finally output nothing for me, and I won't have to google how to revert a commit when I commit myAppDelegate.mfile by mistake 😭)