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

Refactor product name for runIOS, enable multi-line #13826

Closed
wants to merge 1 commit into from
Closed

Refactor product name for runIOS, enable multi-line #13826

wants to merge 1 commit into from

Conversation

dkpalmer
Copy link

@dkpalmer dkpalmer commented May 7, 2017

Updated FULL_PRODUCT_NAME regex to match across multiple lines, which
is the case for iOS build output. Includes refactor to export
getProductName for unit testing.

Motivation (required)

Fixes an issue introduced in #13001
where custom app names may no longer found in the iOS build output due to
change in regex, depending on FULL_PRODUCT_NAME print in build output.

What existing problem does the pull request solve?

Test Plan (required)

Manually ran:

react-native run-ios

Before change:

** BUILD SUCCEEDED **


Installing build/Build/Products/Debug-iphonesimulator/Test.app
An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=2):
Failed to install the requested application
An application bundle was not found at the provided path.
Provide a valid path to the desired application bundle.
Print: Entry, ":CFBundleIdentifier", Does Not Exist

Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/Test.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist

After change:

** BUILD SUCCEEDED **


Installing build/Build/Products/Debug-iphonesimulator/Test Dev.app
Launching com.test.dev-ent
com.test.dev-ent: 25738

Additionally, added unit tests to exhaust case where:

  1. .app is provided, single line
  2. .app is provided, multi-line
  3. .appex and .app are provided (reason more accurate product-name regex #13001 was pushed)
  4. Multiple .app's are provided
  5. No .app is provided

Updated FULL_PRODUCT_NAME regex to match across multiple lines, which
is the case for iOS build output. Includes refactor to export
getProductName for testing.
@facebook-github-bot facebook-github-bot added GH Review: review-needed CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. labels May 7, 2017
@dkpalmer
Copy link
Author

dkpalmer commented May 8, 2017

Travis build is failing for iOS:

/Users/travis/build/facebook/react-native/Examples/UIExplorer/UIExplorerUnitTests/RCTBridgeTests.m:19:9: fatal error: 'React/RCTBridge+Private.h' file not found

and tvOS:

/Users/travis/build/facebook/react-native/ReactCommon/jschelpers/Value.cpp:3:10: fatal error: 'folly/json.h' file not found

I can't correlate these errors to my changes. Anyone have any insights?

@mstllc
Copy link

mstllc commented May 22, 2017

While I can't help with the failing Travis build, I would also appreciate this fix being merged. We have a few different configurations of our app with different Product Names, and we're running into the same issue where the builds won't install to the simulator if built with runIOS

@shergin shergin added Platform: iOS iOS applications. Tooling labels May 31, 2017
birkir added a commit to ueno-llc/ueno-app that referenced this pull request Jul 4, 2017
birkir added a commit to ueno-llc/ueno-app that referenced this pull request Aug 24, 2017
birkir added a commit to ueno-llc/ueno-app that referenced this pull request Aug 24, 2017
@facebook-github-bot
Copy link
Contributor

@dkpalmer I tried to find reviewers for this pull request and wanted to ping them to take another look. However, based on the blame information for the files in this pull request I couldn't find any reviewers. This sometimes happens when the files in the pull request are new or don't exist on master anymore. Is this pull request still relevant? If yes could you please rebase? In case you know who has context on this code feel free to mention them in a comment (one person is fine). Thanks for reading and hope you will continue contributing to the project.

@stale
Copy link

stale bot commented Oct 27, 2017

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. If you think this issue should definitely remain open, please let us know why. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Oct 27, 2017
@stale stale bot closed this Nov 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. Platform: iOS iOS applications. Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants