react-native: Changing the bundle ID breaks the upgrader

I’ve changed the bundle ID of my app to the usual com.something.somethingelse format but because of that react-native-git-upgrade fails. It writes a bunch of files to paths defined using the name in package.json, fails, then resets all the changes.

Is there any way to tell the upgrader what the bundle ID of the apps is supposed to be?

Another problem is that the thing that is supposed to show what part of the upgrade process is broken is apparently broken.

git-upgrade info Commit new version template 
git-upgrade info Generate the patch between the 2 versions 
git-upgrade info Save the patch in temp directory 
git-upgrade info Reset the 2 temporary commits 
git-upgrade info Apply the patch 
fatal: unrecognized input
git-upgrade WARN The upgrade process succeeded but there might be conflicts to be resolved. See above for the list of files that have merge conflicts. 
git-upgrade info Upgrade done 

^^^ Unfortunately, there is no list of files which I’m guessing has something to do with the fatal unrecognized input.

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Reactions: 24
  • Comments: 18 (5 by maintainers)

Commits related to this issue

Most upvoted comments

Hi there! This issue is being closed because it has been inactive for a while. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. Either way, we’re automatically closing issues after a period of inactivity. Please do not take it personally!

If you think this issue should definitely remain open, please let us know. The following information is helpful when it comes to determining if the issue should be re-opened:

  • Does the issue still reproduce on the latest release candidate? Post a comment with the version you tested.
  • If so, is there any information missing from the bug report? Post a comment with all the information required by the issue template.
  • Is there a pull request that addresses this issue? Post a comment with the PR number so we can follow up.

If you would like to work on a patch to fix the issue, contributions are very welcome! Read through the contribution guide, and feel free to hop into #react-native if you need help planning your contribution.

Got the same issue to upgrading from 0.39.2 to 0.40.0

I got the same problem, this worked for me:

Edit ~/.gitconfig and change

[color]
	ui = always

to

[color]
	ui = auto

I figured this out by manually trying to git apply the patch-file in the folder printed at the end of react-native-git-upgrade --verbose (you have to use --verbose for this folder to be printed). This patch-file was color-coded because I had ui = always, and this was the reason git printed fatal: unrecognized input.

Getting the same error:

git-upgrade info Commit new version template
[master 1e1ab7b] New version
git-upgrade info Generate the patch between the 2 versions
git-upgrade info Save the patch in temp directory
git-upgrade info Reset the 2 temporary commits
HEAD is now at 8ed1468 Project snapshot
git-upgrade info Apply the patch
error: unrecognized input
git-upgrade WARN The upgrade process succeeded but there might be conflicts to be resolved. See above for the list of files that have merge conflicts.
git-upgrade info Upgrade done
git-upgrade info Temporary working directory: C:\Users\....\AppData\Local\Temp\react-native-git-upgrade

~and it resets to the project snapshot~ it updates and has some files in conflict which I can resolve. Thing is, we have changed a lot of stuff in platform specific project files so I can understand updating RN would be difficult for a tool which checks for manual changes and doesn’t want to overwrite them… (for example: we’ve created new folders for the iOS xcode project which uses a new name… not sure if it updated in that folder. I will check when I have more time at hand)

@vinceprofeta I have delete the android and iOS folder. I run react-native init and react-native link to recreate these folder. It fix the issue for me 😄

I run 0.2.7 and got the same error:

npm WARN @shoutem/animation@0.8.10 requires a peer of react@^15.0.0 but none was installed.
npm WARN babel-loader@6.4.1 requires a peer of webpack@1 || 2 || ^2.1.0-beta || ^2.2.0-rc but none was installed.
npm WARN native-base-shoutem-theme@0.1.3 requires a peer of react@>=15.1.0 but none was installed.
npm WARN react-native-interactable@0.0.8 requires a peer of react@>= 15.4.1 but none was installed.
npm WARN react-native-svg@5.1.7 requires a peer of react@>=15.4.0 but none was installed.
npm WARN react-static-container@1.0.1 requires a peer of react@^0.13.0 || ^0.14.0 || ^15.0.0 but none was installed.
git-upgrade info Generate new version template
git-upgrade info Add updated files to commit
git-upgrade info Commit new version template
[master 59f8d3c] New version
git-upgrade info Generate the patch between the 2 versions
git-upgrade info Save the patch in temp directory
git-upgrade info Reset the 2 temporary commits
HEAD is now at 923c5bd Project snapshot
git-upgrade info Apply the patch
fatal: unrecognized input
git-upgrade WARN The upgrade process succeeded but there might be conflicts to be resolved. See above for the list of files that have merge conflicts.
git-upgrade info Upgrade done
git-upgrade info Temporary working directory: /var/folders/5k/mywmpyj53gl5qppzytyy43hw0000gn/T/react-native-git-upgrade

I found what was the issue for me. I had updated and installed the new react package I was looking for. I started again from scratch (just making sure that I was using "react-native-git-upgrade": "0.2.7") and it worked nicely.

Unrelated to changing bundleID, i get this when upgrading to 0.40